# PolyScan 3D Model Converter

Convert 3D model packages locally in a modern web browser at `/studio/3d-model-converter`.

## Inputs

Common formats such as GLB, glTF, FBX, OBJ, STL, PLY, DAE, 3DS, 3MF, AMF, USDZ, and STEP use dedicated readers. Assimp WebAssembly provides broader compatibility for formats such as OFF, DXF, LWO, X, MD2, SMD, and others. The exact result depends on the features present in the source file and importer.

Upload the complete folder or a ZIP when a model references external MTL, BIN, image, or texture files. Files are resolved inside the browser and are not uploaded to PolyScan.

When an OBJ/MTL or FBX has no texture links, missing PBR slots can be filled from image filename hints: Albedo/BaseColor/Diffuse, Normal, Roughness, Metallic, AO, Opacity, Emissive, and Height. One texture set is automatically applied to a single-material model. Multi-material models use material-name prefixes; ambiguous matches are left unchanged with a warning. Existing texture links are preserved. DirectX normal maps are corrected for the preview and GLB export. UV coordinates must already exist in the model.

The package panel counts separate image files; the preview counts textures actually assigned to materials, including embedded textures. Check the preview and auto-mapping summary before converting. GLB embeds assigned maps (roughness and metalness share a packed image); it does not embed arbitrary unused files. Filename matching identifies map roles, not the visual content of an image.

FBX/Phong-to-PBR adaptation preserves both emissive color and intensity, including zero. Some FBX exporters write a white emissive color while disabling it with a zero intensity; dropping the intensity washes out the preview and exported GLB.

GLB/glTF export folds emission strengths below one into the core emissive color, avoiding reliance on `KHR_materials_emissive_strength` for disabled/dim emission in older viewers. The original preview material is restored after export, including failures. HDR emission above one still uses the optional extension.

## Outputs

- GLB and embedded glTF can preserve hierarchy, PBR materials, textures, skinning, and animation.
- Binary FBX export is beta and should be tested in the destination application for complex rigs.
- OBJ downloads as a ZIP with MTL and matched source textures; animation and skinning are not stored.
- STL and PLY are static mesh formats and do not store image textures or animation.
- USDZ is intended for Apple AR and Quick Look workflows.
- STEP export is beta and produces faceted B-rep geometry from mesh triangles. It does not reconstruct editable CAD surfaces.

Conversion and preview use the visitor's CPU and GPU. Large files may be limited by available device memory.
