viral-viewer-2 6.4.9 → 6.5.0
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.
|
@@ -24,6 +24,7 @@ export declare class ViralCamera {
|
|
|
24
24
|
restoreState(state: ViralViewerState): void;
|
|
25
25
|
clientToWorld(): import("three").Intersection<Object3D<import("three").Object3DEventMap>>[] | null;
|
|
26
26
|
worldToClient(point: Vector3): Vector3 | null;
|
|
27
|
+
worldToClient2(point: Vector3): Vector3 | null;
|
|
27
28
|
private castRay;
|
|
28
29
|
updateMainCamera(): void;
|
|
29
30
|
private cameraWakeQueuedEvents;
|
package/dist/index.mjs
CHANGED
|
@@ -23276,6 +23276,14 @@ class O2 {
|
|
|
23276
23276
|
}
|
|
23277
23277
|
return null;
|
|
23278
23278
|
}
|
|
23279
|
+
worldToClient2(e) {
|
|
23280
|
+
if (this.camera) {
|
|
23281
|
+
e.project(this.camera);
|
|
23282
|
+
const t = (e.x + 1) / 2 * this.viralViewerApi.viralRenderer.renderer.domElement.clientWidth, i = -(e.y - 1) / 2 * this.viralViewerApi.viralRenderer.renderer.domElement.clientHeight;
|
|
23283
|
+
return new G(t, i, 0);
|
|
23284
|
+
}
|
|
23285
|
+
return null;
|
|
23286
|
+
}
|
|
23279
23287
|
castRay(e) {
|
|
23280
23288
|
return this.camera && this.raycaster && this.viralViewerApi.viralMouse ? (this.camera.updateMatrixWorld(!0), this.raycaster.setFromCamera(
|
|
23281
23289
|
this.viralViewerApi.viralMouse.position,
|