feat(编辑器): 支持导入 GLB/GLTF 模型并驱动角色动画
- 新增 GLB/GLTF 模型加载与渲染,支持内嵌动画播放 - 通过 IndexedDB 持久化大体积模型二进制,规避 localStorage 限制 - 新增动作片段序列,时间轴可添加、编辑与编排多段动作 - 优化机位视角相机同步,修复角度修改不生效问题 - 扩展骨骼识别,兼容 Mixamo 前缀及 UE4 骨架
This commit is contained in:
1 parent
9d3a5b9bea
commit
38dc27501a
36 files changed
+1899
-427
No files matched your search
@@ -15,12 +15,18 @@ function isEditableShortcutTarget(target: EventTarget | null) {
|
||||
export default function App() {
|
||||
const viewMode = useDirectorStore((state) => state.viewMode);
|
||||
const setViewMode = useDirectorStore((state) => state.setViewMode);
|
||||
const hydratePersistedModelBinaries = useDirectorStore((state) => state.hydratePersistedModelBinaries);
|
||||
|
||||
useEffect(() => {
|
||||
initDirectorDeskHostBridge();
|
||||
window.parent?.postMessage({ type: "storyai:director-desk-ready" }, window.location.origin);
|
||||
}, []);
|
||||
|
||||
useEffect(() => {
|
||||
// 启动后把持久化的 GLB/GLTF 二进制从 IndexedDB 还原成 objectURL(localStorage 不存大文件)。
|
||||
void hydratePersistedModelBinaries();
|
||||
}, [hydratePersistedModelBinaries]);
|
||||
|
||||
useEffect(() => {
|
||||
function handleKeyDown(event: KeyboardEvent) {
|
||||
if (event.defaultPrevented || isEditableShortcutTarget(event.target)) return;
|
||||
|
||||
Reference in new issue
Block a user