Spaces:
Running on Zero
Running on Zero
| title: GameMaster Mocap | |
| emoji: πΊ | |
| colorFrom: blue | |
| colorTo: purple | |
| sdk: gradio | |
| sdk_version: 5.31.0 | |
| app_file: app.py | |
| python_version: "3.12" | |
| # π MotionBERT MoCap Studio | |
| Convert any single-person video into a full-body **motion capture animation** exported as: | |
| | File | Use | | |
| |------|-----| | |
| | `motion_capture.glb` | Blender armature import / three.js / Godot import | | |
| | `animation.tres` | Godot 4 AnimationLibrary β text resource | | |
| | `animation.res` | Godot 4 AnimationLibrary β binary resource | | |
| > β± **CPU space**: processing takes ~3-8 minutes per video depending on length. | |
| > Upload a short clip (5-15 seconds) for the fastest results. | |
| --- | |
| ## Pipeline | |
| | Step | Component | | |
| |------|-----------| | |
| | 1 | Frame extraction β up to 243 frames at uniform stride | | |
| | 2 | Person detection β DETR (`facebook/detr-resnet-50`) every 15 frames | | |
| | 3 | 2-D pose β ViTPose (`usyd-community/vitpose-base-simple-coco`) | | |
| | 4 | 3-D lift β MotionBERT DSTformer (`walterzhu/MotionBERT`) | | |
| | 5 | Export β GLB skeleton + Godot 4 `.tres` / `.res` | | |
| --- | |
| ## Bone Hierarchy (17 bones) | |
| ``` | |
| Hips β root | |
| βββ Spine | |
| β βββ Chest | |
| β βββ Neck β Head | |
| β βββ LeftUpperArm β LeftLowerArm β LeftHand | |
| β βββ RightUpperArm β RightLowerArm β RightHand | |
| βββ LeftUpperLeg β LeftLowerLeg β LeftFoot | |
| βββ RightUpperLeg β RightLowerLeg β RightFoot | |
| ``` | |
| --- | |
| ## Using in Godot 4 | |
| ```gdscript | |
| var lib := load("res://animation.tres") as AnimationLibrary | |
| $AnimationPlayer.add_animation_library("mocap", lib) | |
| $AnimationPlayer.play("mocap/mocap") | |
| ``` | |
| ## Using in Blender | |
| File β Import β glTF 2.0 β select `motion_capture.glb` | |