KinesteX

Camera & Pose Detection

Fine-tune the camera and pose detection system. These parameters affect any view that runs the pose-tracking pipeline (Workout player, Camera component, Assessments, Games) unless a narrower scope is listed.


ParameterTypeDefaultApplies toWhat it does internally
shouldAskCamerabooleantrueWorkout player, Challenge, AssessmentsWhen false, the pre-workout camera-permission gate is skipped and navigation proceeds directly (the browser will still ask on first actual camera use). Use when your host app already manages the camera permission
shouldShowCameraSelectorbooleanfalseWorkout player, Camera, AssessmentsShows a camera-switch button on the camera-positioning (check-frame) screens so the user can pick between available camera devices
shouldShowOpenCameraSettingsbooleanfalseAll (camera-help modal)Switches the camera-permission help modal to a step set that guides the user to their device camera settings (for hosts that can deep-link there)
cameraLabelstringAll pose-tracking viewsSelects the camera device whose label contains this substring (e.g. "back", "wide"). If no device matches, falls back to the default front camera. Ignored when videoURL is set
minPoseDetectionConfidencenumber0.75All pose-tracking viewsMediaPipe minimum detection confidence (0–1). Lower = detects poses more easily but with more false positives
minTrackingConfidencenumber0.75All pose-tracking viewsMediaPipe minimum tracking confidence (0–1). Affects how persistently a pose is tracked between frames
minPosePresenceConfidencenumber0.75All pose-tracking viewsMediaPipe minimum presence confidence (0–1). Threshold for deciding a person is in frame
mediapipeModel"full", "heavy", or "light"autoAll pose-tracking viewsExplicitly pins the MediaPipe pose model. When omitted, the SDK auto-selects light or full based on device speed — heavy is never auto-selected and is only used when you pass it explicitly here
defaultDelegate"GPU" or "CPU""GPU"All pose-tracking viewsProcessing backend for pose detection. The URL parameter ?delegate= overrides the postMessage value
landmarkColorstring"#14FF00"All pose-tracking viewsColor of the skeleton overlay when the user's form is correct (# optional — it is added automatically). Mistake highlighting always uses red/orange on top of this
isDrawingPosebooleantrueAll pose-tracking viewsWhen false, hides the skeleton overlay entirely. Pose recognition, rep counting, and mistake detection still run — only the drawing is disabled
showSilhouettebooleantrueWorkout player, CameraWhen false, the camera-positioning (silhouette/check-frame) step is skipped entirely and the session starts straight on the exercise screen
includePoseDatastring[]Camera onlyWhich raw pose streams to emit as postMessage events, e.g. ["angles", "poseLandmarks", "worldLandmarks"]. "poseLandmarks" emits per-frame pose_landmarks messages, "worldLandmarks" emits world_landmarks, "angles" enables joint-angle computation. Ignored by every other integration option
includePoseBordersbooleantrueAll pose-tracking viewsEnables the out-of-frame guard: when body parts leave the frame, the skeleton turns red, a "step back" cue plays, and rep counting pauses until the user is fully visible. false disables that guard
includeRealtimeAccuracybooleantrueWorkout player, CameraTracks per-rep form accuracy and, when explicitly passed as true, additionally streams per-frame correct_position_accuracy postMessage events to the host. Note: passing false does not disable accuracy tracking (the flag is only applied when truthy)
videoFit"cover" or "contain""cover"All pose-tracking views"contain" shows the full camera frame (letterboxed) instead of zooming to fill the view — useful when the full body must stay visible in tight layouts. Assessments force contain in landscape regardless of this value

Notes:

  • videoURL (feed a video file instead of the live camera) is documented in Testing & Simulation.
  • Changing confidence values, mediapipeModel, or defaultDelegate triggers a pose-model rebuild — set them at launch, not mid-session.
  • There is no automatic "heavy" model for balance assessments; if an assessment needs maximum accuracy, pass mediapipeModel: "heavy" explicitly.
Camera & Pose Detection Settings
Swift example:
1// Via customParams
2kinestex.createCameraView(
3    exercises: exerciseList,
4    currentExercise: $currentExercise,
5    customParams: [
6        "landmarkColor": "#FF5500",
7        "showSilhouette": true,
8        "mediapipeModel": "heavy",
9        "defaultDelegate": "GPU",
10        "includePoseData": ["angles", "poseLandmarks"], // Camera component only
11        "includeRealtimeAccuracy": true,
12        "shouldShowCameraSelector": true,
13        "videoFit": "contain" // show full camera frame
14    ]
15)