@vincentt-xr/sdk 2.0.0-alpha.0 → 2.0.0-alpha.2
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/GROUNDING.md +1813 -27
- package/dist/{DebuggerUI-CEfdddkZ.cjs → DebuggerUI-B45_Gb9d.cjs} +1 -1
- package/dist/{DebuggerUI-Dgop6Q6o.js → DebuggerUI-Cq28c18s.js} +1 -1
- package/dist/FaceMeshRenderer-6t8OsQhK.js +1195 -0
- package/dist/FaceMeshRenderer-lQLhYIW-.cjs +155 -0
- package/dist/FaceRetouch-CDrL0pXg.js +551 -0
- package/dist/FaceRetouch-DtNl8-4e.cjs +134 -0
- package/dist/audio/AudioEngine.d.ts +3 -1
- package/dist/audio/AudioPlayer.d.ts +29 -0
- package/dist/audio/AudioPlayerLogic.d.ts +4 -0
- package/dist/audio/index.d.ts +2 -0
- package/dist/components/Axes/index.d.ts +6 -0
- package/dist/components/FaceMesh/FaceMeshRenderer.d.ts +17 -0
- package/dist/components/FaceMesh/canonical/CanonicalFaceMeshRenderer.d.ts +22 -1
- package/dist/components/FaceMesh/canonical/FaceMeshMaterial.d.ts +25 -0
- package/dist/components/FaceMesh/canonical/assets.d.ts +3 -0
- package/dist/components/FaceMesh/canonical/geometryGroups.d.ts +9 -0
- package/dist/components/FaceMesh/canonical/parseCanonicalFaceModel.d.ts +2 -0
- package/dist/components/FaceMesh/canonical/shaders.d.ts +2 -0
- package/dist/components/FaceMesh/deform.d.ts +3 -0
- package/dist/components/FaceMesh/index.d.ts +5 -0
- package/dist/components/FaceMesh/material/defaults.d.ts +74 -0
- package/dist/components/FaceMesh/material/index.d.ts +1 -0
- package/dist/components/FaceMesh/material/options.d.ts +5 -1
- package/dist/components/FaceMesh/material/support.d.ts +7 -2
- package/dist/components/FaceMesh/material/textures.d.ts +4 -0
- package/dist/components/FaceMesh/material/types.d.ts +4 -2
- package/dist/components/FaceRetouch/Background.d.ts +9 -5
- package/dist/components/FaceRetouch/FaceRetouch.d.ts +47 -0
- package/dist/components/FaceRetouch/index.d.ts +2 -6
- package/dist/components/FaceRetouch/landmarkMask.d.ts +4 -6
- package/dist/components/FaceRetouch/useFaceRetouchMask.d.ts +4 -7
- package/dist/components/FaceTracker/index.d.ts +5 -3
- package/dist/components/FaceWarp3D/FaceWarp3DHead.d.ts +15 -0
- package/dist/components/FaceWarp3D/defaults.d.ts +37 -0
- package/dist/components/FaceWarp3D/index.d.ts +3 -0
- package/dist/components/FaceWarp3D/warp.d.ts +13 -0
- package/dist/components/HandJoints2D/index.d.ts +6 -0
- package/dist/components/HandTracker/index.d.ts +2 -2
- package/dist/components/HandTracking2D/HandVisual.d.ts +12 -0
- package/dist/components/HandTracking2D/index.d.ts +5 -0
- package/dist/components/HandTracking2DController/index.d.ts +5 -0
- package/dist/components/HandTracking3D/index.d.ts +6 -0
- package/dist/components/LightObject/index.d.ts +20 -0
- package/dist/components/LookAt/index.d.ts +23 -0
- package/dist/components/MeshRenderer/index.d.ts +58 -0
- package/dist/components/PerspectiveCamera/index.d.ts +2 -8
- package/dist/components/PinToMesh/index.d.ts +47 -0
- package/dist/components/RenderGroupLayer/index.d.ts +6 -0
- package/dist/components/SceneObjectRenderer/index.d.ts +16 -0
- package/dist/components/Screen2D/ScreenTransformFrame.d.ts +11 -0
- package/dist/components/Screen2D/ScreenTransformHelpers.d.ts +19 -0
- package/dist/components/Screen2D/ScreenTransformInteraction.d.ts +18 -0
- package/dist/components/Screen2D/index.d.ts +5 -0
- package/dist/components/ScreenGlass/defaults.d.ts +3 -0
- package/dist/components/ScreenGlass/index.d.ts +5 -0
- package/dist/components/ScreenGlass/shaders.d.ts +2 -0
- package/dist/components/ScreenGlass/types.d.ts +10 -0
- package/dist/components/ScreenGradient/defaults.d.ts +5 -0
- package/dist/components/ScreenGradient/index.d.ts +5 -0
- package/dist/components/ScreenGradient/shaders.d.ts +2 -0
- package/dist/components/ScreenGradient/types.d.ts +19 -0
- package/dist/components/ScreenImage/ScreenImage.d.ts +4 -0
- package/dist/components/ScreenImage/components/DynamicTextureSync.d.ts +9 -0
- package/dist/components/ScreenImage/components/ScreenImageBody.d.ts +9 -0
- package/dist/components/ScreenImage/components/ScreenImageFrame.d.ts +9 -0
- package/dist/components/ScreenImage/components/ScreenImageTransformFrame.d.ts +9 -0
- package/dist/components/ScreenImage/fit.d.ts +52 -0
- package/dist/components/ScreenImage/index.d.ts +8 -0
- package/dist/components/ScreenImage/materials/ScreenImageBlendMaterial.d.ts +9 -0
- package/dist/components/ScreenImage/materials/ScreenImageMatcap.d.ts +3 -0
- package/dist/components/ScreenImage/source.d.ts +16 -0
- package/dist/components/ScreenImage/types.d.ts +37 -0
- package/dist/components/ScreenImage/utils/ScreenImageConstants.d.ts +9 -0
- package/dist/components/ScreenImage/utils/ScreenImageHelpers.d.ts +4 -0
- package/dist/components/ScreenShape/geometry.d.ts +5 -0
- package/dist/components/ScreenShape/index.d.ts +5 -0
- package/dist/components/ScreenShape/types.d.ts +41 -0
- package/dist/components/ScreenSpaceUI/ScreenTransformGuide.d.ts +15 -0
- package/dist/components/ScreenSpaceUI/ScreenTransformOverlayGuide.d.ts +9 -0
- package/dist/components/ScreenSpaceUI/index.d.ts +2 -0
- package/dist/components/ScreenText/components/ScreenTextBody.d.ts +2 -0
- package/dist/components/ScreenText/components/ScreenTextTransformFrame.d.ts +9 -0
- package/dist/components/ScreenText/constants.d.ts +5 -0
- package/dist/components/ScreenText/index.d.ts +6 -0
- package/dist/components/ScreenText/types.d.ts +31 -0
- package/dist/components/ScreenText/utils/ScreenTextHelpers.d.ts +14 -0
- package/dist/components/ScreenText/utils/ScreenTextMappings.d.ts +17 -0
- package/dist/components/SequentialRenderPasses/index.d.ts +6 -0
- package/dist/components/TextLabel/TextLabel.d.ts +5 -0
- package/dist/components/TextLabel/alignment.d.ts +4 -0
- package/dist/components/TextLabel/bend.d.ts +9 -0
- package/dist/components/TextLabel/canvas/buildTextLabelTexture.d.ts +4 -0
- package/dist/components/TextLabel/canvas/canvasTypography.d.ts +13 -0
- package/dist/components/TextLabel/canvas/drawBackground.d.ts +21 -0
- package/dist/components/TextLabel/canvas/drawEffects.d.ts +34 -0
- package/dist/components/TextLabel/canvas/drawText.d.ts +19 -0
- package/dist/components/TextLabel/components/TextLabelMesh.d.ts +13 -0
- package/dist/components/TextLabel/constants.d.ts +2 -0
- package/dist/components/TextLabel/hooks/useTextLabelTexture.d.ts +7 -0
- package/dist/components/TextLabel/index.d.ts +2 -62
- package/dist/components/TextLabel/layout/measurement.d.ts +8 -0
- package/dist/components/TextLabel/layout/resolveTextLayout.d.ts +25 -0
- package/dist/components/TextLabel/layout/wrapText.d.ts +6 -0
- package/dist/components/TextLabel/types.d.ts +227 -0
- package/dist/components/TrackingAnchor/index.d.ts +18 -2
- package/dist/components/Transform3D/index.d.ts +30 -0
- package/dist/components/XRMediaSurface/index.d.ts +6 -6
- package/dist/components/XRScene/index.d.ts +14 -3
- package/dist/components/XRViewport/XRViewport.d.ts +11 -0
- package/dist/components/XRViewport/components/HiddenMedia.d.ts +7 -0
- package/dist/components/XRViewport/components/MediaAssetPicker.d.ts +8 -0
- package/dist/components/XRViewport/components/MediaControlStack.d.ts +13 -0
- package/dist/components/XRViewport/components/XRViewportLayers.d.ts +30 -0
- package/dist/components/XRViewport/constants.d.ts +24 -0
- package/dist/components/XRViewport/contexts.d.ts +6 -0
- package/dist/components/XRViewport/hooks/useViewportExternalFaces.d.ts +13 -0
- package/dist/components/XRViewport/hooks/useViewportMediaSource.d.ts +16 -0
- package/dist/components/XRViewport/hooks/useViewportMediaTexture.d.ts +10 -0
- package/dist/components/XRViewport/hooks/useViewportPipeline.d.ts +41 -0
- package/dist/components/XRViewport/hooks/useViewportRenderState.d.ts +47 -0
- package/dist/components/XRViewport/index.d.ts +3 -101
- package/dist/components/XRViewport/layout.d.ts +16 -0
- package/dist/components/XRViewport/slots.d.ts +16 -0
- package/dist/components/XRViewport/types.d.ts +89 -0
- package/dist/components/XRViewport/useViewportSize.d.ts +3 -0
- package/dist/components/index.d.ts +19 -0
- package/dist/contexts-BKvTIayr.cjs +1 -0
- package/dist/contexts-Bk5zz_VR.js +214 -0
- package/dist/debug-ui/component-editor/index.d.ts +19 -0
- package/dist/debug-ui/default-setting/index.d.ts +37 -0
- package/dist/debug-ui/default-setting.cjs +21 -0
- package/dist/debug-ui/default-setting.js +777 -0
- package/dist/debug-ui/face-mesh-renderer-settings/index.d.ts +8 -0
- package/dist/debug-ui/face-retouch/index.d.ts +11 -0
- package/dist/debug-ui/face-warp-3d/index.d.ts +6 -0
- package/dist/debug-ui/hand-joints-2d/index.d.ts +6 -0
- package/dist/debug-ui/hand-tracking-2d/index.d.ts +6 -0
- package/dist/debug-ui/hand-tracking-2d-controller/index.d.ts +6 -0
- package/dist/debug-ui/hand-tracking-3d/index.d.ts +6 -0
- package/dist/debug-ui/hierarchy-panel/index.d.ts +29 -0
- package/dist/debug-ui/index.d.ts +46 -0
- package/dist/debug-ui/layer-panel/index.d.ts +18 -0
- package/dist/debug-ui/media-source/MediaSourceSwitcher.d.ts +10 -0
- package/dist/debug-ui/media-source/index.d.ts +6 -0
- package/dist/debug-ui/media-source/media-preset.d.ts +9 -0
- package/dist/debug-ui/media-source/session.d.ts +12 -0
- package/dist/debug-ui/media-source.cjs +1 -0
- package/dist/debug-ui/media-source.js +9 -0
- package/dist/debug-ui/mesh-renderer-settings/index.d.ts +6 -0
- package/dist/debug-ui/object-inspector-panel/index.d.ts +25 -0
- package/dist/debug-ui/pin-to-mesh-settings/index.d.ts +10 -0
- package/dist/debug-ui/scene-editor/context.d.ts +38 -0
- package/dist/debug-ui/scene-editor/hierarchy-panel.d.ts +9 -0
- package/dist/debug-ui/scene-editor/index.d.ts +11 -0
- package/dist/debug-ui/scene-editor/inspector-panel.d.ts +7 -0
- package/dist/debug-ui/scene-editor/store-utils.d.ts +2 -0
- package/dist/debug-ui/scene-editor/viewport-toolbar.d.ts +4 -0
- package/dist/debug-ui/scene-editor/viewport.d.ts +21 -0
- package/dist/debug-ui/screen-glass-settings/index.d.ts +6 -0
- package/dist/debug-ui/screen-gradient-settings/GradientStopsEditor.d.ts +5 -0
- package/dist/debug-ui/screen-gradient-settings/index.d.ts +6 -0
- package/dist/debug-ui/screen-gradient-settings/styles.d.ts +3 -0
- package/dist/debug-ui/screen-image-settings/index.d.ts +9 -0
- package/dist/debug-ui/screen-shape-settings/index.d.ts +6 -0
- package/dist/debug-ui/screen-text-settings/NumberField.d.ts +9 -0
- package/dist/debug-ui/screen-text-settings/ScreenTextSettingsPanel.d.ts +3 -0
- package/dist/debug-ui/screen-text-settings/controls/NestedSection.d.ts +7 -0
- package/dist/debug-ui/screen-text-settings/controls/Section.d.ts +8 -0
- package/dist/debug-ui/screen-text-settings/controls/icons.d.ts +4 -0
- package/dist/debug-ui/screen-text-settings/index.d.ts +2 -0
- package/dist/debug-ui/screen-text-settings/sections/BackgroundSection.d.ts +8 -0
- package/dist/debug-ui/screen-text-settings/sections/ContentSection.d.ts +5 -0
- package/dist/debug-ui/screen-text-settings/sections/EffectsSection.d.ts +25 -0
- package/dist/debug-ui/screen-text-settings/sections/StyleSection.d.ts +5 -0
- package/dist/debug-ui/screen-text-settings/sections/TransformSection.d.ts +5 -0
- package/dist/debug-ui/screen-text-settings/sections/background/BackgroundFillControls.d.ts +2 -0
- package/dist/debug-ui/screen-text-settings/sections/background/BackgroundSizeControls.d.ts +2 -0
- package/dist/debug-ui/screen-text-settings/sections/background/BackgroundStrokeControls.d.ts +2 -0
- package/dist/debug-ui/screen-text-settings/sections/background/types.d.ts +7 -0
- package/dist/debug-ui/screen-text-settings/sections/effects/BendEffectSection.d.ts +4 -0
- package/dist/debug-ui/screen-text-settings/sections/effects/EffectChrome.d.ts +21 -0
- package/dist/debug-ui/screen-text-settings/sections/effects/GlowEffectSection.d.ts +4 -0
- package/dist/debug-ui/screen-text-settings/sections/effects/InnerShadowEffectSection.d.ts +4 -0
- package/dist/debug-ui/screen-text-settings/sections/effects/OutlineEffectSection.d.ts +4 -0
- package/dist/debug-ui/screen-text-settings/sections/effects/ShadowEffectSection.d.ts +4 -0
- package/dist/debug-ui/screen-text-settings/sections/effects/types.d.ts +14 -0
- package/dist/debug-ui/screen-text-settings/settings.d.ts +90 -0
- package/dist/debug-ui/screen-text-settings/styles.d.ts +26 -0
- package/dist/debug-ui/screen-text-settings/transform.d.ts +6 -0
- package/dist/debug-ui/screen-text-settings/types.d.ts +9 -0
- package/dist/debug-ui/settings-panel/index.d.ts +38 -0
- package/dist/debug-ui/shared/MaterialSection.d.ts +13 -0
- package/dist/debug-ui/shared/ScreenTransformSection.d.ts +32 -0
- package/dist/debug-ui/transform-3d-settings/index.d.ts +11 -0
- package/dist/debug-ui.cjs +10 -0
- package/dist/debug-ui.js +8861 -0
- package/dist/drawNormalizedCrop-B-7zU-Xw.cjs +1 -0
- package/dist/drawNormalizedCrop-CRdIDyl1.js +44 -0
- package/dist/entries/all.d.ts +1 -0
- package/dist/entries/core.d.ts +55 -4
- package/dist/entries/face-effects.d.ts +12 -8
- package/dist/entries/internal.d.ts +1 -1
- package/dist/entries/low-level.d.ts +21 -4
- package/dist/entries/scene-object.d.ts +10 -0
- package/dist/entries/tracking.d.ts +25 -2
- package/dist/face-action/index.d.ts +34 -0
- package/dist/face-attribute-expression/index.d.ts +10 -0
- package/dist/face-effects.cjs +1 -252
- package/dist/face-effects.js +1404 -2613
- package/dist/face-info/blendshapes.d.ts +3 -0
- package/dist/face-info/derive.d.ts +8 -0
- package/dist/face-info/drawFaceCrop.d.ts +10 -0
- package/dist/face-info/getFaceInfo.d.ts +8 -0
- package/dist/face-info/index.d.ts +8 -0
- package/dist/face-info/landmarks.d.ts +21 -0
- package/dist/face-info/types.d.ts +52 -0
- package/dist/getFaceInfo-CyPAKh3h.cjs +1 -0
- package/dist/getFaceInfo-hUKMLFcr.js +118 -0
- package/dist/hand/handJoints2d.d.ts +49 -0
- package/dist/hand/handTracking2d.d.ts +33 -0
- package/dist/hand/handTracking2dController.d.ts +65 -0
- package/dist/hand/handTracking3d.d.ts +52 -0
- package/dist/hooks/faceResults.d.ts +1 -1
- package/dist/hooks/useCalibrationFaceTracker.d.ts +1 -1
- package/dist/hooks/useFaceAction.d.ts +3 -0
- package/dist/hooks/useFaceAttributeExpression.d.ts +16 -0
- package/dist/hooks/useFaceDetection.d.ts +18 -0
- package/dist/hooks/useFaceInfo.d.ts +7 -0
- package/dist/hooks/useFaceInfos.d.ts +15 -0
- package/dist/hooks/useFaceResultReader.d.ts +10 -0
- package/dist/hooks/useFrameCapture.d.ts +18 -0
- package/dist/hooks/useMediaRecorder.d.ts +14 -2
- package/dist/hooks/useOwnedTexture.d.ts +6 -0
- package/dist/hooks/useTrackerContext.d.ts +2 -2
- package/dist/hooks/useXRSession/facade.d.ts +3 -0
- package/dist/hooks/useXRSession/registry.d.ts +9 -0
- package/dist/index-82aENaRq.cjs +1 -0
- package/dist/{index-BD-JWMjE.js → index-BgQAX8rs.js} +198 -134
- package/dist/index-CEc1CAmB.cjs +1 -0
- package/dist/index-CTHeBQOs.js +178 -0
- package/dist/index-D4bLzBr6.cjs +1 -0
- package/dist/index-DSpzjuqd.cjs +1 -0
- package/dist/index-Di70KWuY.js +2049 -0
- package/dist/index-DzEzkBIH.cjs +17 -0
- package/dist/{index-CYMj26Ej.js → index-JygePOwo.js} +565 -498
- package/dist/index-UC0Ux38E.js +111 -0
- package/dist/{internal-KOKJDxCG.js → internal-DuMPpcbp.js} +86 -80
- package/dist/internal-i2JkM85N.cjs +1 -0
- package/dist/internal.cjs +1 -1
- package/dist/internal.js +2 -2
- package/dist/low-level.cjs +1 -1
- package/dist/low-level.js +959 -632
- package/dist/main.cjs +1 -1
- package/dist/main.js +556 -455
- package/dist/material/MaterialFill.d.ts +20 -0
- package/dist/material/MeshMaterial.d.ts +14 -0
- package/dist/material/index.d.ts +2 -0
- package/dist/models/Body/index.d.ts +1 -1
- package/dist/models/Face/index.d.ts +1 -0
- package/dist/models/Face/rotation.d.ts +3 -0
- package/dist/models/Hand/HandTracking.d.ts +2 -0
- package/dist/render/layerStack.d.ts +29 -0
- package/dist/render/renderGroups.d.ts +47 -0
- package/dist/render/renderPasses.d.ts +18 -0
- package/dist/renderGroups-C9QJrAXu.js +152 -0
- package/dist/renderGroups-Dvm1J4lW.cjs +1 -0
- package/dist/renderLayers-lDtL0_43.cjs +1 -0
- package/dist/renderLayers-zrK2pv5O.js +13 -0
- package/dist/renderPasses-CT5iBwtg.cjs +21 -0
- package/dist/renderPasses-CjgG_6kQ.js +1500 -0
- package/dist/scene-object/index.d.ts +146 -0
- package/dist/scene-object/runtimeRegistry.d.ts +14 -0
- package/dist/scene-object.cjs +1 -0
- package/dist/scene-object.js +40 -0
- package/dist/screen-image/screenImagePresets.d.ts +13 -0
- package/dist/screen-image/screenImageSettings.d.ts +57 -0
- package/dist/screen-text/screenTextPresets.d.ts +6 -0
- package/dist/screen-text/screenTextSettings.d.ts +147 -0
- package/dist/screen2d/coordinates.d.ts +87 -0
- package/dist/screen2d/index.d.ts +7 -0
- package/dist/screen2d/material-runtime.d.ts +32 -0
- package/dist/screen2d/screenTransform.d.ts +47 -0
- package/dist/screen2d/smoothing.d.ts +5 -0
- package/dist/screen2d/texture.d.ts +10 -0
- package/dist/screen2d/transform.d.ts +25 -0
- package/dist/screen2d/types.d.ts +90 -0
- package/dist/{selectors-Bub0o3qy.cjs → selectors-2QvO5RYY.cjs} +1 -1
- package/dist/{selectors-BHO6TnoC.js → selectors-Dw3C-gSk.js} +5 -5
- package/dist/services/MetricsCollector/index.d.ts +7 -1
- package/dist/services/MetricsCollector/utils.d.ts +1 -1
- package/dist/session-BChR4TgK.cjs +31 -0
- package/dist/session-C1StwN0f.js +363 -0
- package/dist/texture/animatedTexture.d.ts +61 -0
- package/dist/texture/animationMath.d.ts +8 -0
- package/dist/texture/sourceResolver.d.ts +30 -0
- package/dist/tracking.cjs +1 -1
- package/dist/tracking.js +582 -298
- package/dist/types/face.d.ts +1 -13
- package/dist/types/hand-tracking.d.ts +8 -0
- package/dist/types/index.d.ts +0 -1
- package/dist/types/nodes.d.ts +4 -1
- package/dist/types/session.d.ts +2 -0
- package/dist/types/tracking.d.ts +8 -2
- package/dist/types/util-types.d.ts +1 -1
- package/dist/useFaceInfo-C-WfMlYp.cjs +1 -0
- package/dist/useFaceInfo-CwsHZedC.js +62 -0
- package/dist/useFaceResults-CkFc1egZ.js +19 -0
- package/dist/useFaceResults-VcFdOUFV.cjs +1 -0
- package/dist/utils/drawNormalizedCrop.d.ts +22 -0
- package/dist/utils/integrity.d.ts +4 -25
- package/dist/utils/landmarkBounds.d.ts +1 -1
- package/dist/utils/logger.d.ts +2 -2
- package/dist/x-Co8jPhP0.js +127 -0
- package/dist/x-KC8E4Gaj.cjs +41 -0
- package/docs/MIGRATION_GUIDE.md +589 -0
- package/docs/SDK_DOCUMENTATION.md +1155 -0
- package/docs/api/audio.mdx +36 -0
- package/docs/api/behavior-components.mdx +164 -0
- package/docs/api/capture-recording.mdx +103 -0
- package/docs/api/debug-ui-scene-editor.mdx +249 -0
- package/docs/api/face-actions.mdx +104 -0
- package/docs/api/face-attribute-expression.mdx +87 -0
- package/docs/api/face-binding-anchors.mdx +53 -0
- package/docs/api/face-effects.mdx +19 -0
- package/docs/api/face-info.mdx +112 -0
- package/docs/api/face-mesh.mdx +98 -0
- package/docs/api/face-painting.mdx +33 -0
- package/docs/api/face-retouching.mdx +73 -0
- package/docs/api/material-render-state.mdx +132 -0
- package/docs/api/runtime-3d.mdx +311 -0
- package/docs/api/scene-object-store.mdx +213 -0
- package/docs/api/screen-image.mdx +41 -0
- package/docs/api/screen-shape.mdx +64 -0
- package/docs/api/screen-space-coordinates.mdx +41 -0
- package/docs/api/screen-text.mdx +39 -0
- package/docs/api/texture-sources.mdx +55 -0
- package/docs/api/trackers.mdx +46 -0
- package/docs/docs.json +70 -0
- package/docs/examples/scene-object-recipes.mdx +194 -0
- package/docs/guides/harness-debug-ui.mdx +139 -0
- package/docs/inspector/hierarchy-panel.mdx +51 -0
- package/docs/inspector/object-inspector-panel.mdx +51 -0
- package/docs/introduction.mdx +121 -0
- package/docs/scene-objects/overview.mdx +127 -0
- package/docs/scene-objects/render-groups.mdx +77 -0
- package/docs/scene-objects/runtime-rendering.mdx +75 -0
- package/docs/texture-api-consumer.md +58 -0
- package/package.json +55 -7
- package/dist/components/FaceRetouch/retouchRegions.d.ts +0 -23
- package/dist/components/FaceRetouch/useFaceRetouchRegions.d.ts +0 -12
- package/dist/index-B5J4gzn2.cjs +0 -1
- package/dist/index-BVBVg96G.cjs +0 -1
- package/dist/index-DtwHElmG.js +0 -157
- package/dist/index-PtFmD6B8.cjs +0 -1
- package/dist/internal-DH5d1Xnq.cjs +0 -1
- package/dist/modules/XRClient/index.d.ts +0 -9
- package/dist/modules/index.d.ts +0 -1
- package/dist/services/ApiService.d.ts +0 -12
- package/dist/types/client.d.ts +0 -3
- package/dist/useFaceResults-cpsSmKKc.js +0 -81
- package/dist/useFaceResults-hVUJYSEY.cjs +0 -1
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
/** MediaPipe Face Landmarker blendshape category names. */
|
|
2
|
+
export declare const FACE_BLENDSHAPE_NAMES: readonly ["_neutral", "browDownLeft", "browDownRight", "browInnerUp", "browOuterUpLeft", "browOuterUpRight", "cheekPuff", "cheekSquintLeft", "cheekSquintRight", "eyeBlinkLeft", "eyeBlinkRight", "eyeLookDownLeft", "eyeLookDownRight", "eyeLookInLeft", "eyeLookInRight", "eyeLookOutLeft", "eyeLookOutRight", "eyeLookUpLeft", "eyeLookUpRight", "eyeSquintLeft", "eyeSquintRight", "eyeWideLeft", "eyeWideRight", "jawForward", "jawLeft", "jawOpen", "jawRight", "mouthClose", "mouthDimpleLeft", "mouthDimpleRight", "mouthFrownLeft", "mouthFrownRight", "mouthFunnel", "mouthLeft", "mouthLowerDownLeft", "mouthLowerDownRight", "mouthPressLeft", "mouthPressRight", "mouthPucker", "mouthRight", "mouthRollLower", "mouthRollUpper", "mouthShrugLower", "mouthShrugUpper", "mouthSmileLeft", "mouthSmileRight", "mouthStretchLeft", "mouthStretchRight", "mouthUpperUpLeft", "mouthUpperUpRight", "noseSneerLeft", "noseSneerRight"];
|
|
3
|
+
export type FaceBlendshapeName = (typeof FACE_BLENDSHAPE_NAMES)[number];
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { Category, NormalizedLandmark } from '@mediapipe/tasks-vision';
|
|
2
|
+
import { FaceBlendshapeName } from './blendshapes';
|
|
3
|
+
import { FaceInfo } from './types';
|
|
4
|
+
export declare const DEFAULT_FACE_EXPRESSION_THRESHOLD = 0.5;
|
|
5
|
+
export declare const writeFaceBlendshapes: (categories: readonly Category[] | undefined, target: Record<string, number>) => Record<string, number>;
|
|
6
|
+
export declare const getFaceBlendshape: (faceInfo: FaceInfo, name: FaceBlendshapeName) => number;
|
|
7
|
+
export declare const hasFaceExpression: (faceInfo: FaceInfo, name: FaceBlendshapeName, threshold?: number) => boolean;
|
|
8
|
+
export declare const getFaceEyeDistance: (landmarks: readonly NormalizedLandmark[]) => number;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { CropOutputSize } from '../utils/drawNormalizedCrop';
|
|
2
|
+
import { FaceInfo } from './types';
|
|
3
|
+
export type DrawFaceCropOptions = {
|
|
4
|
+
source: CanvasImageSource;
|
|
5
|
+
face: FaceInfo;
|
|
6
|
+
canvas: HTMLCanvasElement;
|
|
7
|
+
outputSize: CropOutputSize;
|
|
8
|
+
padding?: number;
|
|
9
|
+
};
|
|
10
|
+
export declare const drawFaceCrop: ({ source, face, canvas, outputSize, padding, }: DrawFaceCropOptions) => boolean;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { FaceLandmarkerResult } from '@mediapipe/tasks-vision';
|
|
2
|
+
import { XRModelNodeFaceTracking } from '../types/nodes';
|
|
3
|
+
import { FaceInfo, FaceInfoTarget } from './types';
|
|
4
|
+
/** Creates reusable storage for allocation-free `getFaceInfo` reads in `useFrame`. */
|
|
5
|
+
export declare const createFaceInfoTarget: () => FaceInfoTarget;
|
|
6
|
+
export declare const getFaceInfoFromResults: (node: XRModelNodeFaceTracking, results: FaceLandmarkerResult, faceIndex?: number, target?: FaceInfoTarget) => FaceInfo | null;
|
|
7
|
+
/** Reads the current face. Pass a reusable target on per-frame hot paths. */
|
|
8
|
+
export declare const getFaceInfo: (node: XRModelNodeFaceTracking, faceIndex?: number, target?: FaceInfoTarget) => FaceInfo | null;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
export { DEFAULT_FACE_EXPRESSION_THRESHOLD, getFaceBlendshape, getFaceEyeDistance, hasFaceExpression, } from './derive';
|
|
2
|
+
export { FACE_BLENDSHAPE_NAMES } from './blendshapes';
|
|
3
|
+
export { createFaceInfoTarget, getFaceInfo } from './getFaceInfo';
|
|
4
|
+
export { drawFaceCrop } from './drawFaceCrop';
|
|
5
|
+
export type { DrawFaceCropOptions } from './drawFaceCrop';
|
|
6
|
+
export { FACE_LANDMARK_INDICES } from './landmarks';
|
|
7
|
+
export type { FaceBlendshapeName } from './blendshapes';
|
|
8
|
+
export type { FaceInfo, FaceInfoTarget, FaceVector3 } from './types';
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { NormalizedLandmark } from '@mediapipe/tasks-vision';
|
|
2
|
+
import { FaceCustomAnchorPoint, FaceTarget } from '../types/tracking';
|
|
3
|
+
/** MediaPipe canonical face-mesh indices. Left/right follow the person's perspective. */
|
|
4
|
+
export declare const FACE_LANDMARK_INDICES: {
|
|
5
|
+
readonly "face.forehead": 10;
|
|
6
|
+
readonly "face.noseTip": 1;
|
|
7
|
+
readonly "face.chin": 152;
|
|
8
|
+
readonly "face.leftEyeOuter": 263;
|
|
9
|
+
readonly "face.rightEyeOuter": 33;
|
|
10
|
+
readonly "face.leftCheek": 425;
|
|
11
|
+
readonly "face.rightCheek": 205;
|
|
12
|
+
readonly "face.mouthCenter": 13;
|
|
13
|
+
readonly "face.leftEarlobe": 454;
|
|
14
|
+
readonly "face.rightEarlobe": 234;
|
|
15
|
+
};
|
|
16
|
+
/** Resolves a semantic face target in normalized tracker-input coordinates. */
|
|
17
|
+
export declare const resolveFaceAnchorPoint: (faceTarget: FaceTarget, landmarks: readonly NormalizedLandmark[], customAnchorPoint?: FaceCustomAnchorPoint, target?: NormalizedLandmark) => NormalizedLandmark | null;
|
|
18
|
+
export declare const FACE_EYE_DISTANCE_LANDMARKS: {
|
|
19
|
+
readonly left: 263;
|
|
20
|
+
readonly right: 33;
|
|
21
|
+
};
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
import { NormalizedLandmark } from '@mediapipe/tasks-vision';
|
|
2
|
+
import { FaceBounds } from '../types/face';
|
|
3
|
+
import { FaceBlendshapeName } from './blendshapes';
|
|
4
|
+
export type FaceVector3 = Readonly<{
|
|
5
|
+
x: number;
|
|
6
|
+
y: number;
|
|
7
|
+
z: number;
|
|
8
|
+
}>;
|
|
9
|
+
export type FaceInfo = {
|
|
10
|
+
/** Current result-array index. This is not a persistent identity. */
|
|
11
|
+
readonly index: number;
|
|
12
|
+
/** MediaPipe landmarks in normalized tracker-input coordinates; top-left origin. */
|
|
13
|
+
readonly landmarks: readonly NormalizedLandmark[];
|
|
14
|
+
/** Axis-aligned bounds in the same normalized tracker-input coordinates. */
|
|
15
|
+
readonly bounds: Readonly<FaceBounds>;
|
|
16
|
+
readonly pose: {
|
|
17
|
+
/** Three.js world position from the existing face tracker. */
|
|
18
|
+
readonly position: FaceVector3;
|
|
19
|
+
/** Radians: X pitch (+up), Y yaw (+left), Z roll. */
|
|
20
|
+
readonly rotation: FaceVector3;
|
|
21
|
+
/** Smoothed uniform sizing heuristic used by the face occluder/tracker anchor. */
|
|
22
|
+
readonly scale: FaceVector3;
|
|
23
|
+
};
|
|
24
|
+
/** Outer-eye distance in normalized tracker-input coordinates. */
|
|
25
|
+
readonly eyeDistance: number;
|
|
26
|
+
/** MediaPipe blendshape category names mapped to scores in [0, 1]. */
|
|
27
|
+
readonly blendshapes: Readonly<Partial<Record<FaceBlendshapeName, number>>>;
|
|
28
|
+
};
|
|
29
|
+
export type FaceInfoTarget = {
|
|
30
|
+
index: number;
|
|
31
|
+
landmarks: readonly NormalizedLandmark[];
|
|
32
|
+
bounds: FaceBounds;
|
|
33
|
+
pose: {
|
|
34
|
+
position: {
|
|
35
|
+
x: number;
|
|
36
|
+
y: number;
|
|
37
|
+
z: number;
|
|
38
|
+
};
|
|
39
|
+
rotation: {
|
|
40
|
+
x: number;
|
|
41
|
+
y: number;
|
|
42
|
+
z: number;
|
|
43
|
+
};
|
|
44
|
+
scale: {
|
|
45
|
+
x: number;
|
|
46
|
+
y: number;
|
|
47
|
+
z: number;
|
|
48
|
+
};
|
|
49
|
+
};
|
|
50
|
+
eyeDistance: number;
|
|
51
|
+
blendshapes: Record<string, number>;
|
|
52
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";const x=require("react"),b=require("./index-82aENaRq.cjs"),E=(e,t={minX:0,minY:0,maxX:0,maxY:0,width:0,height:0,centerX:0,centerY:0})=>{if(e.length===0)return t.minX=0,t.minY=0,t.maxX=0,t.maxY=0,t.width=0,t.height=0,t.centerX=0,t.centerY=0,t;let n=1,s=1,i=0,o=0;for(let l=0;l<e.length;l++){const{x:a,y:r}=e[l];a<n&&(n=a),r<s&&(s=r),a>i&&(i=a),r>o&&(o=r)}const c=Math.max(0,i-n),u=Math.max(0,o-s);return t.minX=n,t.minY=s,t.maxX=i,t.maxY=o,t.width=c,t.height=u,t.centerX=n+c*.5,t.centerY=s+u*.5,t},_=(e,t)=>e.map(n=>({landmarks:n,bounds:E(n)})),C={publishedCount:0,lastPublishAt:-1/0,lastNonEmptyAt:-1},I=(e,t,n,s,i)=>{if(t>0){const o={...e,lastNonEmptyAt:n};return n-e.lastPublishAt>=s?{action:"publish",state:{publishedCount:t,lastPublishAt:n,lastNonEmptyAt:n}}:{action:"none",state:o}}return e.publishedCount===0?{action:"none",state:e}:e.lastNonEmptyAt>=0&&n-e.lastNonEmptyAt<i?{action:"none",state:e}:{action:"clear",state:{publishedCount:0,lastPublishAt:-1/0,lastNonEmptyAt:e.lastNonEmptyAt}}},L=({enabled:e,holdMs:t,node:n,onFrame:s,prepare:i,throttleMs:o})=>{const[c,u]=x.useState([]);return x.useEffect(()=>{if(!e||!n){u(h=>h.length===0?h:[]);return}let l=0,a,r=C;const d=(h,m,f)=>{const{action:A,state:S}=I(r,h,m,o,t);r=S,A==="publish"?u(f):A==="clear"&&u(y=>y.length===0?y:[])},F=()=>{l=requestAnimationFrame(F),s==null||s();const h=performance.now(),m=n.getDetectionResults();if(!m){d(0,h,[]),a=m;return}if(m===a)return;a=m;const f=i(m);d(f.length,h,f)};return l=requestAnimationFrame(F),()=>cancelAnimationFrame(l)},[e,t,n,s,i,o]),c},R=.5,P=(e,t)=>{for(const n in t)delete t[n];if(e)for(const n of e)t[n.categoryName]=n.score;return t},X=(e,t)=>e.blendshapes[t]??0,T=(e,t,n=R)=>X(e,t)>=n,Y=e=>{const t=e[b.FACE_EYE_DISTANCE_LANDMARKS.left],n=e[b.FACE_EYE_DISTANCE_LANDMARKS.right];return!t||!n?0:Math.hypot(t.x-n.x,t.y-n.y)},D=()=>({index:0,landmarks:[],bounds:{minX:0,minY:0,maxX:0,maxY:0,width:0,height:0,centerX:0,centerY:0},pose:{position:{x:0,y:0,z:0},rotation:{x:0,y:0,z:0},scale:{x:0,y:0,z:0}},eyeDistance:0,blendshapes:{}}),p=(e,t)=>{t.x=e.x,t.y=e.y,t.z=e.z},N=(e,t,n=0,s)=>{var u,l,a;const i=(u=t.faceLandmarks)==null?void 0:u[n],o=e.getFace(n);if(!i||!o)return null;const c=s??D();return c.index=n,c.landmarks=i,E(i,c.bounds),p(o.transform.position,c.pose.position),p(o.transform.rotation,c.pose.rotation),p(o.transform.scale,c.pose.scale),c.eyeDistance=Y(i),P((a=(l=t.faceBlendshapes)==null?void 0:l[n])==null?void 0:a.categories,c.blendshapes),c},B=(e,t=0,n)=>{const s=e.getDetectionResults();return s?N(e,s,t,n):null};exports.DEFAULT_FACE_EXPRESSION_THRESHOLD=R;exports.computeLandmarkBounds=E;exports.createFaceInfoTarget=D;exports.getFaceBlendshape=X;exports.getFaceEyeDistance=Y;exports.getFaceInfo=B;exports.getFaceInfoFromResults=N;exports.hasFaceExpression=T;exports.prepareCalibrationFaceResults=_;exports.useFaceResultReader=L;
|
|
@@ -0,0 +1,118 @@
|
|
|
1
|
+
import { useState as X, useEffect as Y } from "react";
|
|
2
|
+
import { F as A } from "./index-BgQAX8rs.js";
|
|
3
|
+
const E = (e, t = {
|
|
4
|
+
minX: 0,
|
|
5
|
+
minY: 0,
|
|
6
|
+
maxX: 0,
|
|
7
|
+
maxY: 0,
|
|
8
|
+
width: 0,
|
|
9
|
+
height: 0,
|
|
10
|
+
centerX: 0,
|
|
11
|
+
centerY: 0
|
|
12
|
+
}) => {
|
|
13
|
+
if (e.length === 0)
|
|
14
|
+
return t.minX = 0, t.minY = 0, t.maxX = 0, t.maxY = 0, t.width = 0, t.height = 0, t.centerX = 0, t.centerY = 0, t;
|
|
15
|
+
let n = 1, s = 1, i = 0, o = 0;
|
|
16
|
+
for (let l = 0; l < e.length; l++) {
|
|
17
|
+
const { x: c, y: r } = e[l];
|
|
18
|
+
c < n && (n = c), r < s && (s = r), c > i && (i = c), r > o && (o = r);
|
|
19
|
+
}
|
|
20
|
+
const a = Math.max(0, i - n), u = Math.max(0, o - s);
|
|
21
|
+
return t.minX = n, t.minY = s, t.maxX = i, t.maxY = o, t.width = a, t.height = u, t.centerX = n + a * 0.5, t.centerY = s + u * 0.5, t;
|
|
22
|
+
}, L = (e, t) => e.map((n) => ({
|
|
23
|
+
landmarks: n,
|
|
24
|
+
bounds: E(n)
|
|
25
|
+
})), D = {
|
|
26
|
+
publishedCount: 0,
|
|
27
|
+
// -Infinity, not 0: the first non-empty frame must publish regardless of its
|
|
28
|
+
// timestamp (a frame at now=0 would otherwise be throttled against 0).
|
|
29
|
+
lastPublishAt: -1 / 0,
|
|
30
|
+
lastNonEmptyAt: -1
|
|
31
|
+
}, N = (e, t, n, s, i) => {
|
|
32
|
+
if (t > 0) {
|
|
33
|
+
const o = { ...e, lastNonEmptyAt: n };
|
|
34
|
+
return n - e.lastPublishAt >= s ? {
|
|
35
|
+
action: "publish",
|
|
36
|
+
state: { publishedCount: t, lastPublishAt: n, lastNonEmptyAt: n }
|
|
37
|
+
} : { action: "none", state: o };
|
|
38
|
+
}
|
|
39
|
+
return e.publishedCount === 0 ? { action: "none", state: e } : e.lastNonEmptyAt >= 0 && n - e.lastNonEmptyAt < i ? { action: "none", state: e } : {
|
|
40
|
+
action: "clear",
|
|
41
|
+
// Reset the throttle anchor so the next reacquired face publishes at once.
|
|
42
|
+
state: { publishedCount: 0, lastPublishAt: -1 / 0, lastNonEmptyAt: e.lastNonEmptyAt }
|
|
43
|
+
};
|
|
44
|
+
}, B = ({
|
|
45
|
+
enabled: e,
|
|
46
|
+
holdMs: t,
|
|
47
|
+
node: n,
|
|
48
|
+
onFrame: s,
|
|
49
|
+
prepare: i,
|
|
50
|
+
throttleMs: o
|
|
51
|
+
}) => {
|
|
52
|
+
const [a, u] = X([]);
|
|
53
|
+
return Y(() => {
|
|
54
|
+
if (!e || !n) {
|
|
55
|
+
u((h) => h.length === 0 ? h : []);
|
|
56
|
+
return;
|
|
57
|
+
}
|
|
58
|
+
let l = 0, c, r = D;
|
|
59
|
+
const d = (h, m, f) => {
|
|
60
|
+
const { action: x, state: F } = N(r, h, m, o, t);
|
|
61
|
+
r = F, x === "publish" ? u(f) : x === "clear" && u((b) => b.length === 0 ? b : []);
|
|
62
|
+
}, y = () => {
|
|
63
|
+
l = requestAnimationFrame(y), s == null || s();
|
|
64
|
+
const h = performance.now(), m = n.getDetectionResults();
|
|
65
|
+
if (!m) {
|
|
66
|
+
d(0, h, []), c = m;
|
|
67
|
+
return;
|
|
68
|
+
}
|
|
69
|
+
if (m === c) return;
|
|
70
|
+
c = m;
|
|
71
|
+
const f = i(m);
|
|
72
|
+
d(f.length, h, f);
|
|
73
|
+
};
|
|
74
|
+
return l = requestAnimationFrame(y), () => cancelAnimationFrame(l);
|
|
75
|
+
}, [e, t, n, s, i, o]), a;
|
|
76
|
+
}, R = 0.5, S = (e, t) => {
|
|
77
|
+
for (const n in t) delete t[n];
|
|
78
|
+
if (e)
|
|
79
|
+
for (const n of e) t[n.categoryName] = n.score;
|
|
80
|
+
return t;
|
|
81
|
+
}, C = (e, t) => e.blendshapes[t] ?? 0, T = (e, t, n = R) => C(e, t) >= n, P = (e) => {
|
|
82
|
+
const t = e[A.left], n = e[A.right];
|
|
83
|
+
return !t || !n ? 0 : Math.hypot(t.x - n.x, t.y - n.y);
|
|
84
|
+
}, _ = () => ({
|
|
85
|
+
index: 0,
|
|
86
|
+
landmarks: [],
|
|
87
|
+
bounds: { minX: 0, minY: 0, maxX: 0, maxY: 0, width: 0, height: 0, centerX: 0, centerY: 0 },
|
|
88
|
+
pose: {
|
|
89
|
+
position: { x: 0, y: 0, z: 0 },
|
|
90
|
+
rotation: { x: 0, y: 0, z: 0 },
|
|
91
|
+
scale: { x: 0, y: 0, z: 0 }
|
|
92
|
+
},
|
|
93
|
+
eyeDistance: 0,
|
|
94
|
+
blendshapes: {}
|
|
95
|
+
}), p = (e, t) => {
|
|
96
|
+
t.x = e.x, t.y = e.y, t.z = e.z;
|
|
97
|
+
}, w = (e, t, n = 0, s) => {
|
|
98
|
+
var u, l, c;
|
|
99
|
+
const i = (u = t.faceLandmarks) == null ? void 0 : u[n], o = e.getFace(n);
|
|
100
|
+
if (!i || !o) return null;
|
|
101
|
+
const a = s ?? _();
|
|
102
|
+
return a.index = n, a.landmarks = i, E(i, a.bounds), p(o.transform.position, a.pose.position), p(o.transform.rotation, a.pose.rotation), p(o.transform.scale, a.pose.scale), a.eyeDistance = P(i), S((c = (l = t.faceBlendshapes) == null ? void 0 : l[n]) == null ? void 0 : c.categories, a.blendshapes), a;
|
|
103
|
+
}, q = (e, t = 0, n) => {
|
|
104
|
+
const s = e.getDetectionResults();
|
|
105
|
+
return s ? w(e, s, t, n) : null;
|
|
106
|
+
};
|
|
107
|
+
export {
|
|
108
|
+
R as D,
|
|
109
|
+
C as a,
|
|
110
|
+
P as b,
|
|
111
|
+
E as c,
|
|
112
|
+
_ as d,
|
|
113
|
+
q as e,
|
|
114
|
+
w as g,
|
|
115
|
+
T as h,
|
|
116
|
+
L as p,
|
|
117
|
+
B as u
|
|
118
|
+
};
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
import { XRModelNodeHandTracking } from '../types/nodes';
|
|
2
|
+
export type HandJoints2DSettings = {
|
|
3
|
+
enabled: boolean;
|
|
4
|
+
bothHands: boolean;
|
|
5
|
+
countEnabled: boolean;
|
|
6
|
+
minCountConfidence: number;
|
|
7
|
+
showBones: boolean;
|
|
8
|
+
showJoints: boolean;
|
|
9
|
+
showBoundingBox: boolean;
|
|
10
|
+
showLabels: boolean;
|
|
11
|
+
visualScale: number;
|
|
12
|
+
opacity: number;
|
|
13
|
+
jointRadius: number;
|
|
14
|
+
lineWidth: number;
|
|
15
|
+
labelScale: number;
|
|
16
|
+
smoothing: number;
|
|
17
|
+
};
|
|
18
|
+
export declare const DEFAULT_HAND_JOINTS_2D_SETTINGS: HandJoints2DSettings;
|
|
19
|
+
export type HandJoints2DHandedness = "left" | "right";
|
|
20
|
+
export type HandJoints2DPoint = {
|
|
21
|
+
x: number;
|
|
22
|
+
y: number;
|
|
23
|
+
};
|
|
24
|
+
export type HandJoints2DHandFrame = {
|
|
25
|
+
handedness?: HandJoints2DHandedness;
|
|
26
|
+
coordinates?: HandJoints2DPoint[];
|
|
27
|
+
};
|
|
28
|
+
export type HandJoints2DBounds = {
|
|
29
|
+
center: HandJoints2DPoint;
|
|
30
|
+
size: HandJoints2DPoint;
|
|
31
|
+
};
|
|
32
|
+
export type HandJoints2DFingerName = "thumb" | "index" | "middle" | "ring" | "pinky";
|
|
33
|
+
export type HandJoints2DCountResult = {
|
|
34
|
+
fingerCount: 0 | 1 | 2 | 3 | 4 | 5;
|
|
35
|
+
confidence: number;
|
|
36
|
+
extendedFingers: HandJoints2DFingerName[];
|
|
37
|
+
handedness?: HandJoints2DHandedness;
|
|
38
|
+
};
|
|
39
|
+
export declare const HAND_JOINTS_2D_BONES: Array<[number, number]>;
|
|
40
|
+
export declare const HAND_JOINTS_2D_LABELS: readonly ["wrist", "thumb_cmc", "thumb_mcp", "thumb_ip", "thumb_tip", "index_mcp", "index_pip", "index_dip", "index_tip", "middle_mcp", "middle_pip", "middle_dip", "middle_tip", "ring_mcp", "ring_pip", "ring_dip", "ring_tip", "pinky_mcp", "pinky_pip", "pinky_dip", "pinky_tip", "palm_center", "thumb_base", "index_base", "pinky_base"];
|
|
41
|
+
export declare function getHandJoints2DHands(node?: XRModelNodeHandTracking | null): HandJoints2DHandFrame[];
|
|
42
|
+
export declare function handJointCoordinateToScreenPoint(point: {
|
|
43
|
+
x: number;
|
|
44
|
+
y: number;
|
|
45
|
+
}): HandJoints2DPoint;
|
|
46
|
+
export declare function smoothHandJoints2DPoints(previous: HandJoints2DPoint[] | null, next: HandJoints2DPoint[], smoothing: number): HandJoints2DPoint[];
|
|
47
|
+
export declare function scaleHandJoints2DPoints(points: HandJoints2DPoint[], scale: number, anchorIndex?: number): HandJoints2DPoint[];
|
|
48
|
+
export declare function getHandJoints2DBounds(points: HandJoints2DPoint[]): HandJoints2DBounds | null;
|
|
49
|
+
export declare function classifyHandJoints2DCount(points: HandJoints2DPoint[], handedness?: HandJoints2DHandedness): HandJoints2DCountResult | null;
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import { XRModelNodeHandTracking } from '../types/nodes';
|
|
2
|
+
export type HandTracking2DSettings = {
|
|
3
|
+
enabled: boolean;
|
|
4
|
+
bothHands: boolean;
|
|
5
|
+
visualScale: number;
|
|
6
|
+
opacity: number;
|
|
7
|
+
pointRadius: number;
|
|
8
|
+
lineWidth: number;
|
|
9
|
+
labelScale: number;
|
|
10
|
+
smoothing: number;
|
|
11
|
+
color: string;
|
|
12
|
+
showBoundingBox: boolean;
|
|
13
|
+
showLabels: boolean;
|
|
14
|
+
logToConsole: boolean;
|
|
15
|
+
};
|
|
16
|
+
export declare const DEFAULT_HAND_TRACKING_2D_SETTINGS: HandTracking2DSettings;
|
|
17
|
+
export type HandTracking2DHandedness = "left" | "right";
|
|
18
|
+
export type HandTracking2DHandFrame = {
|
|
19
|
+
handedness?: HandTracking2DHandedness;
|
|
20
|
+
coordinates?: HandTracking2DPoint[];
|
|
21
|
+
gesture?: "closed_fist" | "open_palm";
|
|
22
|
+
};
|
|
23
|
+
export declare const HAND_TRACKING_2D_BONES: Array<[number, number]>;
|
|
24
|
+
export type HandTracking2DPoint = {
|
|
25
|
+
x: number;
|
|
26
|
+
y: number;
|
|
27
|
+
};
|
|
28
|
+
export declare function getHandTracking2DHands(node?: XRModelNodeHandTracking | null): HandTracking2DHandFrame[];
|
|
29
|
+
export declare function handTrackingCoordinateToScreenPoint(point: {
|
|
30
|
+
x: number;
|
|
31
|
+
y: number;
|
|
32
|
+
}, width: number, height: number): HandTracking2DPoint;
|
|
33
|
+
export declare function smoothHandTrackingPoints(previous: HandTracking2DPoint[] | null, next: HandTracking2DPoint[], smoothing: number): HandTracking2DPoint[];
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
import { XRModelNodeHandTracking } from '../types/nodes';
|
|
2
|
+
export type HandTracking2DControllerSettings = {
|
|
3
|
+
enabled: boolean;
|
|
4
|
+
attachImageEnabled: boolean;
|
|
5
|
+
showBoundingBox: boolean;
|
|
6
|
+
verticalAlign: HandTracking2DControllerVerticalAlign;
|
|
7
|
+
horizontalAlign: HandTracking2DControllerHorizontalAlign;
|
|
8
|
+
sizeResponsiveToHandBoundingBox: boolean;
|
|
9
|
+
size: number;
|
|
10
|
+
offsetX: number;
|
|
11
|
+
offsetY: number;
|
|
12
|
+
rotation: number;
|
|
13
|
+
alpha: number;
|
|
14
|
+
smoothFollowing: boolean;
|
|
15
|
+
smoothing: number;
|
|
16
|
+
};
|
|
17
|
+
export declare const DEFAULT_HAND_TRACKING_2D_CONTROLLER_SETTINGS: HandTracking2DControllerSettings;
|
|
18
|
+
export type HandTracking2DControllerVerticalAlign = "top" | "middle" | "bottom";
|
|
19
|
+
export type HandTracking2DControllerHorizontalAlign = "left" | "center" | "right";
|
|
20
|
+
export declare const HAND_TRACKING_2D_CONTROLLER_VERTICAL_ALIGN_OPTIONS: Array<{
|
|
21
|
+
label: string;
|
|
22
|
+
value: HandTracking2DControllerVerticalAlign;
|
|
23
|
+
}>;
|
|
24
|
+
export declare const HAND_TRACKING_2D_CONTROLLER_HORIZONTAL_ALIGN_OPTIONS: Array<{
|
|
25
|
+
label: string;
|
|
26
|
+
value: HandTracking2DControllerHorizontalAlign;
|
|
27
|
+
}>;
|
|
28
|
+
export type HandTracking2DControllerHandedness = "left" | "right";
|
|
29
|
+
export type HandTracking2DControllerHandFrame = {
|
|
30
|
+
handedness?: HandTracking2DControllerHandedness;
|
|
31
|
+
coordinates?: Array<{
|
|
32
|
+
x: number;
|
|
33
|
+
y: number;
|
|
34
|
+
z: number;
|
|
35
|
+
}>;
|
|
36
|
+
};
|
|
37
|
+
export type HandTracking2DControllerRenderFrame = {
|
|
38
|
+
key: string;
|
|
39
|
+
handedness?: HandTracking2DControllerHandedness;
|
|
40
|
+
position: [number, number];
|
|
41
|
+
size: [number, number];
|
|
42
|
+
boundingBox: {
|
|
43
|
+
position: [number, number];
|
|
44
|
+
size: [number, number];
|
|
45
|
+
};
|
|
46
|
+
rotation: number;
|
|
47
|
+
};
|
|
48
|
+
export declare const handTracking2DControllerToScreenPoint: (point: {
|
|
49
|
+
x: number;
|
|
50
|
+
y: number;
|
|
51
|
+
}) => {
|
|
52
|
+
x: number;
|
|
53
|
+
y: number;
|
|
54
|
+
};
|
|
55
|
+
export declare function getHandTracking2DControllerHands(node?: XRModelNodeHandTracking | null): HandTracking2DControllerHandFrame[];
|
|
56
|
+
export declare function smoothHandTracking2DControllerValue(previous: number | null, next: number, smoothing: number): number;
|
|
57
|
+
export declare function getHandTracking2DControllerAttachOffset(verticalAlign: HandTracking2DControllerVerticalAlign, horizontalAlign: HandTracking2DControllerHorizontalAlign, width: number, height: number): [number, number];
|
|
58
|
+
export declare function getHandTracking2DControllerBoundingBoxSize(points: Array<{
|
|
59
|
+
x: number;
|
|
60
|
+
y: number;
|
|
61
|
+
}>): {
|
|
62
|
+
width: number;
|
|
63
|
+
height: number;
|
|
64
|
+
};
|
|
65
|
+
export declare function computeHandTracking2DControllerFrame(hand: HandTracking2DControllerHandFrame, settings: HandTracking2DControllerSettings, key: string): HandTracking2DControllerRenderFrame | null;
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
import { XRModelNodeHandTracking } from '../types/nodes';
|
|
2
|
+
export type HandTracking3DSettings = {
|
|
3
|
+
enabled: boolean;
|
|
4
|
+
bothHands: boolean;
|
|
5
|
+
space: HandTracking3DSpace;
|
|
6
|
+
showJoints: boolean;
|
|
7
|
+
showBones: boolean;
|
|
8
|
+
showLabels: boolean;
|
|
9
|
+
handScale: number;
|
|
10
|
+
depthScale: number;
|
|
11
|
+
trackingDistanceM: number;
|
|
12
|
+
projectionDistanceM: number;
|
|
13
|
+
fitX: number;
|
|
14
|
+
fitY: number;
|
|
15
|
+
offsetX: number;
|
|
16
|
+
offsetY: number;
|
|
17
|
+
offsetZ: number;
|
|
18
|
+
jointRadius: number;
|
|
19
|
+
boneRadius: number;
|
|
20
|
+
opacity: number;
|
|
21
|
+
smoothing: number;
|
|
22
|
+
};
|
|
23
|
+
export type HandTracking3DSpace = "scene" | "screen";
|
|
24
|
+
export declare const DEFAULT_HAND_TRACKING_3D_SETTINGS: HandTracking3DSettings;
|
|
25
|
+
export type HandTracking3DHandedness = "left" | "right";
|
|
26
|
+
export type HandTracking3DPoint = {
|
|
27
|
+
x: number;
|
|
28
|
+
y: number;
|
|
29
|
+
z: number;
|
|
30
|
+
};
|
|
31
|
+
export type HandTracking3DProjection = {
|
|
32
|
+
width: number;
|
|
33
|
+
height: number;
|
|
34
|
+
planeZ: number;
|
|
35
|
+
};
|
|
36
|
+
export type HandTracking3DHandFrame = {
|
|
37
|
+
handedness?: HandTracking3DHandedness;
|
|
38
|
+
coordinates?: HandTracking3DPoint[];
|
|
39
|
+
};
|
|
40
|
+
export type HandTracking3DRenderedHandFrame = HandTracking3DHandFrame & {
|
|
41
|
+
key: string;
|
|
42
|
+
points: HandTracking3DPoint[];
|
|
43
|
+
};
|
|
44
|
+
export declare const HAND_TRACKING_3D_BONES: Array<[number, number]>;
|
|
45
|
+
export declare const HAND_TRACKING_3D_LABELS: readonly ["wrist", "thumb_cmc", "thumb_mcp", "thumb_ip", "thumb_tip", "index_mcp", "index_pip", "index_dip", "index_tip", "middle_mcp", "middle_pip", "middle_dip", "middle_tip", "ring_mcp", "ring_pip", "ring_dip", "ring_tip", "pinky_mcp", "pinky_pip", "pinky_dip", "pinky_tip"];
|
|
46
|
+
export declare function getHandTracking3DHands(node?: XRModelNodeHandTracking | null): HandTracking3DHandFrame[];
|
|
47
|
+
export declare function handTrackingCoordinateToScenePoint(point: {
|
|
48
|
+
x: number;
|
|
49
|
+
y: number;
|
|
50
|
+
z?: number;
|
|
51
|
+
}, settings: Pick<HandTracking3DSettings, "handScale" | "depthScale" | "space" | "fitX" | "fitY" | "offsetX" | "offsetY" | "offsetZ">, projection?: HandTracking3DProjection): HandTracking3DPoint;
|
|
52
|
+
export declare function smoothHandTracking3DPoints(previous: HandTracking3DPoint[] | null, next: HandTracking3DPoint[], smoothing: number): HandTracking3DPoint[];
|
|
@@ -7,7 +7,7 @@ export type CalibrationMediaSourceKind = "webcam" | XRMediaSourceKind;
|
|
|
7
7
|
* `FaceTrackingResult`s (landmarks + axis-aligned bounds). Source-kind is
|
|
8
8
|
* accepted for future per-source handling; results stay in display space.
|
|
9
9
|
*/
|
|
10
|
-
export declare const prepareCalibrationFaceResults: (faceLandmarks: NormalizedLandmark[][],
|
|
10
|
+
export declare const prepareCalibrationFaceResults: (faceLandmarks: NormalizedLandmark[][], selectedSource: CalibrationMediaSourceKind) => FaceTrackingResult[];
|
|
11
11
|
/**
|
|
12
12
|
* Per-frame publish state for the face-results reader. Pure so the hold +
|
|
13
13
|
* throttle timing can be unit-tested without a RAF/React harness.
|
|
@@ -18,6 +18,6 @@ export declare const useCalibrationFaceTracker: ({ enabled, displayMirrored, ima
|
|
|
18
18
|
}) => {
|
|
19
19
|
activeDelegate: "GPU";
|
|
20
20
|
faces: import('../types').FaceTrackingResult[];
|
|
21
|
-
status: "
|
|
21
|
+
status: "idle" | "ready" | "error" | "initializing";
|
|
22
22
|
error: string | null;
|
|
23
23
|
};
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { FaceAttributeExpressionResult } from '../face-attribute-expression';
|
|
2
|
+
import { FaceInfo } from '../face-info';
|
|
3
|
+
export declare const DEFAULT_FACE_ATTRIBUTE_EXPRESSION_MODEL_URL = "https://huggingface.co/opencv/facial_expression_recognition/resolve/main/facial_expression_recognition_mobilefacenet_2022july_int8.onnx";
|
|
4
|
+
export type FaceAttributeExpressionStatus = "idle" | "loading" | "ready" | "error";
|
|
5
|
+
export type UseFaceAttributeExpressionOptions = {
|
|
6
|
+
active?: boolean;
|
|
7
|
+
targetFps?: number;
|
|
8
|
+
minConfidence?: number;
|
|
9
|
+
modelUrl?: string;
|
|
10
|
+
};
|
|
11
|
+
export type UseFaceAttributeExpressionResult = {
|
|
12
|
+
status: FaceAttributeExpressionStatus;
|
|
13
|
+
result: FaceAttributeExpressionResult | null;
|
|
14
|
+
error: Error | null;
|
|
15
|
+
};
|
|
16
|
+
export declare const useFaceAttributeExpression: (face: FaceInfo | null, { active, targetFps, minConfidence, modelUrl, }?: UseFaceAttributeExpressionOptions) => UseFaceAttributeExpressionResult;
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { FaceInfo } from '../face-info';
|
|
2
|
+
import { UseFaceInfosOptions } from './useFaceInfos';
|
|
3
|
+
export type FaceDetectionPhase = "begin" | "stay" | "end" | "none";
|
|
4
|
+
export type UseFaceDetectionOptions = UseFaceInfosOptions & {
|
|
5
|
+
faceIndex?: number;
|
|
6
|
+
};
|
|
7
|
+
export type FaceDetectionState = {
|
|
8
|
+
face: FaceInfo | null;
|
|
9
|
+
faces: FaceInfo[];
|
|
10
|
+
faceCount: number;
|
|
11
|
+
detected: boolean;
|
|
12
|
+
justDetected: boolean;
|
|
13
|
+
justLost: boolean;
|
|
14
|
+
phase: FaceDetectionPhase;
|
|
15
|
+
};
|
|
16
|
+
export declare const getFaceDetectionPhase: (wasDetected: boolean, detected: boolean) => FaceDetectionPhase;
|
|
17
|
+
/** Face presence/count lifecycle over the shared FaceInfo reader. */
|
|
18
|
+
export declare const useFaceDetection: ({ faceIndex, numFaces, ...options }?: UseFaceDetectionOptions) => FaceDetectionState;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { FaceInfo } from '../face-info';
|
|
2
|
+
import { UseFaceInfosOptions } from './useFaceInfos';
|
|
3
|
+
export type UseFaceInfoOptions = UseFaceInfosOptions & {
|
|
4
|
+
faceIndex?: number;
|
|
5
|
+
};
|
|
6
|
+
/** Single-face selector over `useFaceInfos`; it does not create another reader loop. */
|
|
7
|
+
export declare const useFaceInfo: ({ faceIndex, numFaces, ...options }?: UseFaceInfoOptions) => FaceInfo | null;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { FaceInfo } from '../face-info';
|
|
2
|
+
export type UseFaceInfosOptions = {
|
|
3
|
+
/** Pauses this consumer's model interest when false. Default true. */
|
|
4
|
+
active?: boolean;
|
|
5
|
+
/** Maximum faces requested from the shared model. Default 1. */
|
|
6
|
+
numFaces?: number;
|
|
7
|
+
/** Optional inference-rate cap. */
|
|
8
|
+
targetFps?: number;
|
|
9
|
+
/** Minimum milliseconds between React result publications. Default 16. */
|
|
10
|
+
throttleMs?: number;
|
|
11
|
+
/** Keep the last result through brief missed detections. Default 250. */
|
|
12
|
+
holdMs?: number;
|
|
13
|
+
};
|
|
14
|
+
/** React reader for all current faces. Must run inside XRProvider and the R3F Canvas. */
|
|
15
|
+
export declare const useFaceInfos: ({ active, holdMs, numFaces, targetFps, throttleMs, }?: UseFaceInfosOptions) => FaceInfo[];
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { FaceLandmarkerResult } from '@mediapipe/tasks-vision';
|
|
2
|
+
import { XRModelNodeFaceTracking } from '../types/nodes';
|
|
3
|
+
export declare const useFaceResultReader: <T>({ enabled, holdMs, node, onFrame, prepare, throttleMs, }: {
|
|
4
|
+
node: XRModelNodeFaceTracking | null;
|
|
5
|
+
enabled: boolean;
|
|
6
|
+
throttleMs: number;
|
|
7
|
+
holdMs: number;
|
|
8
|
+
onFrame?: () => void;
|
|
9
|
+
prepare: (results: FaceLandmarkerResult) => T[];
|
|
10
|
+
}) => T[];
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
export type CaptureStatus = "idle" | "capturing" | "completed" | "error";
|
|
2
|
+
export type FrameCaptureEvents = {
|
|
3
|
+
onCaptureStart?: () => void;
|
|
4
|
+
onCaptureComplete?: (dataUrl: string) => void;
|
|
5
|
+
onError?: (error: Error) => void;
|
|
6
|
+
};
|
|
7
|
+
export type UseFrameCaptureOptions = FrameCaptureEvents & {
|
|
8
|
+
/** Override the XR session capture function for custom renderers or tests. */
|
|
9
|
+
captureFrame?: () => string;
|
|
10
|
+
};
|
|
11
|
+
export declare const runFrameCapture: (captureFrame: () => string, events?: FrameCaptureEvents) => Promise<string>;
|
|
12
|
+
export declare const useFrameCapture: (options?: UseFrameCaptureOptions) => {
|
|
13
|
+
status: CaptureStatus;
|
|
14
|
+
capturePhoto: () => Promise<string | null>;
|
|
15
|
+
clear: () => void;
|
|
16
|
+
dataUrl: string | null;
|
|
17
|
+
error: Error | null;
|
|
18
|
+
};
|
|
@@ -1,3 +1,7 @@
|
|
|
1
|
+
export type RecordingStatus = "idle" | "starting" | "recording" | "paused" | "stopping" | "completed" | "error";
|
|
2
|
+
export type RecordingEvent = "start" | "started" | "pause" | "resume" | "stop" | "complete" | "fail" | "clear";
|
|
3
|
+
/** Pure lifecycle mapping, exported so apps and tests can share the SDK convention. */
|
|
4
|
+
export declare const recordingStatusForEvent: (event: RecordingEvent) => RecordingStatus;
|
|
1
5
|
export interface UseMediaRecorderOptions {
|
|
2
6
|
/**
|
|
3
7
|
* Add an audio track to the recording. `true` opens the default microphone;
|
|
@@ -10,7 +14,14 @@ export interface UseMediaRecorderOptions {
|
|
|
10
14
|
mimeType?: string;
|
|
11
15
|
bitsPerSecond?: number;
|
|
12
16
|
onData?: (chunk: Blob) => void;
|
|
17
|
+
/** @deprecated Use `onRecordingComplete`. */
|
|
13
18
|
onStop?: (blob: Blob) => void;
|
|
19
|
+
onRecordingStart?: () => void;
|
|
20
|
+
onRecordingPause?: () => void;
|
|
21
|
+
onRecordingResume?: () => void;
|
|
22
|
+
onRecordingStop?: () => void;
|
|
23
|
+
onRecordingComplete?: (blob: Blob) => void;
|
|
24
|
+
onError?: (error: Error) => void;
|
|
14
25
|
/**
|
|
15
26
|
* Record this exact stream as-is (no track assembly, no getUserMedia). Use
|
|
16
27
|
* when you've already composed the stream you want (e.g. canvas + music).
|
|
@@ -24,10 +35,11 @@ export interface UseMediaRecorderOptions {
|
|
|
24
35
|
* input, plus an optional audio track per `audio` — picks the first supported
|
|
25
36
|
* codec, and begins recording. `stop()` finalizes; the `Blob` lands on
|
|
26
37
|
* `recordedBlob` (and `onStop`). Pass `passThroughStream` to record a
|
|
27
|
-
* pre-composed stream verbatim.
|
|
38
|
+
* pre-composed stream verbatim, then call `start()` without an argument.
|
|
28
39
|
*/
|
|
29
40
|
export declare function useMediaRecorder(opts?: UseMediaRecorderOptions): {
|
|
30
|
-
|
|
41
|
+
status: RecordingStatus;
|
|
42
|
+
start: (inputStream?: MediaStream, timeslice?: number) => Promise<void>;
|
|
31
43
|
stop: () => void;
|
|
32
44
|
pause: () => void;
|
|
33
45
|
resume: () => void;
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { Texture } from 'three';
|
|
2
|
+
/**
|
|
3
|
+
* Own a texture for exactly as long as the current React binding uses it.
|
|
4
|
+
* Replacement disposes the previous texture; unmount disposes the final one.
|
|
5
|
+
*/
|
|
6
|
+
export declare const useOwnedTexture: (texture: Texture | null | undefined) => void;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { TrackerType, TrackingTarget } from '../types/tracking';
|
|
1
|
+
import { FaceCustomAnchorPoint, TrackerType, TrackingTarget } from '../types/tracking';
|
|
2
2
|
import * as THREE from "three";
|
|
3
3
|
/**
|
|
4
4
|
* Per-frame resolver for a tracker's landmarks/joints.
|
|
@@ -12,7 +12,7 @@ import * as THREE from "three";
|
|
|
12
12
|
* Returning `null` means "this landmark is not currently detected" —
|
|
13
13
|
* the anchor should hide its children for that frame.
|
|
14
14
|
*/
|
|
15
|
-
export type TrackerLandmarkResolver = (target: TrackingTarget) => {
|
|
15
|
+
export type TrackerLandmarkResolver = (target: TrackingTarget, customAnchorPoint?: FaceCustomAnchorPoint) => {
|
|
16
16
|
position: THREE.Vector3;
|
|
17
17
|
quaternion?: THREE.Quaternion;
|
|
18
18
|
} | null;
|
|
@@ -15,13 +15,16 @@ export type SessionFacade = {
|
|
|
15
15
|
registerXRPipeline: (params: RegisterXRPipelineParams) => Promise<void>;
|
|
16
16
|
getModelNode: <T extends Record<string, unknown>>(modelCode: XRModel) => T;
|
|
17
17
|
captureFrame: () => string;
|
|
18
|
+
getInputFrame: () => OffscreenCanvas | HTMLCanvasElement | null;
|
|
18
19
|
_setRenderTarget: (canvas: HTMLCanvasElement) => Promise<void>;
|
|
19
20
|
_setRenderSize: (width: number, height: number) => Promise<void>;
|
|
20
21
|
_setR3FState: (state: {
|
|
21
22
|
renderer: WebGLRenderer;
|
|
22
23
|
scene: Scene;
|
|
23
24
|
camera: Camera;
|
|
25
|
+
renderFrame?: () => void;
|
|
24
26
|
}) => void;
|
|
27
|
+
_renderFrame: () => void;
|
|
25
28
|
_getVideoElement: () => HTMLVideoElement | undefined;
|
|
26
29
|
/** Update the session perf config (targetFps / camRes). Applied to models on
|
|
27
30
|
* their next run; camRes takes effect on the next media (re)bind. */
|