fix(avlivebody): track hand face depth to pelvis
CI build oscope-of / build-check (push) Has been cancelled

Drive HandFaceSkeleton.setDepth() from the body pelvis z each frame
(negated ARKit→RealityKit) so hand/face markers follow body depth
instead of rendering at the fixed default plane depth 0.
This commit is contained in:
L'électron rare
2026-06-26 14:23:15 +02:00
parent f9d5614d4d
commit b1e53da2bb
2 changed files with 6 additions and 2 deletions
@@ -105,7 +105,9 @@ struct ContentView: View {
hands: consumer.hands,
face: consumer.face,
prevPelvis: &prevPelvis)
controller.updateHandFace(hands: consumer.hands, face: consumer.face)
controller.updateHandFace(hands: consumer.hands,
face: consumer.face,
depth: Float(-(prevPelvis?.z ?? 0)))
}
private func wire() {
@@ -95,7 +95,9 @@ final class SceneController {
mesh?.update(persons)
}
func updateHandFace(hands: HandsPayload?, face: FacePayload?) {
func updateHandFace(hands: HandsPayload?, face: FacePayload?,
depth: Float) {
handFace?.setDepth(depth)
handFace?.update(hands: hands, face: face)
}