@reactvision/react-viro 2.43.1 → 2.43.3
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/README.md +3 -5
- package/android/react_viro/react_viro-release.aar +0 -0
- package/components/Utilities/ViroVersion.ts +1 -1
- package/dist/components/Utilities/ViroVersion.d.ts +1 -1
- package/dist/components/Utilities/ViroVersion.js +1 -1
- package/dist/plugins/withViro.d.ts +0 -3
- package/dist/plugins/withViro.js +0 -19
- package/dist/plugins/withViroAndroid.js +20 -24
- package/dist/plugins/withViroIos.js +2 -20
- package/ios/ViroReact.podspec +11 -51
- package/ios/dist/armv7_arm64/libViroReact.a +0 -0
- package/ios/dist/include/VRTFabricCrashFix.h +16 -0
- package/ios/dist/lib/libViroReact.a +0 -0
- package/package.json +10 -23
- package/dist/dynamic-index.d.ts +0 -11
- package/dist/dynamic-index.js +0 -28
- package/dist/examples/AutoDetectionExample.d.ts +0 -10
- package/dist/examples/AutoDetectionExample.js +0 -91
- package/dist/fabric-interop/NativeViro.d.ts +0 -42
- package/dist/fabric-interop/NativeViro.js +0 -262
- package/dist/fabric-interop/ViroEventsManager.d.ts +0 -83
- package/dist/fabric-interop/ViroEventsManager.js +0 -222
- package/dist/fabric-interop/ViroFabricContainer.d.ts +0 -34
- package/dist/fabric-interop/ViroFabricContainer.js +0 -200
- package/dist/fabric-interop/android/src/main/js/specs/ViroFabricContainerViewNativeComponent.d.ts +0 -35
- package/dist/fabric-interop/android/src/main/js/specs/ViroFabricContainerViewNativeComponent.js +0 -20
- package/dist/fabric-interop/components/AR/ViroARPlane.d.ts +0 -22
- package/dist/fabric-interop/components/AR/ViroARPlane.js +0 -95
- package/dist/fabric-interop/components/AR/ViroARPlaneSelector.d.ts +0 -43
- package/dist/fabric-interop/components/AR/ViroARPlaneSelector.js +0 -152
- package/dist/fabric-interop/components/AR/ViroARTrackingTargets.d.ts +0 -55
- package/dist/fabric-interop/components/AR/ViroARTrackingTargets.js +0 -85
- package/dist/fabric-interop/components/AR/ViroCommonProps.d.ts +0 -91
- package/dist/fabric-interop/components/AR/ViroCommonProps.js +0 -7
- package/dist/fabric-interop/components/Animation/ViroAnimations.d.ts +0 -48
- package/dist/fabric-interop/components/Animation/ViroAnimations.js +0 -64
- package/dist/fabric-interop/components/Material/ViroMaterials.d.ts +0 -66
- package/dist/fabric-interop/components/Material/ViroMaterials.js +0 -85
- package/dist/fabric-interop/components/Types/ViroEvents.d.ts +0 -202
- package/dist/fabric-interop/components/Types/ViroEvents.js +0 -53
- package/dist/fabric-interop/components/Types/ViroUtils.d.ts +0 -137
- package/dist/fabric-interop/components/Types/ViroUtils.js +0 -7
- package/dist/fabric-interop/components/Viro360Image.d.ts +0 -23
- package/dist/fabric-interop/components/Viro360Image.js +0 -45
- package/dist/fabric-interop/components/Viro360Video.d.ts +0 -29
- package/dist/fabric-interop/components/Viro360Video.js +0 -47
- package/dist/fabric-interop/components/Viro3DObject.d.ts +0 -60
- package/dist/fabric-interop/components/Viro3DObject.js +0 -49
- package/dist/fabric-interop/components/Viro3DSceneNavigator.d.ts +0 -49
- package/dist/fabric-interop/components/Viro3DSceneNavigator.js +0 -388
- package/dist/fabric-interop/components/ViroARCamera.d.ts +0 -29
- package/dist/fabric-interop/components/ViroARCamera.js +0 -64
- package/dist/fabric-interop/components/ViroARImageMarker.d.ts +0 -21
- package/dist/fabric-interop/components/ViroARImageMarker.js +0 -71
- package/dist/fabric-interop/components/ViroARObjectMarker.d.ts +0 -21
- package/dist/fabric-interop/components/ViroARObjectMarker.js +0 -71
- package/dist/fabric-interop/components/ViroARPlane.d.ts +0 -24
- package/dist/fabric-interop/components/ViroARPlane.js +0 -88
- package/dist/fabric-interop/components/ViroARScene.d.ts +0 -29
- package/dist/fabric-interop/components/ViroARScene.js +0 -89
- package/dist/fabric-interop/components/ViroARSceneNavigator.d.ts +0 -29
- package/dist/fabric-interop/components/ViroARSceneNavigator.js +0 -76
- package/dist/fabric-interop/components/ViroAmbientLight.d.ts +0 -19
- package/dist/fabric-interop/components/ViroAmbientLight.js +0 -46
- package/dist/fabric-interop/components/ViroAnimatedComponent.d.ts +0 -24
- package/dist/fabric-interop/components/ViroAnimatedComponent.js +0 -63
- package/dist/fabric-interop/components/ViroAnimatedImage.d.ts +0 -28
- package/dist/fabric-interop/components/ViroAnimatedImage.js +0 -49
- package/dist/fabric-interop/components/ViroBox.d.ts +0 -20
- package/dist/fabric-interop/components/ViroBox.js +0 -47
- package/dist/fabric-interop/components/ViroButton.d.ts +0 -32
- package/dist/fabric-interop/components/ViroButton.js +0 -92
- package/dist/fabric-interop/components/ViroCamera.d.ts +0 -17
- package/dist/fabric-interop/components/ViroCamera.js +0 -30
- package/dist/fabric-interop/components/ViroController.d.ts +0 -19
- package/dist/fabric-interop/components/ViroController.js +0 -64
- package/dist/fabric-interop/components/ViroDirectionalLight.d.ts +0 -28
- package/dist/fabric-interop/components/ViroDirectionalLight.js +0 -55
- package/dist/fabric-interop/components/ViroFlexView.d.ts +0 -36
- package/dist/fabric-interop/components/ViroFlexView.js +0 -97
- package/dist/fabric-interop/components/ViroGeometry.d.ts +0 -23
- package/dist/fabric-interop/components/ViroGeometry.js +0 -50
- package/dist/fabric-interop/components/ViroGlobal.d.ts +0 -45
- package/dist/fabric-interop/components/ViroGlobal.js +0 -20
- package/dist/fabric-interop/components/ViroImage.d.ts +0 -29
- package/dist/fabric-interop/components/ViroImage.js +0 -52
- package/dist/fabric-interop/components/ViroLightingEnvironment.d.ts +0 -19
- package/dist/fabric-interop/components/ViroLightingEnvironment.js +0 -44
- package/dist/fabric-interop/components/ViroMaterialVideo.d.ts +0 -30
- package/dist/fabric-interop/components/ViroMaterialVideo.js +0 -48
- package/dist/fabric-interop/components/ViroNode.d.ts +0 -36
- package/dist/fabric-interop/components/ViroNode.js +0 -28
- package/dist/fabric-interop/components/ViroOmniLight.d.ts +0 -21
- package/dist/fabric-interop/components/ViroOmniLight.js +0 -48
- package/dist/fabric-interop/components/ViroOrbitCamera.d.ts +0 -17
- package/dist/fabric-interop/components/ViroOrbitCamera.js +0 -30
- package/dist/fabric-interop/components/ViroParticleEmitter.d.ts +0 -51
- package/dist/fabric-interop/components/ViroParticleEmitter.js +0 -50
- package/dist/fabric-interop/components/ViroPolygon.d.ts +0 -20
- package/dist/fabric-interop/components/ViroPolygon.js +0 -47
- package/dist/fabric-interop/components/ViroPolyline.d.ts +0 -19
- package/dist/fabric-interop/components/ViroPolyline.js +0 -46
- package/dist/fabric-interop/components/ViroPortal.d.ts +0 -16
- package/dist/fabric-interop/components/ViroPortal.js +0 -73
- package/dist/fabric-interop/components/ViroPortalScene.d.ts +0 -16
- package/dist/fabric-interop/components/ViroPortalScene.js +0 -29
- package/dist/fabric-interop/components/ViroQuad.d.ts +0 -39
- package/dist/fabric-interop/components/ViroQuad.js +0 -49
- package/dist/fabric-interop/components/ViroScene.d.ts +0 -29
- package/dist/fabric-interop/components/ViroScene.js +0 -103
- package/dist/fabric-interop/components/ViroSceneNavigator.d.ts +0 -23
- package/dist/fabric-interop/components/ViroSceneNavigator.js +0 -73
- package/dist/fabric-interop/components/ViroSkyBox.d.ts +0 -39
- package/dist/fabric-interop/components/ViroSkyBox.js +0 -44
- package/dist/fabric-interop/components/ViroSound.d.ts +0 -23
- package/dist/fabric-interop/components/ViroSound.js +0 -46
- package/dist/fabric-interop/components/ViroSoundField.d.ts +0 -24
- package/dist/fabric-interop/components/ViroSoundField.js +0 -47
- package/dist/fabric-interop/components/ViroSpatialSound.d.ts +0 -27
- package/dist/fabric-interop/components/ViroSpatialSound.js +0 -50
- package/dist/fabric-interop/components/ViroSphere.d.ts +0 -22
- package/dist/fabric-interop/components/ViroSphere.js +0 -49
- package/dist/fabric-interop/components/ViroSpinner.d.ts +0 -18
- package/dist/fabric-interop/components/ViroSpinner.js +0 -45
- package/dist/fabric-interop/components/ViroSpotLight.d.ts +0 -30
- package/dist/fabric-interop/components/ViroSpotLight.js +0 -57
- package/dist/fabric-interop/components/ViroSurface.d.ts +0 -38
- package/dist/fabric-interop/components/ViroSurface.js +0 -48
- package/dist/fabric-interop/components/ViroText.d.ts +0 -36
- package/dist/fabric-interop/components/ViroText.js +0 -59
- package/dist/fabric-interop/components/ViroUtils.d.ts +0 -63
- package/dist/fabric-interop/components/ViroUtils.js +0 -140
- package/dist/fabric-interop/components/ViroVRSceneNavigator.d.ts +0 -25
- package/dist/fabric-interop/components/ViroVRSceneNavigator.js +0 -73
- package/dist/fabric-interop/components/ViroVideo.d.ts +0 -32
- package/dist/fabric-interop/components/ViroVideo.js +0 -52
- package/dist/fabric-interop/components/index.d.ts +0 -62
- package/dist/fabric-interop/components/index.js +0 -144
- package/dist/fabric-interop/examples/BasicSceneExample.d.ts +0 -11
- package/dist/fabric-interop/examples/BasicSceneExample.js +0 -244
- package/dist/fabric-interop/examples/ComprehensiveExample.d.ts +0 -13
- package/dist/fabric-interop/examples/ComprehensiveExample.js +0 -327
- package/dist/fabric-interop/examples/SimpleARExample.d.ts +0 -8
- package/dist/fabric-interop/examples/SimpleARExample.js +0 -62
- package/dist/fabric-interop/index.d.ts +0 -14
- package/dist/fabric-interop/index.js +0 -117
- package/dist/fabric-interop/specs/ViroEventsTurboModule.d.ts +0 -19
- package/dist/fabric-interop/specs/ViroEventsTurboModule.js +0 -11
- package/dist/fabric-interop/test/BasicFunctionalityTest.d.ts +0 -9
- package/dist/fabric-interop/test/BasicFunctionalityTest.js +0 -222
- package/dist/fabric.d.ts +0 -13
- package/dist/fabric.js +0 -29
- package/dynamic-index-source.d.ts +0 -77
- package/dynamic-index.ts +0 -41
- package/fabric-interop/NativeViro.ts +0 -335
- package/fabric-interop/README.md +0 -282
- package/fabric-interop/ViroEventsManager.js +0 -257
- package/fabric-interop/ViroFabricContainer.tsx +0 -273
- package/fabric-interop/components/AR/ViroARPlane.tsx +0 -108
- package/fabric-interop/components/AR/ViroARPlaneSelector.tsx +0 -185
- package/fabric-interop/components/AR/ViroARTrackingTargets.ts +0 -108
- package/fabric-interop/components/AR/ViroCommonProps.ts +0 -140
- package/fabric-interop/components/Animation/ViroAnimations.ts +0 -96
- package/fabric-interop/components/Material/ViroMaterials.ts +0 -127
- package/fabric-interop/components/Resources/viro_spinner_1.png +0 -0
- package/fabric-interop/components/Resources/viro_spinner_1_w.png +0 -0
- package/fabric-interop/components/Resources/viro_spinner_1a.png +0 -0
- package/fabric-interop/components/Resources/viro_spinner_1a_w.png +0 -0
- package/fabric-interop/components/Types/ViroEvents.ts +0 -285
- package/fabric-interop/components/Types/ViroUtils.ts +0 -160
- package/fabric-interop/components/Viro360Image.tsx +0 -70
- package/fabric-interop/components/Viro360Video.tsx +0 -78
- package/fabric-interop/components/Viro3DObject.tsx +0 -122
- package/fabric-interop/components/Viro3DSceneNavigator.tsx +0 -503
- package/fabric-interop/components/ViroARCamera.tsx +0 -105
- package/fabric-interop/components/ViroARImageMarker.tsx +0 -98
- package/fabric-interop/components/ViroARObjectMarker.tsx +0 -100
- package/fabric-interop/components/ViroARPlane.tsx +0 -120
- package/fabric-interop/components/ViroARScene.tsx +0 -127
- package/fabric-interop/components/ViroARSceneNavigator.tsx +0 -82
- package/fabric-interop/components/ViroAmbientLight.tsx +0 -62
- package/fabric-interop/components/ViroAnimatedComponent.tsx +0 -91
- package/fabric-interop/components/ViroAnimatedImage.tsx +0 -81
- package/fabric-interop/components/ViroBox.tsx +0 -72
- package/fabric-interop/components/ViroButton.tsx +0 -125
- package/fabric-interop/components/ViroCamera.tsx +0 -45
- package/fabric-interop/components/ViroController.tsx +0 -87
- package/fabric-interop/components/ViroDirectionalLight.tsx +0 -84
- package/fabric-interop/components/ViroFlexView.tsx +0 -146
- package/fabric-interop/components/ViroGeometry.tsx +0 -78
- package/fabric-interop/components/ViroGlobal.ts +0 -114
- package/fabric-interop/components/ViroImage.tsx +0 -85
- package/fabric-interop/components/ViroLightingEnvironment.tsx +0 -63
- package/fabric-interop/components/ViroMaterialVideo.tsx +0 -82
- package/fabric-interop/components/ViroNode.tsx +0 -62
- package/fabric-interop/components/ViroOmniLight.tsx +0 -66
- package/fabric-interop/components/ViroOrbitCamera.tsx +0 -45
- package/fabric-interop/components/ViroParticleEmitter.tsx +0 -111
- package/fabric-interop/components/ViroPolygon.tsx +0 -72
- package/fabric-interop/components/ViroPolyline.tsx +0 -71
- package/fabric-interop/components/ViroPortal.tsx +0 -91
- package/fabric-interop/components/ViroPortalScene.tsx +0 -43
- package/fabric-interop/components/ViroQuad.tsx +0 -82
- package/fabric-interop/components/ViroScene.tsx +0 -117
- package/fabric-interop/components/ViroSceneNavigator.tsx +0 -71
- package/fabric-interop/components/ViroSkyBox.tsx +0 -75
- package/fabric-interop/components/ViroSound.tsx +0 -71
- package/fabric-interop/components/ViroSoundField.tsx +0 -75
- package/fabric-interop/components/ViroSpatialSound.tsx +0 -81
- package/fabric-interop/components/ViroSphere.tsx +0 -75
- package/fabric-interop/components/ViroSpinner.tsx +0 -63
- package/fabric-interop/components/ViroSpotLight.tsx +0 -86
- package/fabric-interop/components/ViroSurface.tsx +0 -80
- package/fabric-interop/components/ViroText.tsx +0 -114
- package/fabric-interop/components/ViroUtils.ts +0 -208
- package/fabric-interop/components/ViroVRSceneNavigator.tsx +0 -75
- package/fabric-interop/components/ViroVideo.tsx +0 -91
- package/fabric-interop/components/index.ts +0 -94
- package/fabric-interop/dist/NativeViro.d.ts +0 -43
- package/fabric-interop/dist/NativeViro.d.ts.map +0 -1
- package/fabric-interop/dist/NativeViro.js +0 -263
- package/fabric-interop/dist/NativeViro.js.map +0 -1
- package/fabric-interop/dist/ViroFabricContainer.d.ts +0 -35
- package/fabric-interop/dist/ViroFabricContainer.d.ts.map +0 -1
- package/fabric-interop/dist/ViroFabricContainer.js +0 -201
- package/fabric-interop/dist/ViroFabricContainer.js.map +0 -1
- package/fabric-interop/dist/components/AR/ViroARPlane.d.ts +0 -23
- package/fabric-interop/dist/components/AR/ViroARPlane.d.ts.map +0 -1
- package/fabric-interop/dist/components/AR/ViroARPlane.js +0 -96
- package/fabric-interop/dist/components/AR/ViroARPlane.js.map +0 -1
- package/fabric-interop/dist/components/AR/ViroARPlaneSelector.d.ts +0 -44
- package/fabric-interop/dist/components/AR/ViroARPlaneSelector.d.ts.map +0 -1
- package/fabric-interop/dist/components/AR/ViroARPlaneSelector.js +0 -156
- package/fabric-interop/dist/components/AR/ViroARPlaneSelector.js.map +0 -1
- package/fabric-interop/dist/components/AR/ViroARTrackingTargets.d.ts +0 -56
- package/fabric-interop/dist/components/AR/ViroARTrackingTargets.d.ts.map +0 -1
- package/fabric-interop/dist/components/AR/ViroARTrackingTargets.js +0 -86
- package/fabric-interop/dist/components/AR/ViroARTrackingTargets.js.map +0 -1
- package/fabric-interop/dist/components/AR/ViroCommonProps.d.ts +0 -92
- package/fabric-interop/dist/components/AR/ViroCommonProps.d.ts.map +0 -1
- package/fabric-interop/dist/components/AR/ViroCommonProps.js +0 -8
- package/fabric-interop/dist/components/AR/ViroCommonProps.js.map +0 -1
- package/fabric-interop/dist/components/Animation/ViroAnimations.d.ts +0 -49
- package/fabric-interop/dist/components/Animation/ViroAnimations.d.ts.map +0 -1
- package/fabric-interop/dist/components/Animation/ViroAnimations.js +0 -65
- package/fabric-interop/dist/components/Animation/ViroAnimations.js.map +0 -1
- package/fabric-interop/dist/components/Material/ViroMaterials.d.ts +0 -67
- package/fabric-interop/dist/components/Material/ViroMaterials.d.ts.map +0 -1
- package/fabric-interop/dist/components/Material/ViroMaterials.js +0 -86
- package/fabric-interop/dist/components/Material/ViroMaterials.js.map +0 -1
- package/fabric-interop/dist/components/Types/ViroEvents.d.ts +0 -203
- package/fabric-interop/dist/components/Types/ViroEvents.d.ts.map +0 -1
- package/fabric-interop/dist/components/Types/ViroEvents.js +0 -54
- package/fabric-interop/dist/components/Types/ViroEvents.js.map +0 -1
- package/fabric-interop/dist/components/Types/ViroUtils.d.ts +0 -138
- package/fabric-interop/dist/components/Types/ViroUtils.d.ts.map +0 -1
- package/fabric-interop/dist/components/Types/ViroUtils.js +0 -8
- package/fabric-interop/dist/components/Types/ViroUtils.js.map +0 -1
- package/fabric-interop/dist/components/Viro360Image.d.ts +0 -24
- package/fabric-interop/dist/components/Viro360Image.d.ts.map +0 -1
- package/fabric-interop/dist/components/Viro360Image.js +0 -47
- package/fabric-interop/dist/components/Viro360Image.js.map +0 -1
- package/fabric-interop/dist/components/Viro360Video.d.ts +0 -30
- package/fabric-interop/dist/components/Viro360Video.d.ts.map +0 -1
- package/fabric-interop/dist/components/Viro360Video.js +0 -49
- package/fabric-interop/dist/components/Viro360Video.js.map +0 -1
- package/fabric-interop/dist/components/Viro3DObject.d.ts +0 -61
- package/fabric-interop/dist/components/Viro3DObject.d.ts.map +0 -1
- package/fabric-interop/dist/components/Viro3DObject.js +0 -51
- package/fabric-interop/dist/components/Viro3DObject.js.map +0 -1
- package/fabric-interop/dist/components/Viro3DSceneNavigator.d.ts +0 -50
- package/fabric-interop/dist/components/Viro3DSceneNavigator.d.ts.map +0 -1
- package/fabric-interop/dist/components/Viro3DSceneNavigator.js +0 -389
- package/fabric-interop/dist/components/Viro3DSceneNavigator.js.map +0 -1
- package/fabric-interop/dist/components/ViroARCamera.d.ts +0 -30
- package/fabric-interop/dist/components/ViroARCamera.d.ts.map +0 -1
- package/fabric-interop/dist/components/ViroARCamera.js +0 -65
- package/fabric-interop/dist/components/ViroARCamera.js.map +0 -1
- package/fabric-interop/dist/components/ViroARImageMarker.d.ts +0 -22
- package/fabric-interop/dist/components/ViroARImageMarker.d.ts.map +0 -1
- package/fabric-interop/dist/components/ViroARImageMarker.js +0 -72
- package/fabric-interop/dist/components/ViroARImageMarker.js.map +0 -1
- package/fabric-interop/dist/components/ViroARObjectMarker.d.ts +0 -22
- package/fabric-interop/dist/components/ViroARObjectMarker.d.ts.map +0 -1
- package/fabric-interop/dist/components/ViroARObjectMarker.js +0 -72
- package/fabric-interop/dist/components/ViroARObjectMarker.js.map +0 -1
- package/fabric-interop/dist/components/ViroARPlane.d.ts +0 -25
- package/fabric-interop/dist/components/ViroARPlane.d.ts.map +0 -1
- package/fabric-interop/dist/components/ViroARPlane.js +0 -89
- package/fabric-interop/dist/components/ViroARPlane.js.map +0 -1
- package/fabric-interop/dist/components/ViroARScene.d.ts +0 -30
- package/fabric-interop/dist/components/ViroARScene.d.ts.map +0 -1
- package/fabric-interop/dist/components/ViroARScene.js +0 -90
- package/fabric-interop/dist/components/ViroARScene.js.map +0 -1
- package/fabric-interop/dist/components/ViroARSceneNavigator.d.ts +0 -30
- package/fabric-interop/dist/components/ViroARSceneNavigator.d.ts.map +0 -1
- package/fabric-interop/dist/components/ViroARSceneNavigator.js +0 -78
- package/fabric-interop/dist/components/ViroARSceneNavigator.js.map +0 -1
- package/fabric-interop/dist/components/ViroAmbientLight.d.ts +0 -20
- package/fabric-interop/dist/components/ViroAmbientLight.d.ts.map +0 -1
- package/fabric-interop/dist/components/ViroAmbientLight.js +0 -48
- package/fabric-interop/dist/components/ViroAmbientLight.js.map +0 -1
- package/fabric-interop/dist/components/ViroAnimatedComponent.d.ts +0 -25
- package/fabric-interop/dist/components/ViroAnimatedComponent.d.ts.map +0 -1
- package/fabric-interop/dist/components/ViroAnimatedComponent.js +0 -65
- package/fabric-interop/dist/components/ViroAnimatedComponent.js.map +0 -1
- package/fabric-interop/dist/components/ViroAnimatedImage.d.ts +0 -29
- package/fabric-interop/dist/components/ViroAnimatedImage.d.ts.map +0 -1
- package/fabric-interop/dist/components/ViroAnimatedImage.js +0 -51
- package/fabric-interop/dist/components/ViroAnimatedImage.js.map +0 -1
- package/fabric-interop/dist/components/ViroBox.d.ts +0 -21
- package/fabric-interop/dist/components/ViroBox.d.ts.map +0 -1
- package/fabric-interop/dist/components/ViroBox.js +0 -49
- package/fabric-interop/dist/components/ViroBox.js.map +0 -1
- package/fabric-interop/dist/components/ViroButton.d.ts +0 -33
- package/fabric-interop/dist/components/ViroButton.d.ts.map +0 -1
- package/fabric-interop/dist/components/ViroButton.js +0 -94
- package/fabric-interop/dist/components/ViroButton.js.map +0 -1
- package/fabric-interop/dist/components/ViroCamera.d.ts +0 -18
- package/fabric-interop/dist/components/ViroCamera.d.ts.map +0 -1
- package/fabric-interop/dist/components/ViroCamera.js +0 -31
- package/fabric-interop/dist/components/ViroCamera.js.map +0 -1
- package/fabric-interop/dist/components/ViroController.d.ts +0 -20
- package/fabric-interop/dist/components/ViroController.d.ts.map +0 -1
- package/fabric-interop/dist/components/ViroController.js +0 -65
- package/fabric-interop/dist/components/ViroController.js.map +0 -1
- package/fabric-interop/dist/components/ViroDirectionalLight.d.ts +0 -29
- package/fabric-interop/dist/components/ViroDirectionalLight.d.ts.map +0 -1
- package/fabric-interop/dist/components/ViroDirectionalLight.js +0 -57
- package/fabric-interop/dist/components/ViroDirectionalLight.js.map +0 -1
- package/fabric-interop/dist/components/ViroFlexView.d.ts +0 -37
- package/fabric-interop/dist/components/ViroFlexView.d.ts.map +0 -1
- package/fabric-interop/dist/components/ViroFlexView.js +0 -98
- package/fabric-interop/dist/components/ViroFlexView.js.map +0 -1
- package/fabric-interop/dist/components/ViroGeometry.d.ts +0 -24
- package/fabric-interop/dist/components/ViroGeometry.d.ts.map +0 -1
- package/fabric-interop/dist/components/ViroGeometry.js +0 -52
- package/fabric-interop/dist/components/ViroGeometry.js.map +0 -1
- package/fabric-interop/dist/components/ViroGlobal.d.ts +0 -46
- package/fabric-interop/dist/components/ViroGlobal.d.ts.map +0 -1
- package/fabric-interop/dist/components/ViroGlobal.js +0 -21
- package/fabric-interop/dist/components/ViroGlobal.js.map +0 -1
- package/fabric-interop/dist/components/ViroImage.d.ts +0 -30
- package/fabric-interop/dist/components/ViroImage.d.ts.map +0 -1
- package/fabric-interop/dist/components/ViroImage.js +0 -54
- package/fabric-interop/dist/components/ViroImage.js.map +0 -1
- package/fabric-interop/dist/components/ViroLightingEnvironment.d.ts +0 -20
- package/fabric-interop/dist/components/ViroLightingEnvironment.d.ts.map +0 -1
- package/fabric-interop/dist/components/ViroLightingEnvironment.js +0 -46
- package/fabric-interop/dist/components/ViroLightingEnvironment.js.map +0 -1
- package/fabric-interop/dist/components/ViroMaterialVideo.d.ts +0 -31
- package/fabric-interop/dist/components/ViroMaterialVideo.d.ts.map +0 -1
- package/fabric-interop/dist/components/ViroMaterialVideo.js +0 -50
- package/fabric-interop/dist/components/ViroMaterialVideo.js.map +0 -1
- package/fabric-interop/dist/components/ViroNode.d.ts +0 -37
- package/fabric-interop/dist/components/ViroNode.d.ts.map +0 -1
- package/fabric-interop/dist/components/ViroNode.js +0 -29
- package/fabric-interop/dist/components/ViroNode.js.map +0 -1
- package/fabric-interop/dist/components/ViroOmniLight.d.ts +0 -22
- package/fabric-interop/dist/components/ViroOmniLight.d.ts.map +0 -1
- package/fabric-interop/dist/components/ViroOmniLight.js +0 -50
- package/fabric-interop/dist/components/ViroOmniLight.js.map +0 -1
- package/fabric-interop/dist/components/ViroOrbitCamera.d.ts +0 -18
- package/fabric-interop/dist/components/ViroOrbitCamera.d.ts.map +0 -1
- package/fabric-interop/dist/components/ViroOrbitCamera.js +0 -31
- package/fabric-interop/dist/components/ViroOrbitCamera.js.map +0 -1
- package/fabric-interop/dist/components/ViroParticleEmitter.d.ts +0 -52
- package/fabric-interop/dist/components/ViroParticleEmitter.d.ts.map +0 -1
- package/fabric-interop/dist/components/ViroParticleEmitter.js +0 -52
- package/fabric-interop/dist/components/ViroParticleEmitter.js.map +0 -1
- package/fabric-interop/dist/components/ViroPolygon.d.ts +0 -21
- package/fabric-interop/dist/components/ViroPolygon.d.ts.map +0 -1
- package/fabric-interop/dist/components/ViroPolygon.js +0 -49
- package/fabric-interop/dist/components/ViroPolygon.js.map +0 -1
- package/fabric-interop/dist/components/ViroPolyline.d.ts +0 -20
- package/fabric-interop/dist/components/ViroPolyline.d.ts.map +0 -1
- package/fabric-interop/dist/components/ViroPolyline.js +0 -48
- package/fabric-interop/dist/components/ViroPolyline.js.map +0 -1
- package/fabric-interop/dist/components/ViroPortal.d.ts +0 -17
- package/fabric-interop/dist/components/ViroPortal.d.ts.map +0 -1
- package/fabric-interop/dist/components/ViroPortal.js +0 -74
- package/fabric-interop/dist/components/ViroPortal.js.map +0 -1
- package/fabric-interop/dist/components/ViroPortalScene.d.ts +0 -17
- package/fabric-interop/dist/components/ViroPortalScene.d.ts.map +0 -1
- package/fabric-interop/dist/components/ViroPortalScene.js +0 -30
- package/fabric-interop/dist/components/ViroPortalScene.js.map +0 -1
- package/fabric-interop/dist/components/ViroQuad.d.ts +0 -40
- package/fabric-interop/dist/components/ViroQuad.d.ts.map +0 -1
- package/fabric-interop/dist/components/ViroQuad.js +0 -51
- package/fabric-interop/dist/components/ViroQuad.js.map +0 -1
- package/fabric-interop/dist/components/ViroScene.d.ts +0 -30
- package/fabric-interop/dist/components/ViroScene.d.ts.map +0 -1
- package/fabric-interop/dist/components/ViroScene.js +0 -105
- package/fabric-interop/dist/components/ViroScene.js.map +0 -1
- package/fabric-interop/dist/components/ViroSceneNavigator.d.ts +0 -24
- package/fabric-interop/dist/components/ViroSceneNavigator.d.ts.map +0 -1
- package/fabric-interop/dist/components/ViroSceneNavigator.js +0 -74
- package/fabric-interop/dist/components/ViroSceneNavigator.js.map +0 -1
- package/fabric-interop/dist/components/ViroSkyBox.d.ts +0 -40
- package/fabric-interop/dist/components/ViroSkyBox.d.ts.map +0 -1
- package/fabric-interop/dist/components/ViroSkyBox.js +0 -46
- package/fabric-interop/dist/components/ViroSkyBox.js.map +0 -1
- package/fabric-interop/dist/components/ViroSound.d.ts +0 -24
- package/fabric-interop/dist/components/ViroSound.d.ts.map +0 -1
- package/fabric-interop/dist/components/ViroSound.js +0 -48
- package/fabric-interop/dist/components/ViroSound.js.map +0 -1
- package/fabric-interop/dist/components/ViroSoundField.d.ts +0 -25
- package/fabric-interop/dist/components/ViroSoundField.d.ts.map +0 -1
- package/fabric-interop/dist/components/ViroSoundField.js +0 -49
- package/fabric-interop/dist/components/ViroSoundField.js.map +0 -1
- package/fabric-interop/dist/components/ViroSpatialSound.d.ts +0 -28
- package/fabric-interop/dist/components/ViroSpatialSound.d.ts.map +0 -1
- package/fabric-interop/dist/components/ViroSpatialSound.js +0 -52
- package/fabric-interop/dist/components/ViroSpatialSound.js.map +0 -1
- package/fabric-interop/dist/components/ViroSphere.d.ts +0 -23
- package/fabric-interop/dist/components/ViroSphere.d.ts.map +0 -1
- package/fabric-interop/dist/components/ViroSphere.js +0 -51
- package/fabric-interop/dist/components/ViroSphere.js.map +0 -1
- package/fabric-interop/dist/components/ViroSpinner.d.ts +0 -19
- package/fabric-interop/dist/components/ViroSpinner.d.ts.map +0 -1
- package/fabric-interop/dist/components/ViroSpinner.js +0 -47
- package/fabric-interop/dist/components/ViroSpinner.js.map +0 -1
- package/fabric-interop/dist/components/ViroSpotLight.d.ts +0 -31
- package/fabric-interop/dist/components/ViroSpotLight.d.ts.map +0 -1
- package/fabric-interop/dist/components/ViroSpotLight.js +0 -59
- package/fabric-interop/dist/components/ViroSpotLight.js.map +0 -1
- package/fabric-interop/dist/components/ViroSurface.d.ts +0 -39
- package/fabric-interop/dist/components/ViroSurface.d.ts.map +0 -1
- package/fabric-interop/dist/components/ViroSurface.js +0 -50
- package/fabric-interop/dist/components/ViroSurface.js.map +0 -1
- package/fabric-interop/dist/components/ViroText.d.ts +0 -37
- package/fabric-interop/dist/components/ViroText.d.ts.map +0 -1
- package/fabric-interop/dist/components/ViroText.js +0 -61
- package/fabric-interop/dist/components/ViroText.js.map +0 -1
- package/fabric-interop/dist/components/ViroUtils.d.ts +0 -64
- package/fabric-interop/dist/components/ViroUtils.d.ts.map +0 -1
- package/fabric-interop/dist/components/ViroUtils.js +0 -141
- package/fabric-interop/dist/components/ViroUtils.js.map +0 -1
- package/fabric-interop/dist/components/ViroVRSceneNavigator.d.ts +0 -26
- package/fabric-interop/dist/components/ViroVRSceneNavigator.d.ts.map +0 -1
- package/fabric-interop/dist/components/ViroVRSceneNavigator.js +0 -74
- package/fabric-interop/dist/components/ViroVRSceneNavigator.js.map +0 -1
- package/fabric-interop/dist/components/ViroVideo.d.ts +0 -33
- package/fabric-interop/dist/components/ViroVideo.d.ts.map +0 -1
- package/fabric-interop/dist/components/ViroVideo.js +0 -54
- package/fabric-interop/dist/components/ViroVideo.js.map +0 -1
- package/fabric-interop/dist/components/index.d.ts +0 -63
- package/fabric-interop/dist/components/index.d.ts.map +0 -1
- package/fabric-interop/dist/components/index.js +0 -145
- package/fabric-interop/dist/components/index.js.map +0 -1
- package/fabric-interop/dist/index.d.ts +0 -15
- package/fabric-interop/dist/index.d.ts.map +0 -1
- package/fabric-interop/dist/index.js +0 -118
- package/fabric-interop/dist/index.js.map +0 -1
- package/fabric-interop/dist/specs/ViroEventsTurboModule.d.ts +0 -20
- package/fabric-interop/dist/specs/ViroEventsTurboModule.d.ts.map +0 -1
- package/fabric-interop/dist/specs/ViroEventsTurboModule.js +0 -12
- package/fabric-interop/dist/specs/ViroEventsTurboModule.js.map +0 -1
- package/fabric-interop/examples/BasicSceneExample.tsx +0 -287
- package/fabric-interop/examples/ComprehensiveExample.tsx +0 -441
- package/fabric-interop/examples/SimpleARExample.tsx +0 -95
- package/fabric-interop/global.d.ts +0 -14
- package/fabric-interop/index.ts +0 -107
- package/fabric-interop/metro.config.js +0 -12
- package/fabric-interop/package.json +0 -40
- package/fabric-interop/react-native.config.js +0 -22
- package/fabric-interop/scripts/validate-build.js +0 -393
- package/fabric-interop/scripts/validate-implementation.js +0 -272
- package/fabric-interop/specs/README.md +0 -22
- package/fabric-interop/specs/ViroEventsTurboModule.ts +0 -27
- package/fabric-interop/test/BasicFunctionalityTest.tsx +0 -243
- package/fabric-interop/tsconfig.json +0 -38
- package/fabric.d.ts +0 -5
- package/fabric.ts +0 -14
- package/scripts/copy-types.js +0 -46
|
@@ -1,73 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
/**
|
|
3
|
-
* ViroVRSceneNavigator
|
|
4
|
-
*
|
|
5
|
-
* A component for rendering VR scenes.
|
|
6
|
-
*/
|
|
7
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
8
|
-
if (k2 === undefined) k2 = k;
|
|
9
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
10
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
11
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
12
|
-
}
|
|
13
|
-
Object.defineProperty(o, k2, desc);
|
|
14
|
-
}) : (function(o, m, k, k2) {
|
|
15
|
-
if (k2 === undefined) k2 = k;
|
|
16
|
-
o[k2] = m[k];
|
|
17
|
-
}));
|
|
18
|
-
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
19
|
-
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
20
|
-
}) : function(o, v) {
|
|
21
|
-
o["default"] = v;
|
|
22
|
-
});
|
|
23
|
-
var __importStar = (this && this.__importStar) || (function () {
|
|
24
|
-
var ownKeys = function(o) {
|
|
25
|
-
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
26
|
-
var ar = [];
|
|
27
|
-
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
28
|
-
return ar;
|
|
29
|
-
};
|
|
30
|
-
return ownKeys(o);
|
|
31
|
-
};
|
|
32
|
-
return function (mod) {
|
|
33
|
-
if (mod && mod.__esModule) return mod;
|
|
34
|
-
var result = {};
|
|
35
|
-
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
36
|
-
__setModuleDefault(result, mod);
|
|
37
|
-
return result;
|
|
38
|
-
};
|
|
39
|
-
})();
|
|
40
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
41
|
-
exports.ViroVRSceneNavigator = void 0;
|
|
42
|
-
const react_1 = __importStar(require("react"));
|
|
43
|
-
const ViroFabricContainer_1 = require("../ViroFabricContainer");
|
|
44
|
-
const ViroGlobal_1 = require("./ViroGlobal");
|
|
45
|
-
/**
|
|
46
|
-
* ViroVRSceneNavigator is a component for rendering VR scenes.
|
|
47
|
-
* It provides a container for VR scenes and handles the VR session lifecycle.
|
|
48
|
-
*/
|
|
49
|
-
const ViroVRSceneNavigator = (props) => {
|
|
50
|
-
const [apiKey] = (0, react_1.useState)(() => {
|
|
51
|
-
// Generate a random API key for demo purposes
|
|
52
|
-
return `viro-${Math.random().toString(36).substring(2, 15)}`;
|
|
53
|
-
});
|
|
54
|
-
// Initialize VR scene
|
|
55
|
-
(0, react_1.useEffect)(() => {
|
|
56
|
-
const nativeViro = (0, ViroGlobal_1.getNativeViro)();
|
|
57
|
-
if (!nativeViro)
|
|
58
|
-
return;
|
|
59
|
-
// Initialize Viro
|
|
60
|
-
nativeViro.initialize();
|
|
61
|
-
// Cleanup when unmounting
|
|
62
|
-
return () => {
|
|
63
|
-
// Cleanup code here
|
|
64
|
-
};
|
|
65
|
-
}, []);
|
|
66
|
-
// Create the scene component
|
|
67
|
-
const SceneComponent = props.initialScene.scene;
|
|
68
|
-
// Render the VR scene
|
|
69
|
-
return (<ViroFabricContainer_1.ViroFabricContainer style={props.style} debug={false} arEnabled={false} onCameraTransformUpdate={props.onCameraTransformUpdate}>
|
|
70
|
-
<SceneComponent />
|
|
71
|
-
</ViroFabricContainer_1.ViroFabricContainer>);
|
|
72
|
-
};
|
|
73
|
-
exports.ViroVRSceneNavigator = ViroVRSceneNavigator;
|
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* ViroVideo
|
|
3
|
-
*
|
|
4
|
-
* A component for displaying video content in 3D space.
|
|
5
|
-
*/
|
|
6
|
-
import React from "react";
|
|
7
|
-
import { ViroCommonProps } from "./ViroUtils";
|
|
8
|
-
export interface ViroVideoProps extends ViroCommonProps {
|
|
9
|
-
source: {
|
|
10
|
-
uri: string;
|
|
11
|
-
} | number;
|
|
12
|
-
width?: number;
|
|
13
|
-
height?: number;
|
|
14
|
-
loop?: boolean;
|
|
15
|
-
muted?: boolean;
|
|
16
|
-
volume?: number;
|
|
17
|
-
paused?: boolean;
|
|
18
|
-
resizeMode?: "ScaleToFill" | "ScaleToFit" | "StretchToFill";
|
|
19
|
-
stereoMode?: "LeftRight" | "RightLeft" | "TopBottom" | "BottomTop" | "None";
|
|
20
|
-
materials?: string | string[];
|
|
21
|
-
lightReceivingBitMask?: number;
|
|
22
|
-
shadowCastingBitMask?: number;
|
|
23
|
-
onBufferStart?: () => void;
|
|
24
|
-
onBufferEnd?: () => void;
|
|
25
|
-
onFinish?: () => void;
|
|
26
|
-
onUpdateTime?: (currentTime: number, totalTime: number) => void;
|
|
27
|
-
onError?: (error: string) => void;
|
|
28
|
-
}
|
|
29
|
-
/**
|
|
30
|
-
* ViroVideo is a component for displaying video content in 3D space.
|
|
31
|
-
*/
|
|
32
|
-
export declare const ViroVideo: React.FC<ViroVideoProps>;
|
|
@@ -1,52 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
/**
|
|
3
|
-
* ViroVideo
|
|
4
|
-
*
|
|
5
|
-
* A component for displaying video content in 3D space.
|
|
6
|
-
*/
|
|
7
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
8
|
-
exports.ViroVideo = void 0;
|
|
9
|
-
const ViroUtils_1 = require("./ViroUtils");
|
|
10
|
-
/**
|
|
11
|
-
* ViroVideo is a component for displaying video content in 3D space.
|
|
12
|
-
*/
|
|
13
|
-
const ViroVideo = (props) => {
|
|
14
|
-
// Convert common props to the format expected by the native code
|
|
15
|
-
const nativeProps = {
|
|
16
|
-
...(0, ViroUtils_1.convertCommonProps)(props),
|
|
17
|
-
source: props.source,
|
|
18
|
-
width: props.width,
|
|
19
|
-
height: props.height,
|
|
20
|
-
loop: props.loop,
|
|
21
|
-
muted: props.muted,
|
|
22
|
-
volume: props.volume,
|
|
23
|
-
paused: props.paused,
|
|
24
|
-
resizeMode: props.resizeMode,
|
|
25
|
-
stereoMode: props.stereoMode,
|
|
26
|
-
materials: props.materials,
|
|
27
|
-
lightReceivingBitMask: props.lightReceivingBitMask,
|
|
28
|
-
shadowCastingBitMask: props.shadowCastingBitMask,
|
|
29
|
-
};
|
|
30
|
-
// Create the node (parent will be determined by context)
|
|
31
|
-
const nodeId = (0, ViroUtils_1.useViroNode)("video", nativeProps);
|
|
32
|
-
// Register event handlers using our new event system
|
|
33
|
-
(0, ViroUtils_1.useViroEventListeners)(nodeId, {
|
|
34
|
-
onHover: props.onHover,
|
|
35
|
-
onClick: props.onClick,
|
|
36
|
-
onClickState: props.onClickState,
|
|
37
|
-
onTouch: props.onTouch,
|
|
38
|
-
onScroll: props.onScroll,
|
|
39
|
-
onSwipe: props.onSwipe,
|
|
40
|
-
onDrag: props.onDrag,
|
|
41
|
-
onPinch: props.onPinch,
|
|
42
|
-
onRotate: props.onRotate,
|
|
43
|
-
onFuse: typeof props.onFuse === "function"
|
|
44
|
-
? props.onFuse
|
|
45
|
-
: props.onFuse?.callback,
|
|
46
|
-
onCollision: props.onCollision,
|
|
47
|
-
onTransformUpdate: props.onTransformUpdate,
|
|
48
|
-
});
|
|
49
|
-
// Component doesn't have children, so just return null
|
|
50
|
-
return null;
|
|
51
|
-
};
|
|
52
|
-
exports.ViroVideo = ViroVideo;
|
|
@@ -1,62 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Viro Component Wrappers
|
|
3
|
-
*
|
|
4
|
-
* This module exports React components that maintain the same API as the original
|
|
5
|
-
* Viro components but use the Fabric interop layer internally.
|
|
6
|
-
*/
|
|
7
|
-
export { ViroNode } from "./ViroNode";
|
|
8
|
-
export { ViroScene } from "./ViroScene";
|
|
9
|
-
export { ViroARScene } from "./ViroARScene";
|
|
10
|
-
export { ViroFlexView } from "./ViroFlexView";
|
|
11
|
-
export { ViroBox } from "./ViroBox";
|
|
12
|
-
export { ViroSphere } from "./ViroSphere";
|
|
13
|
-
export { Viro3DObject } from "./Viro3DObject";
|
|
14
|
-
export { ViroGeometry } from "./ViroGeometry";
|
|
15
|
-
export { ViroQuad } from "./ViroQuad";
|
|
16
|
-
export { ViroPolygon } from "./ViroPolygon";
|
|
17
|
-
export { ViroPolyline } from "./ViroPolyline";
|
|
18
|
-
export { ViroSurface } from "./ViroSurface";
|
|
19
|
-
export { ViroText } from "./ViroText";
|
|
20
|
-
export { ViroImage } from "./ViroImage";
|
|
21
|
-
export { ViroVideo } from "./ViroVideo";
|
|
22
|
-
export { ViroAnimatedImage } from "./ViroAnimatedImage";
|
|
23
|
-
export { Viro360Image } from "./Viro360Image";
|
|
24
|
-
export { Viro360Video } from "./Viro360Video";
|
|
25
|
-
export { ViroSkyBox } from "./ViroSkyBox";
|
|
26
|
-
export { ViroPortal } from "./ViroPortal";
|
|
27
|
-
export { ViroPortalScene } from "./ViroPortalScene";
|
|
28
|
-
export { ViroAmbientLight } from "./ViroAmbientLight";
|
|
29
|
-
export { ViroDirectionalLight } from "./ViroDirectionalLight";
|
|
30
|
-
export { ViroSpotLight } from "./ViroSpotLight";
|
|
31
|
-
export { ViroOmniLight } from "./ViroOmniLight";
|
|
32
|
-
export { ViroLightingEnvironment } from "./ViroLightingEnvironment";
|
|
33
|
-
export { ViroCamera } from "./ViroCamera";
|
|
34
|
-
export { ViroOrbitCamera } from "./ViroOrbitCamera";
|
|
35
|
-
export { ViroSound } from "./ViroSound";
|
|
36
|
-
export { ViroSoundField } from "./ViroSoundField";
|
|
37
|
-
export { ViroSpatialSound } from "./ViroSpatialSound";
|
|
38
|
-
export { ViroButton } from "./ViroButton";
|
|
39
|
-
export { ViroController } from "./ViroController";
|
|
40
|
-
export { ViroSpinner } from "./ViroSpinner";
|
|
41
|
-
export { ViroParticleEmitter } from "./ViroParticleEmitter";
|
|
42
|
-
export { ViroAnimatedComponent } from "./ViroAnimatedComponent";
|
|
43
|
-
export { ViroMaterialVideo } from "./ViroMaterialVideo";
|
|
44
|
-
export { ViroSceneNavigator } from "./ViroSceneNavigator";
|
|
45
|
-
export { ViroVRSceneNavigator } from "./ViroVRSceneNavigator";
|
|
46
|
-
export { ViroARSceneNavigator } from "./ViroARSceneNavigator";
|
|
47
|
-
export { Viro3DSceneNavigator } from "./Viro3DSceneNavigator";
|
|
48
|
-
export { ViroARCamera } from "./ViroARCamera";
|
|
49
|
-
export { ViroARPlane } from "./AR/ViroARPlane";
|
|
50
|
-
export { ViroARPlaneSelector } from "./AR/ViroARPlaneSelector";
|
|
51
|
-
export { ViroARImageMarker } from "./ViroARImageMarker";
|
|
52
|
-
export { ViroARObjectMarker } from "./ViroARObjectMarker";
|
|
53
|
-
export * from "./ViroUtils";
|
|
54
|
-
export * from "./Animation/ViroAnimations";
|
|
55
|
-
import ViroAnimations from "./Animation/ViroAnimations";
|
|
56
|
-
export { ViroAnimations };
|
|
57
|
-
export * from "./Material/ViroMaterials";
|
|
58
|
-
import ViroMaterials from "./Material/ViroMaterials";
|
|
59
|
-
export { ViroMaterials };
|
|
60
|
-
export * from "./AR/ViroARTrackingTargets";
|
|
61
|
-
import ViroARTrackingTargets from "./AR/ViroARTrackingTargets";
|
|
62
|
-
export { ViroARTrackingTargets };
|
|
@@ -1,144 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
/**
|
|
3
|
-
* Viro Component Wrappers
|
|
4
|
-
*
|
|
5
|
-
* This module exports React components that maintain the same API as the original
|
|
6
|
-
* Viro components but use the Fabric interop layer internally.
|
|
7
|
-
*/
|
|
8
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
9
|
-
if (k2 === undefined) k2 = k;
|
|
10
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
11
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
12
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
13
|
-
}
|
|
14
|
-
Object.defineProperty(o, k2, desc);
|
|
15
|
-
}) : (function(o, m, k, k2) {
|
|
16
|
-
if (k2 === undefined) k2 = k;
|
|
17
|
-
o[k2] = m[k];
|
|
18
|
-
}));
|
|
19
|
-
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
20
|
-
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
21
|
-
};
|
|
22
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
23
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
24
|
-
};
|
|
25
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
26
|
-
exports.ViroARTrackingTargets = exports.ViroMaterials = exports.ViroAnimations = exports.ViroARObjectMarker = exports.ViroARImageMarker = exports.ViroARPlaneSelector = exports.ViroARPlane = exports.ViroARCamera = exports.Viro3DSceneNavigator = exports.ViroARSceneNavigator = exports.ViroVRSceneNavigator = exports.ViroSceneNavigator = exports.ViroMaterialVideo = exports.ViroAnimatedComponent = exports.ViroParticleEmitter = exports.ViroSpinner = exports.ViroController = exports.ViroButton = exports.ViroSpatialSound = exports.ViroSoundField = exports.ViroSound = exports.ViroOrbitCamera = exports.ViroCamera = exports.ViroLightingEnvironment = exports.ViroOmniLight = exports.ViroSpotLight = exports.ViroDirectionalLight = exports.ViroAmbientLight = exports.ViroPortalScene = exports.ViroPortal = exports.ViroSkyBox = exports.Viro360Video = exports.Viro360Image = exports.ViroAnimatedImage = exports.ViroVideo = exports.ViroImage = exports.ViroText = exports.ViroSurface = exports.ViroPolyline = exports.ViroPolygon = exports.ViroQuad = exports.ViroGeometry = exports.Viro3DObject = exports.ViroSphere = exports.ViroBox = exports.ViroFlexView = exports.ViroARScene = exports.ViroScene = exports.ViroNode = void 0;
|
|
27
|
-
// Basic components
|
|
28
|
-
var ViroNode_1 = require("./ViroNode");
|
|
29
|
-
Object.defineProperty(exports, "ViroNode", { enumerable: true, get: function () { return ViroNode_1.ViroNode; } });
|
|
30
|
-
var ViroScene_1 = require("./ViroScene");
|
|
31
|
-
Object.defineProperty(exports, "ViroScene", { enumerable: true, get: function () { return ViroScene_1.ViroScene; } });
|
|
32
|
-
var ViroARScene_1 = require("./ViroARScene");
|
|
33
|
-
Object.defineProperty(exports, "ViroARScene", { enumerable: true, get: function () { return ViroARScene_1.ViroARScene; } });
|
|
34
|
-
var ViroFlexView_1 = require("./ViroFlexView");
|
|
35
|
-
Object.defineProperty(exports, "ViroFlexView", { enumerable: true, get: function () { return ViroFlexView_1.ViroFlexView; } });
|
|
36
|
-
// 3D primitives
|
|
37
|
-
var ViroBox_1 = require("./ViroBox");
|
|
38
|
-
Object.defineProperty(exports, "ViroBox", { enumerable: true, get: function () { return ViroBox_1.ViroBox; } });
|
|
39
|
-
var ViroSphere_1 = require("./ViroSphere");
|
|
40
|
-
Object.defineProperty(exports, "ViroSphere", { enumerable: true, get: function () { return ViroSphere_1.ViroSphere; } });
|
|
41
|
-
var Viro3DObject_1 = require("./Viro3DObject");
|
|
42
|
-
Object.defineProperty(exports, "Viro3DObject", { enumerable: true, get: function () { return Viro3DObject_1.Viro3DObject; } });
|
|
43
|
-
var ViroGeometry_1 = require("./ViroGeometry");
|
|
44
|
-
Object.defineProperty(exports, "ViroGeometry", { enumerable: true, get: function () { return ViroGeometry_1.ViroGeometry; } });
|
|
45
|
-
var ViroQuad_1 = require("./ViroQuad");
|
|
46
|
-
Object.defineProperty(exports, "ViroQuad", { enumerable: true, get: function () { return ViroQuad_1.ViroQuad; } });
|
|
47
|
-
var ViroPolygon_1 = require("./ViroPolygon");
|
|
48
|
-
Object.defineProperty(exports, "ViroPolygon", { enumerable: true, get: function () { return ViroPolygon_1.ViroPolygon; } });
|
|
49
|
-
var ViroPolyline_1 = require("./ViroPolyline");
|
|
50
|
-
Object.defineProperty(exports, "ViroPolyline", { enumerable: true, get: function () { return ViroPolyline_1.ViroPolyline; } });
|
|
51
|
-
var ViroSurface_1 = require("./ViroSurface");
|
|
52
|
-
Object.defineProperty(exports, "ViroSurface", { enumerable: true, get: function () { return ViroSurface_1.ViroSurface; } });
|
|
53
|
-
// 2D components
|
|
54
|
-
var ViroText_1 = require("./ViroText");
|
|
55
|
-
Object.defineProperty(exports, "ViroText", { enumerable: true, get: function () { return ViroText_1.ViroText; } });
|
|
56
|
-
var ViroImage_1 = require("./ViroImage");
|
|
57
|
-
Object.defineProperty(exports, "ViroImage", { enumerable: true, get: function () { return ViroImage_1.ViroImage; } });
|
|
58
|
-
var ViroVideo_1 = require("./ViroVideo");
|
|
59
|
-
Object.defineProperty(exports, "ViroVideo", { enumerable: true, get: function () { return ViroVideo_1.ViroVideo; } });
|
|
60
|
-
var ViroAnimatedImage_1 = require("./ViroAnimatedImage");
|
|
61
|
-
Object.defineProperty(exports, "ViroAnimatedImage", { enumerable: true, get: function () { return ViroAnimatedImage_1.ViroAnimatedImage; } });
|
|
62
|
-
// 360 components
|
|
63
|
-
var Viro360Image_1 = require("./Viro360Image");
|
|
64
|
-
Object.defineProperty(exports, "Viro360Image", { enumerable: true, get: function () { return Viro360Image_1.Viro360Image; } });
|
|
65
|
-
var Viro360Video_1 = require("./Viro360Video");
|
|
66
|
-
Object.defineProperty(exports, "Viro360Video", { enumerable: true, get: function () { return Viro360Video_1.Viro360Video; } });
|
|
67
|
-
var ViroSkyBox_1 = require("./ViroSkyBox");
|
|
68
|
-
Object.defineProperty(exports, "ViroSkyBox", { enumerable: true, get: function () { return ViroSkyBox_1.ViroSkyBox; } });
|
|
69
|
-
// Portal components
|
|
70
|
-
var ViroPortal_1 = require("./ViroPortal");
|
|
71
|
-
Object.defineProperty(exports, "ViroPortal", { enumerable: true, get: function () { return ViroPortal_1.ViroPortal; } });
|
|
72
|
-
var ViroPortalScene_1 = require("./ViroPortalScene");
|
|
73
|
-
Object.defineProperty(exports, "ViroPortalScene", { enumerable: true, get: function () { return ViroPortalScene_1.ViroPortalScene; } });
|
|
74
|
-
// Lights
|
|
75
|
-
var ViroAmbientLight_1 = require("./ViroAmbientLight");
|
|
76
|
-
Object.defineProperty(exports, "ViroAmbientLight", { enumerable: true, get: function () { return ViroAmbientLight_1.ViroAmbientLight; } });
|
|
77
|
-
var ViroDirectionalLight_1 = require("./ViroDirectionalLight");
|
|
78
|
-
Object.defineProperty(exports, "ViroDirectionalLight", { enumerable: true, get: function () { return ViroDirectionalLight_1.ViroDirectionalLight; } });
|
|
79
|
-
var ViroSpotLight_1 = require("./ViroSpotLight");
|
|
80
|
-
Object.defineProperty(exports, "ViroSpotLight", { enumerable: true, get: function () { return ViroSpotLight_1.ViroSpotLight; } });
|
|
81
|
-
var ViroOmniLight_1 = require("./ViroOmniLight");
|
|
82
|
-
Object.defineProperty(exports, "ViroOmniLight", { enumerable: true, get: function () { return ViroOmniLight_1.ViroOmniLight; } });
|
|
83
|
-
var ViroLightingEnvironment_1 = require("./ViroLightingEnvironment");
|
|
84
|
-
Object.defineProperty(exports, "ViroLightingEnvironment", { enumerable: true, get: function () { return ViroLightingEnvironment_1.ViroLightingEnvironment; } });
|
|
85
|
-
// Cameras
|
|
86
|
-
var ViroCamera_1 = require("./ViroCamera");
|
|
87
|
-
Object.defineProperty(exports, "ViroCamera", { enumerable: true, get: function () { return ViroCamera_1.ViroCamera; } });
|
|
88
|
-
var ViroOrbitCamera_1 = require("./ViroOrbitCamera");
|
|
89
|
-
Object.defineProperty(exports, "ViroOrbitCamera", { enumerable: true, get: function () { return ViroOrbitCamera_1.ViroOrbitCamera; } });
|
|
90
|
-
// Audio
|
|
91
|
-
var ViroSound_1 = require("./ViroSound");
|
|
92
|
-
Object.defineProperty(exports, "ViroSound", { enumerable: true, get: function () { return ViroSound_1.ViroSound; } });
|
|
93
|
-
var ViroSoundField_1 = require("./ViroSoundField");
|
|
94
|
-
Object.defineProperty(exports, "ViroSoundField", { enumerable: true, get: function () { return ViroSoundField_1.ViroSoundField; } });
|
|
95
|
-
var ViroSpatialSound_1 = require("./ViroSpatialSound");
|
|
96
|
-
Object.defineProperty(exports, "ViroSpatialSound", { enumerable: true, get: function () { return ViroSpatialSound_1.ViroSpatialSound; } });
|
|
97
|
-
// Interactive components
|
|
98
|
-
var ViroButton_1 = require("./ViroButton");
|
|
99
|
-
Object.defineProperty(exports, "ViroButton", { enumerable: true, get: function () { return ViroButton_1.ViroButton; } });
|
|
100
|
-
var ViroController_1 = require("./ViroController");
|
|
101
|
-
Object.defineProperty(exports, "ViroController", { enumerable: true, get: function () { return ViroController_1.ViroController; } });
|
|
102
|
-
var ViroSpinner_1 = require("./ViroSpinner");
|
|
103
|
-
Object.defineProperty(exports, "ViroSpinner", { enumerable: true, get: function () { return ViroSpinner_1.ViroSpinner; } });
|
|
104
|
-
// Effects
|
|
105
|
-
var ViroParticleEmitter_1 = require("./ViroParticleEmitter");
|
|
106
|
-
Object.defineProperty(exports, "ViroParticleEmitter", { enumerable: true, get: function () { return ViroParticleEmitter_1.ViroParticleEmitter; } });
|
|
107
|
-
var ViroAnimatedComponent_1 = require("./ViroAnimatedComponent");
|
|
108
|
-
Object.defineProperty(exports, "ViroAnimatedComponent", { enumerable: true, get: function () { return ViroAnimatedComponent_1.ViroAnimatedComponent; } });
|
|
109
|
-
var ViroMaterialVideo_1 = require("./ViroMaterialVideo");
|
|
110
|
-
Object.defineProperty(exports, "ViroMaterialVideo", { enumerable: true, get: function () { return ViroMaterialVideo_1.ViroMaterialVideo; } });
|
|
111
|
-
// Scene navigators
|
|
112
|
-
var ViroSceneNavigator_1 = require("./ViroSceneNavigator");
|
|
113
|
-
Object.defineProperty(exports, "ViroSceneNavigator", { enumerable: true, get: function () { return ViroSceneNavigator_1.ViroSceneNavigator; } });
|
|
114
|
-
var ViroVRSceneNavigator_1 = require("./ViroVRSceneNavigator");
|
|
115
|
-
Object.defineProperty(exports, "ViroVRSceneNavigator", { enumerable: true, get: function () { return ViroVRSceneNavigator_1.ViroVRSceneNavigator; } });
|
|
116
|
-
var ViroARSceneNavigator_1 = require("./ViroARSceneNavigator");
|
|
117
|
-
Object.defineProperty(exports, "ViroARSceneNavigator", { enumerable: true, get: function () { return ViroARSceneNavigator_1.ViroARSceneNavigator; } });
|
|
118
|
-
var Viro3DSceneNavigator_1 = require("./Viro3DSceneNavigator");
|
|
119
|
-
Object.defineProperty(exports, "Viro3DSceneNavigator", { enumerable: true, get: function () { return Viro3DSceneNavigator_1.Viro3DSceneNavigator; } });
|
|
120
|
-
// AR components
|
|
121
|
-
var ViroARCamera_1 = require("./ViroARCamera");
|
|
122
|
-
Object.defineProperty(exports, "ViroARCamera", { enumerable: true, get: function () { return ViroARCamera_1.ViroARCamera; } });
|
|
123
|
-
var ViroARPlane_1 = require("./AR/ViroARPlane");
|
|
124
|
-
Object.defineProperty(exports, "ViroARPlane", { enumerable: true, get: function () { return ViroARPlane_1.ViroARPlane; } });
|
|
125
|
-
var ViroARPlaneSelector_1 = require("./AR/ViroARPlaneSelector");
|
|
126
|
-
Object.defineProperty(exports, "ViroARPlaneSelector", { enumerable: true, get: function () { return ViroARPlaneSelector_1.ViroARPlaneSelector; } });
|
|
127
|
-
var ViroARImageMarker_1 = require("./ViroARImageMarker");
|
|
128
|
-
Object.defineProperty(exports, "ViroARImageMarker", { enumerable: true, get: function () { return ViroARImageMarker_1.ViroARImageMarker; } });
|
|
129
|
-
var ViroARObjectMarker_1 = require("./ViroARObjectMarker");
|
|
130
|
-
Object.defineProperty(exports, "ViroARObjectMarker", { enumerable: true, get: function () { return ViroARObjectMarker_1.ViroARObjectMarker; } });
|
|
131
|
-
// Utilities
|
|
132
|
-
__exportStar(require("./ViroUtils"), exports);
|
|
133
|
-
// Animation utilities
|
|
134
|
-
__exportStar(require("./Animation/ViroAnimations"), exports);
|
|
135
|
-
const ViroAnimations_1 = __importDefault(require("./Animation/ViroAnimations"));
|
|
136
|
-
exports.ViroAnimations = ViroAnimations_1.default;
|
|
137
|
-
// Material utilities
|
|
138
|
-
__exportStar(require("./Material/ViroMaterials"), exports);
|
|
139
|
-
const ViroMaterials_1 = __importDefault(require("./Material/ViroMaterials"));
|
|
140
|
-
exports.ViroMaterials = ViroMaterials_1.default;
|
|
141
|
-
// AR utilities
|
|
142
|
-
__exportStar(require("./AR/ViroARTrackingTargets"), exports);
|
|
143
|
-
const ViroARTrackingTargets_1 = __importDefault(require("./AR/ViroARTrackingTargets"));
|
|
144
|
-
exports.ViroARTrackingTargets = ViroARTrackingTargets_1.default;
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* BasicSceneExample
|
|
3
|
-
*
|
|
4
|
-
* A simple example demonstrating the new fabric-interop system with:
|
|
5
|
-
* - Scene management and lifecycle
|
|
6
|
-
* - Property system with individual setters
|
|
7
|
-
* - Event system with JSI + fallback
|
|
8
|
-
* - Memory management integration
|
|
9
|
-
*/
|
|
10
|
-
import React from "react";
|
|
11
|
-
export declare const BasicSceneExample: React.FC;
|
|
@@ -1,244 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
/**
|
|
3
|
-
* BasicSceneExample
|
|
4
|
-
*
|
|
5
|
-
* A simple example demonstrating the new fabric-interop system with:
|
|
6
|
-
* - Scene management and lifecycle
|
|
7
|
-
* - Property system with individual setters
|
|
8
|
-
* - Event system with JSI + fallback
|
|
9
|
-
* - Memory management integration
|
|
10
|
-
*/
|
|
11
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
12
|
-
if (k2 === undefined) k2 = k;
|
|
13
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
14
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
15
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
16
|
-
}
|
|
17
|
-
Object.defineProperty(o, k2, desc);
|
|
18
|
-
}) : (function(o, m, k, k2) {
|
|
19
|
-
if (k2 === undefined) k2 = k;
|
|
20
|
-
o[k2] = m[k];
|
|
21
|
-
}));
|
|
22
|
-
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
23
|
-
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
24
|
-
}) : function(o, v) {
|
|
25
|
-
o["default"] = v;
|
|
26
|
-
});
|
|
27
|
-
var __importStar = (this && this.__importStar) || (function () {
|
|
28
|
-
var ownKeys = function(o) {
|
|
29
|
-
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
30
|
-
var ar = [];
|
|
31
|
-
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
32
|
-
return ar;
|
|
33
|
-
};
|
|
34
|
-
return ownKeys(o);
|
|
35
|
-
};
|
|
36
|
-
return function (mod) {
|
|
37
|
-
if (mod && mod.__esModule) return mod;
|
|
38
|
-
var result = {};
|
|
39
|
-
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
40
|
-
__setModuleDefault(result, mod);
|
|
41
|
-
return result;
|
|
42
|
-
};
|
|
43
|
-
})();
|
|
44
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
45
|
-
exports.BasicSceneExample = void 0;
|
|
46
|
-
const react_1 = __importStar(require("react"));
|
|
47
|
-
const react_native_1 = require("react-native");
|
|
48
|
-
const index_1 = require("../index");
|
|
49
|
-
const BasicSceneExample = () => {
|
|
50
|
-
const [sceneActive, setSceneActive] = (0, react_1.useState)(false);
|
|
51
|
-
const [memoryStats, setMemoryStats] = (0, react_1.useState)(null);
|
|
52
|
-
// Initialize materials and animations when component mounts
|
|
53
|
-
(0, react_1.useEffect)(() => {
|
|
54
|
-
// Create a red material for the box
|
|
55
|
-
(0, index_1.createMaterial)("redMaterial", {
|
|
56
|
-
diffuseColor: "#FF0000",
|
|
57
|
-
shininess: 2.0,
|
|
58
|
-
lightingModel: "Lambert",
|
|
59
|
-
});
|
|
60
|
-
// Create a blue material for the box
|
|
61
|
-
(0, index_1.createMaterial)("blueMaterial", {
|
|
62
|
-
diffuseColor: "#0000FF",
|
|
63
|
-
shininess: 2.0,
|
|
64
|
-
lightingModel: "Lambert",
|
|
65
|
-
});
|
|
66
|
-
// Create a rotation animation
|
|
67
|
-
(0, index_1.createAnimation)("spinAnimation", {
|
|
68
|
-
properties: {
|
|
69
|
-
rotateY: "+=360",
|
|
70
|
-
},
|
|
71
|
-
duration: 2000,
|
|
72
|
-
easing: "Linear",
|
|
73
|
-
});
|
|
74
|
-
// Create a scale animation
|
|
75
|
-
(0, index_1.createAnimation)("pulseAnimation", {
|
|
76
|
-
properties: {
|
|
77
|
-
scaleX: 1.5,
|
|
78
|
-
scaleY: 1.5,
|
|
79
|
-
scaleZ: 1.5,
|
|
80
|
-
},
|
|
81
|
-
duration: 1000,
|
|
82
|
-
easing: "EaseInEaseOut",
|
|
83
|
-
});
|
|
84
|
-
}, []);
|
|
85
|
-
// Handle scene initialization
|
|
86
|
-
const handleSceneInitialized = (success) => {
|
|
87
|
-
console.log("Scene initialized:", success);
|
|
88
|
-
setSceneActive(success);
|
|
89
|
-
if (success) {
|
|
90
|
-
react_native_1.Alert.alert("Success", "Viro scene initialized successfully!");
|
|
91
|
-
}
|
|
92
|
-
else {
|
|
93
|
-
react_native_1.Alert.alert("Error", "Failed to initialize Viro scene");
|
|
94
|
-
}
|
|
95
|
-
};
|
|
96
|
-
// Handle scene state changes
|
|
97
|
-
const handleSceneStateChanged = (event) => {
|
|
98
|
-
console.log("Scene state changed:", event);
|
|
99
|
-
};
|
|
100
|
-
// Handle memory warnings
|
|
101
|
-
const handleMemoryWarning = (event) => {
|
|
102
|
-
console.log("Memory warning received:", event.memoryStats);
|
|
103
|
-
setMemoryStats(event.memoryStats);
|
|
104
|
-
react_native_1.Alert.alert("Memory Warning", `Memory usage: ${event.memoryStats.usedMemoryMB?.toFixed(1) || "N/A"} MB`);
|
|
105
|
-
};
|
|
106
|
-
// Handle box click
|
|
107
|
-
const handleBoxClick = () => {
|
|
108
|
-
react_native_1.Alert.alert("Box Clicked", "The red box was clicked!");
|
|
109
|
-
// Execute spin animation
|
|
110
|
-
(0, index_1.executeAnimation)("box1", "spinAnimation", {
|
|
111
|
-
run: true,
|
|
112
|
-
loop: false,
|
|
113
|
-
});
|
|
114
|
-
};
|
|
115
|
-
// Handle box hover
|
|
116
|
-
const handleBoxHover = (isHovering) => {
|
|
117
|
-
console.log("Box hover:", isHovering);
|
|
118
|
-
if (isHovering) {
|
|
119
|
-
// Execute pulse animation on hover
|
|
120
|
-
(0, index_1.executeAnimation)("box1", "pulseAnimation", {
|
|
121
|
-
run: true,
|
|
122
|
-
loop: false,
|
|
123
|
-
});
|
|
124
|
-
}
|
|
125
|
-
};
|
|
126
|
-
// Get current memory stats
|
|
127
|
-
const checkMemoryStats = () => {
|
|
128
|
-
const stats = (0, index_1.getMemoryStats)();
|
|
129
|
-
setMemoryStats(stats);
|
|
130
|
-
if (stats) {
|
|
131
|
-
react_native_1.Alert.alert("Memory Stats", `Total Scenes: ${stats.totalScenes || 0}\n` +
|
|
132
|
-
`Active Scenes: ${stats.activeScenes || 0}\n` +
|
|
133
|
-
`Managed Nodes: ${stats.managedNodes || 0}\n` +
|
|
134
|
-
`Memory Usage: ${stats.usedMemoryMB?.toFixed(1) || "N/A"} MB`);
|
|
135
|
-
}
|
|
136
|
-
else {
|
|
137
|
-
react_native_1.Alert.alert("Memory Stats", "Memory statistics not available");
|
|
138
|
-
}
|
|
139
|
-
};
|
|
140
|
-
// Perform manual memory cleanup
|
|
141
|
-
const cleanupMemory = () => {
|
|
142
|
-
(0, index_1.performMemoryCleanup)();
|
|
143
|
-
react_native_1.Alert.alert("Memory Cleanup", "Memory cleanup performed");
|
|
144
|
-
};
|
|
145
|
-
return (<react_native_1.View style={styles.container}>
|
|
146
|
-
<react_native_1.Text style={styles.title}>Viro Fabric Interop Example</react_native_1.Text>
|
|
147
|
-
<react_native_1.Text style={styles.subtitle}>
|
|
148
|
-
Demonstrating New Architecture compatibility
|
|
149
|
-
</react_native_1.Text>
|
|
150
|
-
|
|
151
|
-
<react_native_1.View style={styles.controls}>
|
|
152
|
-
<react_native_1.Button title="Check Memory Stats" onPress={checkMemoryStats} disabled={!sceneActive}/>
|
|
153
|
-
<react_native_1.Button title="Cleanup Memory" onPress={cleanupMemory} disabled={!sceneActive}/>
|
|
154
|
-
</react_native_1.View>
|
|
155
|
-
|
|
156
|
-
{memoryStats && (<react_native_1.View style={styles.stats}>
|
|
157
|
-
<react_native_1.Text style={styles.statsTitle}>Memory Stats:</react_native_1.Text>
|
|
158
|
-
<react_native_1.Text>Total Scenes: {memoryStats.totalScenes || 0}</react_native_1.Text>
|
|
159
|
-
<react_native_1.Text>Active Scenes: {memoryStats.activeScenes || 0}</react_native_1.Text>
|
|
160
|
-
<react_native_1.Text>Managed Nodes: {memoryStats.managedNodes || 0}</react_native_1.Text>
|
|
161
|
-
<react_native_1.Text>
|
|
162
|
-
Memory Usage: {memoryStats.usedMemoryMB?.toFixed(1) || "N/A"} MB
|
|
163
|
-
</react_native_1.Text>
|
|
164
|
-
</react_native_1.View>)}
|
|
165
|
-
|
|
166
|
-
<index_1.ViroFabricContainer style={styles.viroContainer} debug={true} arEnabled={false} worldAlignment="Gravity" onInitialized={handleSceneInitialized} onSceneStateChanged={handleSceneStateChanged} onMemoryWarning={handleMemoryWarning}>
|
|
167
|
-
<index_1.ViroScene onSceneLoadStart={() => console.log("Scene load started")} onSceneLoadEnd={() => console.log("Scene load ended")} onSceneError={(error) => console.error("Scene error:", error)}>
|
|
168
|
-
{/* Red box with click and hover events */}
|
|
169
|
-
<index_1.ViroBox position={[-1, 0, -3]} scale={[0.5, 0.5, 0.5]} materials={["redMaterial"]} onClick={handleBoxClick} onHover={(isHovering) => handleBoxHover(isHovering)} canClick={true} canHover={true}/>
|
|
170
|
-
|
|
171
|
-
{/* Blue box with different position */}
|
|
172
|
-
<index_1.ViroBox position={[1, 0, -3]} scale={[0.5, 0.5, 0.5]} materials={["blueMaterial"]} onClick={() => react_native_1.Alert.alert("Blue Box", "Blue box clicked!")} canClick={true}/>
|
|
173
|
-
|
|
174
|
-
{/* Center box with animation */}
|
|
175
|
-
<index_1.ViroBox position={[0, 1, -3]} scale={[0.3, 0.3, 0.3]} materials={["redMaterial"]} animation={{
|
|
176
|
-
name: "spinAnimation",
|
|
177
|
-
run: true,
|
|
178
|
-
loop: true,
|
|
179
|
-
}}/>
|
|
180
|
-
</index_1.ViroScene>
|
|
181
|
-
</index_1.ViroFabricContainer>
|
|
182
|
-
|
|
183
|
-
<react_native_1.View style={styles.footer}>
|
|
184
|
-
<react_native_1.Text style={styles.footerText}>
|
|
185
|
-
Status: {sceneActive ? "Active" : "Initializing..."}
|
|
186
|
-
</react_native_1.Text>
|
|
187
|
-
<react_native_1.Text style={styles.footerText}>
|
|
188
|
-
Features: Scene Management • Property System • Event System • Memory
|
|
189
|
-
Management
|
|
190
|
-
</react_native_1.Text>
|
|
191
|
-
</react_native_1.View>
|
|
192
|
-
</react_native_1.View>);
|
|
193
|
-
};
|
|
194
|
-
exports.BasicSceneExample = BasicSceneExample;
|
|
195
|
-
const styles = react_native_1.StyleSheet.create({
|
|
196
|
-
container: {
|
|
197
|
-
flex: 1,
|
|
198
|
-
backgroundColor: "#f0f0f0",
|
|
199
|
-
},
|
|
200
|
-
title: {
|
|
201
|
-
fontSize: 20,
|
|
202
|
-
fontWeight: "bold",
|
|
203
|
-
textAlign: "center",
|
|
204
|
-
marginTop: 20,
|
|
205
|
-
marginBottom: 5,
|
|
206
|
-
},
|
|
207
|
-
subtitle: {
|
|
208
|
-
fontSize: 14,
|
|
209
|
-
textAlign: "center",
|
|
210
|
-
color: "#666",
|
|
211
|
-
marginBottom: 15,
|
|
212
|
-
},
|
|
213
|
-
controls: {
|
|
214
|
-
flexDirection: "row",
|
|
215
|
-
justifyContent: "space-around",
|
|
216
|
-
paddingHorizontal: 20,
|
|
217
|
-
marginBottom: 10,
|
|
218
|
-
},
|
|
219
|
-
stats: {
|
|
220
|
-
backgroundColor: "#fff",
|
|
221
|
-
margin: 10,
|
|
222
|
-
padding: 10,
|
|
223
|
-
borderRadius: 5,
|
|
224
|
-
borderWidth: 1,
|
|
225
|
-
borderColor: "#ddd",
|
|
226
|
-
},
|
|
227
|
-
statsTitle: {
|
|
228
|
-
fontWeight: "bold",
|
|
229
|
-
marginBottom: 5,
|
|
230
|
-
},
|
|
231
|
-
viroContainer: {
|
|
232
|
-
flex: 1,
|
|
233
|
-
backgroundColor: "#000",
|
|
234
|
-
},
|
|
235
|
-
footer: {
|
|
236
|
-
backgroundColor: "#333",
|
|
237
|
-
padding: 10,
|
|
238
|
-
},
|
|
239
|
-
footerText: {
|
|
240
|
-
color: "#fff",
|
|
241
|
-
textAlign: "center",
|
|
242
|
-
fontSize: 12,
|
|
243
|
-
},
|
|
244
|
-
});
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* ComprehensiveExample
|
|
3
|
-
*
|
|
4
|
-
* A comprehensive example demonstrating the updated fabric-interop system with:
|
|
5
|
-
* - Multiple component types (3D primitives, lights, text, images)
|
|
6
|
-
* - Scene management and lifecycle
|
|
7
|
-
* - Property system with individual setters
|
|
8
|
-
* - Event system with JSI + fallback
|
|
9
|
-
* - Memory management integration
|
|
10
|
-
* - Material and animation management
|
|
11
|
-
*/
|
|
12
|
-
import React from "react";
|
|
13
|
-
export declare const ComprehensiveExample: React.FC;
|