We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent f4b4d69 commit 169c5e4Copy full SHA for 169c5e4
src/core/modules/useCamera.ts
@@ -22,6 +22,14 @@ export default function useCamera(
22
const camera = getCamera();
23
const mtime = camera.getMTime();
24
25
+ // filter out any null props
26
+ Object.keys(cameraProps).forEach((key) => {
27
+ const name = key as keyof ICameraInitialValues;
28
+ if (!cameraProps[name]) {
29
+ delete cameraProps[name];
30
+ }
31
+ });
32
+
33
camera.set(cameraProps);
34
35
// force-set focal point and direction of projection,
0 commit comments