lythreeframe 1.0.26 → 1.0.28
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/bundle.cjs.js
CHANGED
|
@@ -1664,6 +1664,10 @@ class Viewport {
|
|
|
1664
1664
|
}
|
|
1665
1665
|
this.isRenderStateDirty = false;
|
|
1666
1666
|
}
|
|
1667
|
+
renderAsImage() {
|
|
1668
|
+
new Image();
|
|
1669
|
+
return this.renderer.domElement.toDataURL('image/jpeg');
|
|
1670
|
+
}
|
|
1667
1671
|
destroy() {
|
|
1668
1672
|
var _a;
|
|
1669
1673
|
this.destroyPostProcess();
|
|
@@ -2138,6 +2142,7 @@ class ThreeJsApp {
|
|
|
2138
2142
|
if (previousCam !== this.camera) {
|
|
2139
2143
|
this._onCameraChangedDelegate.broadcast();
|
|
2140
2144
|
}
|
|
2145
|
+
this._camera.updateProjectionMatrix();
|
|
2141
2146
|
this.viewport.markRenderStateDirty();
|
|
2142
2147
|
}
|
|
2143
2148
|
onWindowResize(width, height) {
|
|
@@ -2150,6 +2155,9 @@ class ThreeJsApp {
|
|
|
2150
2155
|
// }
|
|
2151
2156
|
this.camera.updateProjectionMatrix();
|
|
2152
2157
|
}
|
|
2158
|
+
renderAsImage() {
|
|
2159
|
+
return this.viewport.renderAsImage();
|
|
2160
|
+
}
|
|
2153
2161
|
}
|
|
2154
2162
|
|
|
2155
2163
|
class Actor extends BaseObject {
|
package/dist/bundle.esm.js
CHANGED
|
@@ -1662,6 +1662,10 @@ class Viewport {
|
|
|
1662
1662
|
}
|
|
1663
1663
|
this.isRenderStateDirty = false;
|
|
1664
1664
|
}
|
|
1665
|
+
renderAsImage() {
|
|
1666
|
+
new Image();
|
|
1667
|
+
return this.renderer.domElement.toDataURL('image/jpeg');
|
|
1668
|
+
}
|
|
1665
1669
|
destroy() {
|
|
1666
1670
|
var _a;
|
|
1667
1671
|
this.destroyPostProcess();
|
|
@@ -2136,6 +2140,7 @@ class ThreeJsApp {
|
|
|
2136
2140
|
if (previousCam !== this.camera) {
|
|
2137
2141
|
this._onCameraChangedDelegate.broadcast();
|
|
2138
2142
|
}
|
|
2143
|
+
this._camera.updateProjectionMatrix();
|
|
2139
2144
|
this.viewport.markRenderStateDirty();
|
|
2140
2145
|
}
|
|
2141
2146
|
onWindowResize(width, height) {
|
|
@@ -2148,6 +2153,9 @@ class ThreeJsApp {
|
|
|
2148
2153
|
// }
|
|
2149
2154
|
this.camera.updateProjectionMatrix();
|
|
2150
2155
|
}
|
|
2156
|
+
renderAsImage() {
|
|
2157
|
+
return this.viewport.renderAsImage();
|
|
2158
|
+
}
|
|
2151
2159
|
}
|
|
2152
2160
|
|
|
2153
2161
|
class Actor extends BaseObject {
|