Skip to content

Commit cd2f467

Browse files
authored
FE-719 feat(load3d): add FBX export support (#12323)
## Summary implement fbx export, using our own lib fbx-exporter-three ## Screenshots (if applicable) https://github.com/user-attachments/assets/80012338-d065-4a00-a9a0-0a2e73d67db4 ┆Issue is synchronized with this [Notion page](https://www.notion.so/PR-12323-FE-719-feat-load3d-add-FBX-export-support-3656d73d365081ef901ffe880ae9568a) by [Unito](https://www.unito.io)
1 parent 38fed22 commit cd2f467

11 files changed

Lines changed: 416 additions & 25 deletions

File tree

package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,7 @@
6060
"@atlaskit/pragmatic-drag-and-drop": "^1.3.1",
6161
"@comfyorg/comfyui-electron-types": "catalog:",
6262
"@comfyorg/design-system": "workspace:*",
63+
"@comfyorg/fbx-exporter-three": "^1.0.1",
6364
"@comfyorg/object-info-parser": "workspace:*",
6465
"@comfyorg/registry-types": "workspace:*",
6566
"@comfyorg/shared-frontend-utils": "workspace:*",

pnpm-lock.yaml

Lines changed: 33 additions & 12 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/components/load3d/controls/ExportControls.vue

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,8 @@ const showExportFormats = ref(false)
4848
const exportFormats = [
4949
{ label: 'GLB', value: 'glb' },
5050
{ label: 'OBJ', value: 'obj' },
51-
{ label: 'STL', value: 'stl' }
51+
{ label: 'STL', value: 'stl' },
52+
{ label: 'FBX', value: 'fbx' }
5253
]
5354
5455
function toggleExportFormats() {

src/components/load3d/controls/viewer/ViewerExportControls.test.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -81,12 +81,12 @@ function renderComponent(onExportModel?: (format: string) => void) {
8181
}
8282

8383
describe('ViewerExportControls', () => {
84-
it('renders all three export format options', () => {
84+
it('renders all four export format options', () => {
8585
renderComponent()
8686
const select = screen.getByRole('combobox') as HTMLSelectElement
8787
const optionValues = Array.from(select.options).map((o) => o.value)
8888

89-
expect(optionValues).toEqual(['glb', 'obj', 'stl'])
89+
expect(optionValues).toEqual(['glb', 'obj', 'stl', 'fbx'])
9090
})
9191

9292
it('defaults the export format to obj', () => {

src/components/load3d/controls/viewer/ViewerExportControls.vue

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,8 @@ const emit = defineEmits<{
4242
const exportFormats = [
4343
{ label: 'GLB', value: 'glb' },
4444
{ label: 'OBJ', value: 'obj' },
45-
{ label: 'STL', value: 'stl' }
45+
{ label: 'STL', value: 'stl' },
46+
{ label: 'FBX', value: 'fbx' }
4647
]
4748
4849
const exportFormat = ref('obj')

0 commit comments

Comments
 (0)