Skip to main content

Media sources

PoseTracker accepts three input modes on all four npm packages (v0.2.0). Default is live camera so quickstarts stay unchanged.
React Native: the host app must pick the file (expo-image-picker, document picker, …). The SDK does not ship a picker.

React Native

Works the same on offline and light:

Props

Prop updates inject window.__PT_SET_SOURCE into the WebView. Still-image re-run uses page runtime __PT_ANALYZE (no typed RN analyze() yet).

Host checklist

  1. For camera: declare + request permission (Permissions).
  2. For video / image: pick a file in the host app, then pass sourceUri or sourceBase64.
  3. Prefer a cache file:// over Android content:// when the WebView cannot read the URI.
  4. Remote https media follows WebView / CORS rules.
Full prop table: WebViewPoseView.

Web (vanilla)

Script tag

PoseSource

Also: createPoseTracker({ source: 'video', sourceFile }) / sourceUrl via normalizePoseSource. Prefer local File / Blob over remote URLs (CORS). See Web SDKs.

Web (React)

PoseCamera props: source, sourceUrl, sourceFile (plus the usual skeleton / watermark / coldStart props).

Events by mode

Packages (npm 0.2.0)

Next