baozi3d 0.1.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- baozi3d-0.1.0/Cargo.toml +94 -0
- baozi3d-0.1.0/LICENSE-APACHE +201 -0
- baozi3d-0.1.0/LICENSE-MIT +21 -0
- baozi3d-0.1.0/PKG-INFO +143 -0
- baozi3d-0.1.0/README.md +106 -0
- baozi3d-0.1.0/THIRD_PARTY_NOTICES.md +18586 -0
- baozi3d-0.1.0/bindings/baozi-python/Cargo.lock +1070 -0
- baozi3d-0.1.0/bindings/baozi-python/Cargo.toml +32 -0
- baozi3d-0.1.0/bindings/baozi-python/LICENSE-APACHE +201 -0
- baozi3d-0.1.0/bindings/baozi-python/LICENSE-MIT +21 -0
- baozi3d-0.1.0/bindings/baozi-python/README.md +106 -0
- baozi3d-0.1.0/bindings/baozi-python/THIRD_PARTY_NOTICES.md +18586 -0
- baozi3d-0.1.0/bindings/baozi-python/src/buffer.rs +252 -0
- baozi3d-0.1.0/bindings/baozi-python/src/error.rs +205 -0
- baozi3d-0.1.0/bindings/baozi-python/src/lib.rs +157 -0
- baozi3d-0.1.0/bindings/baozi-python/src/mesh.rs +326 -0
- baozi3d-0.1.0/bindings/baozi-python/src/options.rs +200 -0
- baozi3d-0.1.0/bindings/baozi-python/src/report.rs +434 -0
- baozi3d-0.1.0/bindings/baozi-python/src/scene.rs +565 -0
- baozi3d-0.1.0/bindings/baozi-python/tests/test_baozi3d.py +921 -0
- baozi3d-0.1.0/bindings/baozi-python/tests/type_smoke.py +148 -0
- baozi3d-0.1.0/crates/baozi/Cargo.toml +149 -0
- baozi3d-0.1.0/crates/baozi/LICENSE-APACHE +201 -0
- baozi3d-0.1.0/crates/baozi/LICENSE-MIT +21 -0
- baozi3d-0.1.0/crates/baozi/README.md +65 -0
- baozi3d-0.1.0/crates/baozi/benches/conditioning_scale_probe.rs +133 -0
- baozi3d-0.1.0/crates/baozi/benches/import_baseline.rs +36 -0
- baozi3d-0.1.0/crates/baozi/benches/import_scale_probe.rs +44 -0
- baozi3d-0.1.0/crates/baozi/benches/support/scale_fixture.rs +21 -0
- baozi3d-0.1.0/crates/baozi/examples/custom_format.rs +39 -0
- baozi3d-0.1.0/crates/baozi/examples/custom_pass_and_exporter.rs +61 -0
- baozi3d-0.1.0/crates/baozi/examples/diagnostics_and_cancel.rs +19 -0
- baozi3d-0.1.0/crates/baozi/examples/engine_vertex_layout.rs +67 -0
- baozi3d-0.1.0/crates/baozi/examples/export_glb.rs +12 -0
- baozi3d-0.1.0/crates/baozi/examples/gltf_scenes_and_vrm.rs +30 -0
- baozi3d-0.1.0/crates/baozi/examples/load_bytes.rs +6 -0
- baozi3d-0.1.0/crates/baozi/examples/load_file.rs +14 -0
- baozi3d-0.1.0/crates/baozi/examples/retro_archive.rs +548 -0
- baozi3d-0.1.0/crates/baozi/examples/wasm_memory_io.rs +53 -0
- baozi3d-0.1.0/crates/baozi/src/export.rs +300 -0
- baozi3d-0.1.0/crates/baozi/src/formats/mod.rs +85 -0
- baozi3d-0.1.0/crates/baozi/src/import_report.rs +190 -0
- baozi3d-0.1.0/crates/baozi/src/importer.rs +564 -0
- baozi3d-0.1.0/crates/baozi/src/lib.rs +112 -0
- baozi3d-0.1.0/crates/baozi/tests/dependency_discovery.rs +179 -0
- baozi3d-0.1.0/crates/baozi/tests/ecosystem_dx.rs +369 -0
- baozi3d-0.1.0/crates/baozi/tests/ecosystem_extensions.rs +466 -0
- baozi3d-0.1.0/crates/baozi/tests/export_features.rs +63 -0
- baozi3d-0.1.0/crates/baozi/tests/export_roundtrip.rs +243 -0
- baozi3d-0.1.0/crates/baozi/tests/fixtures/arm.mjcf +14 -0
- baozi3d-0.1.0/crates/baozi/tests/fixtures/hinge.urdf +9 -0
- baozi3d-0.1.0/crates/baozi/tests/fixtures/motion.bvh +16 -0
- baozi3d-0.1.0/crates/baozi/tests/formats/mtl.rs +1135 -0
- baozi3d-0.1.0/crates/baozi/tests/formats/obj.rs +633 -0
- baozi3d-0.1.0/crates/baozi/tests/formats/ply.rs +751 -0
- baozi3d-0.1.0/crates/baozi/tests/formats/stl.rs +470 -0
- baozi3d-0.1.0/crates/baozi/tests/gltf_compression.rs +349 -0
- baozi3d-0.1.0/crates/baozi/tests/gltf_export/sparse_morph.rs +637 -0
- baozi3d-0.1.0/crates/baozi/tests/gltf_export/spec_gloss.rs +293 -0
- baozi3d-0.1.0/crates/baozi/tests/gltf_export.rs +2098 -0
- baozi3d-0.1.0/crates/baozi/tests/gltf_export_losses.rs +413 -0
- baozi3d-0.1.0/crates/baozi/tests/gltf_instancing_space.rs +123 -0
- baozi3d-0.1.0/crates/baozi/tests/gltf_modern_textures.rs +548 -0
- baozi3d-0.1.0/crates/baozi/tests/gltf_provenance.rs +266 -0
- baozi3d-0.1.0/crates/baozi/tests/gltf_xmp.rs +213 -0
- baozi3d-0.1.0/crates/baozi/tests/importer_facade.rs +298 -0
- baozi3d-0.1.0/crates/baozi/tests/integration.rs +193 -0
- baozi3d-0.1.0/crates/baozi/tests/motion_robotics_roundtrip.rs +150 -0
- baozi3d-0.1.0/crates/baozi/tests/usd_instancer_display.rs +148 -0
- baozi3d-0.1.0/crates/baozi-core/Cargo.toml +33 -0
- baozi3d-0.1.0/crates/baozi-core/LICENSE-APACHE +201 -0
- baozi3d-0.1.0/crates/baozi-core/LICENSE-MIT +21 -0
- baozi3d-0.1.0/crates/baozi-core/README.md +16 -0
- baozi3d-0.1.0/crates/baozi-core/src/animation/pointer/material.rs +212 -0
- baozi3d-0.1.0/crates/baozi-core/src/animation/pointer.rs +444 -0
- baozi3d-0.1.0/crates/baozi-core/src/animation.rs +224 -0
- baozi3d-0.1.0/crates/baozi-core/src/attribute.rs +307 -0
- baozi3d-0.1.0/crates/baozi-core/src/bytes.rs +93 -0
- baozi3d-0.1.0/crates/baozi-core/src/camera.rs +146 -0
- baozi3d-0.1.0/crates/baozi-core/src/control.rs +25 -0
- baozi3d-0.1.0/crates/baozi-core/src/deform.rs +212 -0
- baozi3d-0.1.0/crates/baozi-core/src/features.rs +513 -0
- baozi3d-0.1.0/crates/baozi-core/src/id.rs +101 -0
- baozi3d-0.1.0/crates/baozi-core/src/lib.rs +48 -0
- baozi3d-0.1.0/crates/baozi-core/src/light.rs +143 -0
- baozi3d-0.1.0/crates/baozi-core/src/material.rs +567 -0
- baozi3d-0.1.0/crates/baozi-core/src/math/aabb.rs +139 -0
- baozi3d-0.1.0/crates/baozi-core/src/math/mat.rs +469 -0
- baozi3d-0.1.0/crates/baozi-core/src/math/mod.rs +80 -0
- baozi3d-0.1.0/crates/baozi-core/src/math/quat.rs +204 -0
- baozi3d-0.1.0/crates/baozi-core/src/math/vec.rs +148 -0
- baozi3d-0.1.0/crates/baozi-core/src/mesh.rs +414 -0
- baozi3d-0.1.0/crates/baozi-core/src/metadata.rs +37 -0
- baozi3d-0.1.0/crates/baozi-core/src/node.rs +141 -0
- baozi3d-0.1.0/crates/baozi-core/src/scene/append.rs +350 -0
- baozi3d-0.1.0/crates/baozi-core/src/scene/extract.rs +458 -0
- baozi3d-0.1.0/crates/baozi-core/src/scene/fit.rs +386 -0
- baozi3d-0.1.0/crates/baozi-core/src/scene/queries.rs +140 -0
- baozi3d-0.1.0/crates/baozi-core/src/scene.rs +661 -0
- baozi3d-0.1.0/crates/baozi-core/src/space.rs +343 -0
- baozi3d-0.1.0/crates/baozi-core/src/texture.rs +832 -0
- baozi3d-0.1.0/crates/baozi-core/src/validate/error.rs +169 -0
- baozi3d-0.1.0/crates/baozi-core/src/validate.rs +653 -0
- baozi3d-0.1.0/crates/baozi-core/src/vrm/avatar.rs +598 -0
- baozi3d-0.1.0/crates/baozi-core/src/vrm/constraints.rs +111 -0
- baozi3d-0.1.0/crates/baozi-core/src/vrm/spring_bone.rs +406 -0
- baozi3d-0.1.0/crates/baozi-core/src/vrm/validation.rs +371 -0
- baozi3d-0.1.0/crates/baozi-core/src/vrm.rs +204 -0
- baozi3d-0.1.0/crates/baozi-core/tests/buffer_transfers.rs +128 -0
- baozi3d-0.1.0/crates/baozi-core/tests/core/scene.rs +564 -0
- baozi3d-0.1.0/crates/baozi-core/tests/core/validation.rs +869 -0
- baozi3d-0.1.0/crates/baozi-core/tests/core.rs +615 -0
- baozi3d-0.1.0/crates/baozi-core/tests/features.rs +496 -0
- baozi3d-0.1.0/crates/baozi-core/tests/math_and_animation.rs +232 -0
- baozi3d-0.1.0/crates/baozi-core/tests/scene_api.rs +213 -0
- baozi3d-0.1.0/crates/baozi-core/tests/scene_composition.rs +966 -0
- baozi3d-0.1.0/crates/baozi-core/tests/scene_fit.rs +187 -0
- baozi3d-0.1.0/crates/baozi-core/tests/vrm.rs +899 -0
- baozi3d-0.1.0/crates/baozi-draco/Cargo.toml +31 -0
- baozi3d-0.1.0/crates/baozi-draco/LICENSE-APACHE +201 -0
- baozi3d-0.1.0/crates/baozi-draco/LICENSE-MIT +21 -0
- baozi3d-0.1.0/crates/baozi-draco/README.md +38 -0
- baozi3d-0.1.0/crates/baozi-draco/src/attributes/compat.rs +167 -0
- baozi3d-0.1.0/crates/baozi-draco/src/attributes/decode.rs +367 -0
- baozi3d-0.1.0/crates/baozi-draco/src/attributes/dequantize.rs +24 -0
- baozi3d-0.1.0/crates/baozi-draco/src/attributes/mod.rs +85 -0
- baozi3d-0.1.0/crates/baozi-draco/src/attributes/prediction.rs +195 -0
- baozi3d-0.1.0/crates/baozi-draco/src/bitstream.rs +63 -0
- baozi3d-0.1.0/crates/baozi-draco/src/budget.rs +156 -0
- baozi3d-0.1.0/crates/baozi-draco/src/connectivity/edgebreaker.rs +244 -0
- baozi3d-0.1.0/crates/baozi-draco/src/connectivity/mod.rs +62 -0
- baozi3d-0.1.0/crates/baozi-draco/src/connectivity/sequential.rs +63 -0
- baozi3d-0.1.0/crates/baozi-draco/src/connectivity/strip.rs +279 -0
- baozi3d-0.1.0/crates/baozi-draco/src/header.rs +94 -0
- baozi3d-0.1.0/crates/baozi-draco/src/lib.rs +232 -0
- baozi3d-0.1.0/crates/baozi-draco/src/output.rs +276 -0
- baozi3d-0.1.0/crates/baozi-draco/src/rans.rs +217 -0
- baozi3d-0.1.0/crates/baozi-draco/src/tests.rs +254 -0
- baozi3d-0.1.0/crates/baozi-draco/tests/decode.rs +663 -0
- baozi3d-0.1.0/crates/baozi-draco/tests/fixtures/mod.rs +142 -0
- baozi3d-0.1.0/crates/baozi-draco/tests/resource_accounting.rs +58 -0
- baozi3d-0.1.0/crates/baozi-draco/tests/strip_topology.rs +111 -0
- baozi3d-0.1.0/crates/baozi-eval/Cargo.toml +26 -0
- baozi3d-0.1.0/crates/baozi-eval/LICENSE-APACHE +201 -0
- baozi3d-0.1.0/crates/baozi-eval/LICENSE-MIT +21 -0
- baozi3d-0.1.0/crates/baozi-eval/README.md +90 -0
- baozi3d-0.1.0/crates/baozi-eval/src/animation/pointers.rs +142 -0
- baozi3d-0.1.0/crates/baozi-eval/src/animation.rs +471 -0
- baozi3d-0.1.0/crates/baozi-eval/src/bake/instance.rs +235 -0
- baozi3d-0.1.0/crates/baozi-eval/src/bake/primitive.rs +367 -0
- baozi3d-0.1.0/crates/baozi-eval/src/bake.rs +462 -0
- baozi3d-0.1.0/crates/baozi-eval/src/constraints/rotation.rs +188 -0
- baozi3d-0.1.0/crates/baozi-eval/src/constraints.rs +327 -0
- baozi3d-0.1.0/crates/baozi-eval/src/deform/morphs.rs +311 -0
- baozi3d-0.1.0/crates/baozi-eval/src/deform.rs +694 -0
- baozi3d-0.1.0/crates/baozi-eval/src/error.rs +75 -0
- baozi3d-0.1.0/crates/baozi-eval/src/lib.rs +53 -0
- baozi3d-0.1.0/crates/baozi-eval/src/meshlets/bounds.rs +224 -0
- baozi3d-0.1.0/crates/baozi-eval/src/meshlets/math.rs +71 -0
- baozi3d-0.1.0/crates/baozi-eval/src/meshlets/partition.rs +264 -0
- baozi3d-0.1.0/crates/baozi-eval/src/meshlets.rs +202 -0
- baozi3d-0.1.0/crates/baozi-eval/src/pack.rs +638 -0
- baozi3d-0.1.0/crates/baozi-eval/src/pose.rs +372 -0
- baozi3d-0.1.0/crates/baozi-eval/src/quality/links.rs +82 -0
- baozi3d-0.1.0/crates/baozi-eval/src/quality/measure.rs +187 -0
- baozi3d-0.1.0/crates/baozi-eval/src/quality.rs +408 -0
- baozi3d-0.1.0/crates/baozi-eval/src/spatial.rs +117 -0
- baozi3d-0.1.0/crates/baozi-eval/src/spring_bone.rs +710 -0
- baozi3d-0.1.0/crates/baozi-eval/src/winding.rs +137 -0
- baozi3d-0.1.0/crates/baozi-eval/tests/animation.rs +650 -0
- baozi3d-0.1.0/crates/baozi-eval/tests/bake.rs +667 -0
- baozi3d-0.1.0/crates/baozi-eval/tests/constraints.rs +381 -0
- baozi3d-0.1.0/crates/baozi-eval/tests/deform.rs +597 -0
- baozi3d-0.1.0/crates/baozi-eval/tests/meshlets.rs +501 -0
- baozi3d-0.1.0/crates/baozi-eval/tests/pack.rs +556 -0
- baozi3d-0.1.0/crates/baozi-eval/tests/pack_reuse/allocations.rs +90 -0
- baozi3d-0.1.0/crates/baozi-eval/tests/pack_reuse.rs +147 -0
- baozi3d-0.1.0/crates/baozi-eval/tests/quality.rs +326 -0
- baozi3d-0.1.0/crates/baozi-eval/tests/skin_palette.rs +246 -0
- baozi3d-0.1.0/crates/baozi-eval/tests/spatial.rs +65 -0
- baozi3d-0.1.0/crates/baozi-eval/tests/spring_bone.rs +603 -0
- baozi3d-0.1.0/crates/baozi-eval/tests/vertex_layout_derive.rs +132 -0
- baozi3d-0.1.0/crates/baozi-eval/tests/vertex_layout_derive_ui.md +156 -0
- baozi3d-0.1.0/crates/baozi-export/Cargo.toml +50 -0
- baozi3d-0.1.0/crates/baozi-export/LICENSE-APACHE +201 -0
- baozi3d-0.1.0/crates/baozi-export/LICENSE-MIT +21 -0
- baozi3d-0.1.0/crates/baozi-export/README.md +52 -0
- baozi3d-0.1.0/crates/baozi-export/src/context.rs +279 -0
- baozi3d-0.1.0/crates/baozi-export/src/error.rs +109 -0
- baozi3d-0.1.0/crates/baozi-export/src/formats/mod.rs +17 -0
- baozi3d-0.1.0/crates/baozi-export/src/formats/obj/mtl.rs +670 -0
- baozi3d-0.1.0/crates/baozi-export/src/formats/obj.rs +689 -0
- baozi3d-0.1.0/crates/baozi-export/src/formats/ply/properties.rs +595 -0
- baozi3d-0.1.0/crates/baozi-export/src/formats/ply/writer.rs +108 -0
- baozi3d-0.1.0/crates/baozi-export/src/formats/ply.rs +447 -0
- baozi3d-0.1.0/crates/baozi-export/src/formats/stl.rs +592 -0
- baozi3d-0.1.0/crates/baozi-export/src/lib.rs +22 -0
- baozi3d-0.1.0/crates/baozi-export/src/options.rs +196 -0
- baozi3d-0.1.0/crates/baozi-export/src/registry/file/tests.rs +322 -0
- baozi3d-0.1.0/crates/baozi-export/src/registry/file.rs +509 -0
- baozi3d-0.1.0/crates/baozi-export/src/registry.rs +653 -0
- baozi3d-0.1.0/crates/baozi-export/src/report.rs +47 -0
- baozi3d-0.1.0/crates/baozi-export/src/sink.rs +151 -0
- baozi3d-0.1.0/crates/baozi-export/src/util/animation.rs +192 -0
- baozi3d-0.1.0/crates/baozi-export/src/util.rs +285 -0
- baozi3d-0.1.0/crates/baozi-export/tests/file_overwrite.rs +235 -0
- baozi3d-0.1.0/crates/baozi-export/tests/file_staging.rs +82 -0
- baozi3d-0.1.0/crates/baozi-export/tests/obj.rs +493 -0
- baozi3d-0.1.0/crates/baozi-export/tests/plugin.rs +509 -0
- baozi3d-0.1.0/crates/baozi-export/tests/ply.rs +499 -0
- baozi3d-0.1.0/crates/baozi-export/tests/sink.rs +429 -0
- baozi3d-0.1.0/crates/baozi-export/tests/stl.rs +638 -0
- baozi3d-0.1.0/crates/baozi-export/tests/surface_winding.rs +196 -0
- baozi3d-0.1.0/crates/baozi-export-3mf/Cargo.toml +28 -0
- baozi3d-0.1.0/crates/baozi-export-3mf/LICENSE-APACHE +201 -0
- baozi3d-0.1.0/crates/baozi-export-3mf/LICENSE-MIT +21 -0
- baozi3d-0.1.0/crates/baozi-export-3mf/README.md +19 -0
- baozi3d-0.1.0/crates/baozi-export-3mf/src/appearance/properties.rs +309 -0
- baozi3d-0.1.0/crates/baozi-export-3mf/src/appearance/textures.rs +221 -0
- baozi3d-0.1.0/crates/baozi-export-3mf/src/appearance.rs +258 -0
- baozi3d-0.1.0/crates/baozi-export-3mf/src/geometry.rs +464 -0
- baozi3d-0.1.0/crates/baozi-export-3mf/src/graph.rs +468 -0
- baozi3d-0.1.0/crates/baozi-export-3mf/src/lib.rs +244 -0
- baozi3d-0.1.0/crates/baozi-export-3mf/src/package.rs +144 -0
- baozi3d-0.1.0/crates/baozi-export-3mf/src/space.rs +119 -0
- baozi3d-0.1.0/crates/baozi-export-3mf/src/xml.rs +80 -0
- baozi3d-0.1.0/crates/baozi-export-3mf/tests/threemf.rs +841 -0
- baozi3d-0.1.0/crates/baozi-export-gltf/Cargo.toml +33 -0
- baozi3d-0.1.0/crates/baozi-export-gltf/LICENSE-APACHE +201 -0
- baozi3d-0.1.0/crates/baozi-export-gltf/LICENSE-MIT +21 -0
- baozi3d-0.1.0/crates/baozi-export-gltf/README.md +39 -0
- baozi3d-0.1.0/crates/baozi-export-gltf/src/animation/morph.rs +613 -0
- baozi3d-0.1.0/crates/baozi-export-gltf/src/animation/pointer.rs +313 -0
- baozi3d-0.1.0/crates/baozi-export-gltf/src/animation.rs +371 -0
- baozi3d-0.1.0/crates/baozi-export-gltf/src/appearance/binding.rs +369 -0
- baozi3d-0.1.0/crates/baozi-export-gltf/src/appearance/material.rs +701 -0
- baozi3d-0.1.0/crates/baozi-export-gltf/src/appearance/mtoon.rs +122 -0
- baozi3d-0.1.0/crates/baozi-export-gltf/src/appearance/tests/spec_gloss.rs +126 -0
- baozi3d-0.1.0/crates/baozi-export-gltf/src/appearance/tests.rs +713 -0
- baozi3d-0.1.0/crates/baozi-export-gltf/src/appearance.rs +713 -0
- baozi3d-0.1.0/crates/baozi-export-gltf/src/compression.rs +444 -0
- baozi3d-0.1.0/crates/baozi-export-gltf/src/document.rs +405 -0
- baozi3d-0.1.0/crates/baozi-export-gltf/src/extensions.rs +698 -0
- baozi3d-0.1.0/crates/baozi-export-gltf/src/geometry/deformation.rs +322 -0
- baozi3d-0.1.0/crates/baozi-export-gltf/src/geometry.rs +743 -0
- baozi3d-0.1.0/crates/baozi-export-gltf/src/graph.rs +721 -0
- baozi3d-0.1.0/crates/baozi-export-gltf/src/lib.rs +716 -0
- baozi3d-0.1.0/crates/baozi-export-gltf/src/meshopt/filter.rs +240 -0
- baozi3d-0.1.0/crates/baozi-export-gltf/src/meshopt/tests.rs +175 -0
- baozi3d-0.1.0/crates/baozi-export-gltf/src/meshopt/triangles.rs +136 -0
- baozi3d-0.1.0/crates/baozi-export-gltf/src/meshopt.rs +228 -0
- baozi3d-0.1.0/crates/baozi-export-gltf/src/options.rs +96 -0
- baozi3d-0.1.0/crates/baozi-export-gltf/src/tests.rs +86 -0
- baozi3d-0.1.0/crates/baozi-export-gltf/src/vrm/avatar.rs +394 -0
- baozi3d-0.1.0/crates/baozi-export-gltf/src/vrm/spring.rs +117 -0
- baozi3d-0.1.0/crates/baozi-export-gltf/src/vrm.rs +291 -0
- baozi3d-0.1.0/crates/baozi-export-gltf/src/xmp.rs +67 -0
- baozi3d-0.1.0/crates/baozi-export-gltf/tests/common/mod.rs +8 -0
- baozi3d-0.1.0/crates/baozi-export-gltf/tests/gltf_animation_pointer.rs +574 -0
- baozi3d-0.1.0/crates/baozi-export-gltf/tests/gltf_cancellation.rs +74 -0
- baozi3d-0.1.0/crates/baozi-export-gltf/tests/gltf_extensions.rs +1057 -0
- baozi3d-0.1.0/crates/baozi-export-gltf/tests/gltf_modern_materials.rs +85 -0
- baozi3d-0.1.0/crates/baozi-export-gltf/tests/gltf_node_visibility.rs +163 -0
- baozi3d-0.1.0/crates/baozi-export-gltf/tests/gltf_transforms.rs +178 -0
- baozi3d-0.1.0/crates/baozi-export-gltf/tests/uv_space_animation.rs +265 -0
- baozi3d-0.1.0/crates/baozi-export-gltf/tests/vrm.rs +215 -0
- baozi3d-0.1.0/crates/baozi-export-usd/Cargo.toml +35 -0
- baozi3d-0.1.0/crates/baozi-export-usd/LICENSE-APACHE +201 -0
- baozi3d-0.1.0/crates/baozi-export-usd/LICENSE-MIT +21 -0
- baozi3d-0.1.0/crates/baozi-export-usd/README.md +21 -0
- baozi3d-0.1.0/crates/baozi-export-usd/src/animation.rs +373 -0
- baozi3d-0.1.0/crates/baozi-export-usd/src/deform/influences.rs +129 -0
- baozi3d-0.1.0/crates/baozi-export-usd/src/deform/morph.rs +146 -0
- baozi3d-0.1.0/crates/baozi-export-usd/src/deform.rs +397 -0
- baozi3d-0.1.0/crates/baozi-export-usd/src/geometry/attributes/normals.rs +220 -0
- baozi3d-0.1.0/crates/baozi-export-usd/src/geometry/attributes.rs +374 -0
- baozi3d-0.1.0/crates/baozi-export-usd/src/geometry/binding.rs +87 -0
- baozi3d-0.1.0/crates/baozi-export-usd/src/geometry/tests.rs +545 -0
- baozi3d-0.1.0/crates/baozi-export-usd/src/geometry.rs +288 -0
- baozi3d-0.1.0/crates/baozi-export-usd/src/layer.rs +260 -0
- baozi3d-0.1.0/crates/baozi-export-usd/src/lib.rs +150 -0
- baozi3d-0.1.0/crates/baozi-export-usd/src/materials/image.rs +272 -0
- baozi3d-0.1.0/crates/baozi-export-usd/src/materials/preview.rs +401 -0
- baozi3d-0.1.0/crates/baozi-export-usd/src/materials/tests.rs +366 -0
- baozi3d-0.1.0/crates/baozi-export-usd/src/materials/texture/network.rs +219 -0
- baozi3d-0.1.0/crates/baozi-export-usd/src/materials/texture.rs +465 -0
- baozi3d-0.1.0/crates/baozi-export-usd/src/materials.rs +141 -0
- baozi3d-0.1.0/crates/baozi-export-usd/src/project.rs +555 -0
- baozi3d-0.1.0/crates/baozi-export-usd/src/tests.rs +54 -0
- baozi3d-0.1.0/crates/baozi-export-usd/src/usda.rs +304 -0
- baozi3d-0.1.0/crates/baozi-export-usd/src/usdc/encode.rs +188 -0
- baozi3d-0.1.0/crates/baozi-export-usd/src/usdc/lz4.rs +202 -0
- baozi3d-0.1.0/crates/baozi-export-usd/src/usdc/paths.rs +161 -0
- baozi3d-0.1.0/crates/baozi-export-usd/src/usdc/tables.rs +286 -0
- baozi3d-0.1.0/crates/baozi-export-usd/src/usdc/tests.rs +289 -0
- baozi3d-0.1.0/crates/baozi-export-usd/src/usdc/values.rs +377 -0
- baozi3d-0.1.0/crates/baozi-export-usd/src/usdc.rs +158 -0
- baozi3d-0.1.0/crates/baozi-export-usd/src/usdz/tests.rs +271 -0
- baozi3d-0.1.0/crates/baozi-export-usd/src/usdz.rs +342 -0
- baozi3d-0.1.0/crates/baozi-export-usd/src/visuals.rs +198 -0
- baozi3d-0.1.0/crates/baozi-export-usd/tests/display_glb.rs +44 -0
- baozi3d-0.1.0/crates/baozi-export-usd/tests/usd.rs +1139 -0
- baozi3d-0.1.0/crates/baozi-format-3mf/Cargo.toml +25 -0
- baozi3d-0.1.0/crates/baozi-format-3mf/LICENSE-APACHE +201 -0
- baozi3d-0.1.0/crates/baozi-format-3mf/LICENSE-MIT +21 -0
- baozi3d-0.1.0/crates/baozi-format-3mf/README.md +16 -0
- baozi3d-0.1.0/crates/baozi-format-3mf/src/assemble.rs +218 -0
- baozi3d-0.1.0/crates/baozi-format-3mf/src/lib.rs +85 -0
- baozi3d-0.1.0/crates/baozi-format-3mf/src/model.rs +745 -0
- baozi3d-0.1.0/crates/baozi-format-3mf/src/opc.rs +417 -0
- baozi3d-0.1.0/crates/baozi-format-3mf/src/surface.rs +453 -0
- baozi3d-0.1.0/crates/baozi-format-3mf/src/xml.rs +226 -0
- baozi3d-0.1.0/crates/baozi-format-3mf/tests/image_load_policy.rs +217 -0
- baozi3d-0.1.0/crates/baozi-format-3mf/tests/threemf.rs +1317 -0
- baozi3d-0.1.0/crates/baozi-format-bvh/Cargo.toml +21 -0
- baozi3d-0.1.0/crates/baozi-format-bvh/LICENSE-APACHE +201 -0
- baozi3d-0.1.0/crates/baozi-format-bvh/LICENSE-MIT +21 -0
- baozi3d-0.1.0/crates/baozi-format-bvh/README.md +28 -0
- baozi3d-0.1.0/crates/baozi-format-bvh/src/lib.rs +44 -0
- baozi3d-0.1.0/crates/baozi-format-bvh/src/parser/motion.rs +239 -0
- baozi3d-0.1.0/crates/baozi-format-bvh/src/parser.rs +510 -0
- baozi3d-0.1.0/crates/baozi-format-bvh/tests/import.rs +540 -0
- baozi3d-0.1.0/crates/baozi-format-collada/Cargo.toml +22 -0
- baozi3d-0.1.0/crates/baozi-format-collada/LICENSE-APACHE +201 -0
- baozi3d-0.1.0/crates/baozi-format-collada/LICENSE-MIT +21 -0
- baozi3d-0.1.0/crates/baozi-format-collada/README.md +44 -0
- baozi3d-0.1.0/crates/baozi-format-collada/src/animation/clips.rs +165 -0
- baozi3d-0.1.0/crates/baozi-format-collada/src/animation/curve.rs +400 -0
- baozi3d-0.1.0/crates/baozi-format-collada/src/animation/output.rs +428 -0
- baozi3d-0.1.0/crates/baozi-format-collada/src/animation/targets.rs +531 -0
- baozi3d-0.1.0/crates/baozi-format-collada/src/animation/trs.rs +386 -0
- baozi3d-0.1.0/crates/baozi-format-collada/src/animation.rs +216 -0
- baozi3d-0.1.0/crates/baozi-format-collada/src/controllers/morph.rs +174 -0
- baozi3d-0.1.0/crates/baozi-format-collada/src/controllers/skin.rs +377 -0
- baozi3d-0.1.0/crates/baozi-format-collada/src/controllers.rs +190 -0
- baozi3d-0.1.0/crates/baozi-format-collada/src/discovery.rs +127 -0
- baozi3d-0.1.0/crates/baozi-format-collada/src/extra.rs +176 -0
- baozi3d-0.1.0/crates/baozi-format-collada/src/geometry/inputs.rs +535 -0
- baozi3d-0.1.0/crates/baozi-format-collada/src/geometry/topology.rs +239 -0
- baozi3d-0.1.0/crates/baozi-format-collada/src/geometry.rs +193 -0
- baozi3d-0.1.0/crates/baozi-format-collada/src/lib.rs +142 -0
- baozi3d-0.1.0/crates/baozi-format-collada/src/materials/images.rs +227 -0
- baozi3d-0.1.0/crates/baozi-format-collada/src/materials/textures.rs +181 -0
- baozi3d-0.1.0/crates/baozi-format-collada/src/materials/uv.rs +194 -0
- baozi3d-0.1.0/crates/baozi-format-collada/src/materials.rs +576 -0
- baozi3d-0.1.0/crates/baozi-format-collada/src/scene/attachments.rs +515 -0
- baozi3d-0.1.0/crates/baozi-format-collada/src/scene.rs +340 -0
- baozi3d-0.1.0/crates/baozi-format-collada/src/source.rs +313 -0
- baozi3d-0.1.0/crates/baozi-format-collada/src/transform.rs +198 -0
- baozi3d-0.1.0/crates/baozi-format-collada/src/visuals.rs +204 -0
- baozi3d-0.1.0/crates/baozi-format-collada/src/xml.rs +489 -0
- baozi3d-0.1.0/crates/baozi-format-collada/tests/animation.rs +705 -0
- baozi3d-0.1.0/crates/baozi-format-collada/tests/appearance.rs +789 -0
- baozi3d-0.1.0/crates/baozi-format-collada/tests/controllers.rs +401 -0
- baozi3d-0.1.0/crates/baozi-format-collada/tests/custom_properties.rs +370 -0
- baozi3d-0.1.0/crates/baozi-format-collada/tests/document.rs +339 -0
- baozi3d-0.1.0/crates/baozi-format-collada/tests/geometry.rs +332 -0
- baozi3d-0.1.0/crates/baozi-format-collada/tests/image_load_policy.rs +318 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/Cargo.toml +29 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/LICENSE-APACHE +201 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/LICENSE-MIT +21 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/README.md +20 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/src/animation/connections.rs +537 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/src/animation/curve.rs +464 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/src/animation/layers/scalar.rs +150 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/src/animation/layers.rs +264 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/src/animation/output/inbetween.rs +302 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/src/animation/output/morph.rs +165 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/src/animation/output.rs +417 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/src/animation/rotation.rs +407 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/src/animation/signal/profile.rs +479 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/src/animation/signal/weighted.rs +195 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/src/animation/signal.rs +323 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/src/animation.rs +126 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/src/ascii.rs +404 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/src/binary.rs +447 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/src/cameras_lights.rs +503 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/src/deform/bind.rs +139 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/src/deform/blend.rs +462 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/src/deform/skin.rs +594 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/src/deform.rs +143 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/src/discovery.rs +170 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/src/document.rs +264 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/src/geometry/edges.rs +108 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/src/geometry/layers/values.rs +355 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/src/geometry/layers.rs +594 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/src/geometry/projection.rs +164 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/src/geometry.rs +400 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/src/hierarchy.rs +345 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/src/lib.rs +125 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/src/materials/inputs.rs +338 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/src/materials/legacy.rs +475 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/src/materials/profiles.rs +545 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/src/materials/shader.rs +179 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/src/materials/slots.rs +304 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/src/materials/textures/images.rs +299 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/src/materials/textures.rs +408 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/src/materials/uv_sets.rs +128 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/src/materials.rs +171 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/src/properties/user.rs +242 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/src/properties.rs +117 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/src/scene/mesh_jobs.rs +173 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/src/scene/models/inheritance/scale_tracks.rs +219 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/src/scene/models/inheritance.rs +183 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/src/scene/models.rs +260 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/src/scene.rs +399 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/src/space.rs +85 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/src/tree.rs +349 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/tests/animation.rs +680 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/tests/animation_layers.rs +271 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/tests/ascii.rs +265 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/tests/assembly.rs +250 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/tests/binary/ordered.rs +422 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/tests/binary.rs +488 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/tests/curve_profiles.rs +426 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/tests/custom_properties.rs +316 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/tests/deform.rs +727 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/tests/deform_animation.rs +229 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/tests/fixtures/animation_linear.fbx +85 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/tests/fixtures/deform_inbetween_cubic.fbx +49 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/tests/fixtures/layer-controls.fbx +78 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/tests/fixtures/layer-weight-accumulation.fbx +85 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/tests/geometry.rs +690 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/tests/hierarchy.rs +742 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/tests/image_load_policy.rs +316 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/tests/materials/profiles.rs +618 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/tests/materials.rs +854 -0
- baozi3d-0.1.0/crates/baozi-format-fbx/tests/scale_inheritance.rs +143 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/Cargo.toml +36 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/LICENSE-APACHE +201 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/LICENSE-MIT +21 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/README.md +36 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/src/accessor/decode.rs +451 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/src/accessor.rs +473 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/src/appearance.rs +100 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/src/budget.rs +15 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/src/discovery.rs +104 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/src/draco.rs +442 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/src/extensions.rs +532 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/src/glb.rs +122 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/src/integer.rs +76 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/src/lib.rs +427 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/src/materials/material_extensions.rs +430 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/src/materials/texture_extensions.rs +583 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/src/materials.rs +600 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/src/mesh/attributes.rs +394 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/src/mesh/draco.rs +119 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/src/mesh/parallel.rs +370 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/src/mesh.rs +658 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/src/meshopt/filters.rs +101 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/src/meshopt/tests.rs +457 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/src/meshopt.rs +461 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/src/options.rs +92 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/src/provenance.rs +68 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/src/resources/meshopt.rs +228 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/src/resources.rs +538 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/src/scene/animation/pointer.rs +271 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/src/scene/animation.rs +609 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/src/scene/attachment.rs +216 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/src/scene/instancing.rs +173 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/src/scene.rs +602 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/src/schema/alternate_metadata.rs +211 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/src/schema/inspection.rs +844 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/src/schema.rs +246 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/src/variants.rs +46 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/src/vrm/avatar/expressions.rs +304 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/src/vrm/avatar.rs +423 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/src/vrm/constraints.rs +227 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/src/vrm/spring_bone.rs +368 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/src/vrm/v0/expressions.rs +201 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/src/vrm/v0/spring.rs +285 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/src/vrm/v0.rs +505 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/src/vrm/v0_materials.rs +502 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/src/vrm/value/typed.rs +505 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/src/vrm/value.rs +496 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/src/vrm.rs +248 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/src/xmp.rs +269 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/tests/animation_pointer/rules.rs +199 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/tests/animation_pointer.rs +719 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/tests/decoded_limits.rs +531 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/tests/draco.rs +597 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/tests/extensions.rs +556 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/tests/gltf/compatibility.rs +412 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/tests/gltf/discovery.rs +228 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/tests/gltf/materials.rs +857 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/tests/gltf/mesh.rs +499 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/tests/gltf/scene.rs +631 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/tests/gltf.rs +226 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/tests/instancing.rs +420 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/tests/integer_encoding.rs +442 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/tests/meshopt.rs +343 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/tests/parallel.rs +493 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/tests/variants.rs +75 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/tests/vrm/v0.rs +614 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/tests/vrm/validation.rs +400 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/tests/vrm.rs +660 -0
- baozi3d-0.1.0/crates/baozi-format-gltf/tests/xmp.rs +255 -0
- baozi3d-0.1.0/crates/baozi-format-mesh/Cargo.toml +27 -0
- baozi3d-0.1.0/crates/baozi-format-mesh/LICENSE-APACHE +201 -0
- baozi3d-0.1.0/crates/baozi-format-mesh/LICENSE-MIT +21 -0
- baozi3d-0.1.0/crates/baozi-format-mesh/README.md +30 -0
- baozi3d-0.1.0/crates/baozi-format-mesh/src/geometry_budget.rs +7 -0
- baozi3d-0.1.0/crates/baozi-format-mesh/src/lib.rs +39 -0
- baozi3d-0.1.0/crates/baozi-format-mesh/src/obj/batch.rs +376 -0
- baozi3d-0.1.0/crates/baozi-format-mesh/src/obj/discovery.rs +61 -0
- baozi3d-0.1.0/crates/baozi-format-mesh/src/obj/mod.rs +243 -0
- baozi3d-0.1.0/crates/baozi-format-mesh/src/obj/mtl/maps.rs +414 -0
- baozi3d-0.1.0/crates/baozi-format-mesh/src/obj/mtl/mod.rs +394 -0
- baozi3d-0.1.0/crates/baozi-format-mesh/src/obj/mtl/parse.rs +342 -0
- baozi3d-0.1.0/crates/baozi-format-mesh/src/obj/parser.rs +527 -0
- baozi3d-0.1.0/crates/baozi-format-mesh/src/obj/scan.rs +126 -0
- baozi3d-0.1.0/crates/baozi-format-mesh/src/ply/body/record.rs +377 -0
- baozi3d-0.1.0/crates/baozi-format-mesh/src/ply/body.rs +489 -0
- baozi3d-0.1.0/crates/baozi-format-mesh/src/ply/header.rs +332 -0
- baozi3d-0.1.0/crates/baozi-format-mesh/src/ply/lexer.rs +219 -0
- baozi3d-0.1.0/crates/baozi-format-mesh/src/ply/mod.rs +136 -0
- baozi3d-0.1.0/crates/baozi-format-mesh/src/ply/scene.rs +183 -0
- baozi3d-0.1.0/crates/baozi-format-mesh/src/stl.rs +651 -0
- baozi3d-0.1.0/crates/baozi-format-mesh/tests/standalone.rs +209 -0
- baozi3d-0.1.0/crates/baozi-format-robotics/Cargo.toml +26 -0
- baozi3d-0.1.0/crates/baozi-format-robotics/LICENSE-APACHE +201 -0
- baozi3d-0.1.0/crates/baozi-format-robotics/LICENSE-MIT +21 -0
- baozi3d-0.1.0/crates/baozi-format-robotics/README.md +17 -0
- baozi3d-0.1.0/crates/baozi-format-robotics/src/build.rs +308 -0
- baozi3d-0.1.0/crates/baozi-format-robotics/src/lib.rs +31 -0
- baozi3d-0.1.0/crates/baozi-format-robotics/src/meshes/streams.rs +237 -0
- baozi3d-0.1.0/crates/baozi-format-robotics/src/meshes.rs +539 -0
- baozi3d-0.1.0/crates/baozi-format-robotics/src/mjcf/assets.rs +382 -0
- baozi3d-0.1.0/crates/baozi-format-robotics/src/mjcf/defaults.rs +295 -0
- baozi3d-0.1.0/crates/baozi-format-robotics/src/mjcf/document.rs +254 -0
- baozi3d-0.1.0/crates/baozi-format-robotics/src/mjcf/visuals.rs +604 -0
- baozi3d-0.1.0/crates/baozi-format-robotics/src/mjcf.rs +167 -0
- baozi3d-0.1.0/crates/baozi-format-robotics/src/numbers.rs +27 -0
- baozi3d-0.1.0/crates/baozi-format-robotics/src/orientation.rs +292 -0
- baozi3d-0.1.0/crates/baozi-format-robotics/src/primitives/tests.rs +351 -0
- baozi3d-0.1.0/crates/baozi-format-robotics/src/primitives.rs +416 -0
- baozi3d-0.1.0/crates/baozi-format-robotics/src/urdf/geometry.rs +355 -0
- baozi3d-0.1.0/crates/baozi-format-robotics/src/urdf/kinematics.rs +315 -0
- baozi3d-0.1.0/crates/baozi-format-robotics/src/urdf.rs +197 -0
- baozi3d-0.1.0/crates/baozi-format-robotics/src/xml.rs +179 -0
- baozi3d-0.1.0/crates/baozi-format-robotics/tests/mjcf.rs +885 -0
- baozi3d-0.1.0/crates/baozi-format-robotics/tests/nested_mesh.rs +247 -0
- baozi3d-0.1.0/crates/baozi-format-robotics/tests/nested_visibility.rs +104 -0
- baozi3d-0.1.0/crates/baozi-format-robotics/tests/urdf.rs +606 -0
- baozi3d-0.1.0/crates/baozi-format-usd/Cargo.toml +35 -0
- baozi3d-0.1.0/crates/baozi-format-usd/LICENSE-APACHE +201 -0
- baozi3d-0.1.0/crates/baozi-format-usd/LICENSE-MIT +21 -0
- baozi3d-0.1.0/crates/baozi-format-usd/README.md +15 -0
- baozi3d-0.1.0/crates/baozi-format-usd/SHA256SUMS +44 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/compose/arcs.rs +425 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/compose/copy.rs +281 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/compose/layers.rs +323 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/compose/list.rs +250 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/compose/materialize.rs +206 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/compose/mod.rs +190 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/compose/stack.rs +485 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/compose/variants.rs +109 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/custom_properties.rs +276 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/discovery.rs +190 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/geom/display.rs +16 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/geom/tessellate.rs +398 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/geom.rs +251 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/layer/array.rs +142 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/layer/paths.rs +38 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/layer.rs +234 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/lib.rs +299 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/material/image.rs +314 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/material/materialx/graph.rs +541 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/material/materialx/sampling.rs +378 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/material/materialx.rs +436 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/material/network.rs +528 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/material/tests.rs +469 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/material/texture.rs +507 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/material.rs +684 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/mesh/primvars.rs +581 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/mesh/projection.rs +381 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/mesh/subsets.rs +335 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/mesh/tests.rs +688 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/mesh/topology.rs +166 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/mesh.rs +350 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/skel/animation.rs +559 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/skel/blendshapes.rs +434 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/skel/influences.rs +416 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/skel.rs +664 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/stage/display_primvars.rs +362 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/stage/instancer/placements.rs +199 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/stage/instancer/prototype.rs +627 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/stage/instancer.rs +163 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/stage/material_bindings.rs +56 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/stage/timeline.rs +119 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/stage.rs +668 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/usda/lexer.rs +586 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/usda/paths.rs +117 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/usda/tests.rs +716 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/usda/value/packed.rs +194 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/usda/value.rs +463 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/usda/variants.rs +30 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/usda.rs +466 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/usdc/compression.rs +279 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/usdc/fixtures/arcs.usda +66 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/usdc/fixtures/arcs.usdc +0 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/usdc/fixtures/asset-array.usda +9 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/usdc/fixtures/asset-array.usdc +0 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/usdc/fixtures/preview.usda +63 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/usdc/fixtures/preview.usdc +0 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/usdc/fixtures/runtime-slice.usda +25 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/usdc/fixtures/runtime-slice.usdc +0 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/usdc/fixtures/variants.usda +52 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/usdc/fixtures/variants.usdc +0 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/usdc/fixtures/versions/crate-08.usda +11 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/usdc/fixtures/versions/crate-08.usdc +0 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/usdc/fixtures/versions/crate-09.usda +17 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/usdc/fixtures/versions/crate-09.usdc +0 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/usdc/fixtures/versions/crate-10.usda +11 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/usdc/fixtures/versions/crate-10.usdc +0 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/usdc/fixtures/versions/crate-11.usda +11 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/usdc/fixtures/versions/crate-11.usdc +0 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/usdc/fixtures/versions/plugInfo.json +11 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/usdc/structure/layer.rs +583 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/usdc/structure.rs +717 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/usdc/tests.rs +1126 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/usdc/values/arrays.rs +239 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/usdc/values/fields.rs +304 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/usdc/values.rs +652 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/usdc/versions.rs +243 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/usdc.rs +212 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/visuals.rs +171 -0
- baozi3d-0.1.0/crates/baozi-format-usd/src/xform.rs +482 -0
- baozi3d-0.1.0/crates/baozi-format-usd/tests/blendshapes.rs +492 -0
- baozi3d-0.1.0/crates/baozi-format-usd/tests/composition.rs +605 -0
- baozi3d-0.1.0/crates/baozi-format-usd/tests/custom_properties.rs +189 -0
- baozi3d-0.1.0/crates/baozi-format-usd/tests/fixtures/README.md +44 -0
- baozi3d-0.1.0/crates/baozi-format-usd/tests/fixtures/animated_skin.usda +49 -0
- baozi3d-0.1.0/crates/baozi-format-usd/tests/fixtures/animated_skin.usdc +0 -0
- baozi3d-0.1.0/crates/baozi-format-usd/tests/fixtures/animated_skin.usdz +0 -0
- baozi3d-0.1.0/crates/baozi-format-usd/tests/fixtures/custom_properties.usda +48 -0
- baozi3d-0.1.0/crates/baozi-format-usd/tests/fixtures/custom_properties.usdc +0 -0
- baozi3d-0.1.0/crates/baozi-format-usd/tests/fixtures/inherited_material.usda +79 -0
- baozi3d-0.1.0/crates/baozi-format-usd/tests/fixtures/inherited_material.usdc +0 -0
- baozi3d-0.1.0/crates/baozi-format-usd/tests/fixtures/inherited_visibility.usda +39 -0
- baozi3d-0.1.0/crates/baozi-format-usd/tests/fixtures/inherited_visibility.usdc +0 -0
- baozi3d-0.1.0/crates/baozi-format-usd/tests/fixtures/materialx_standard.usda +116 -0
- baozi3d-0.1.0/crates/baozi-format-usd/tests/fixtures/materialx_standard.usdc +0 -0
- baozi3d-0.1.0/crates/baozi-format-usd/tests/fixtures/moving_mesh.usda +32 -0
- baozi3d-0.1.0/crates/baozi-format-usd/tests/fixtures/moving_mesh.usdc +0 -0
- baozi3d-0.1.0/crates/baozi-format-usd/tests/fixtures/moving_mesh.usdz +0 -0
- baozi3d-0.1.0/crates/baozi-format-usd/tests/fixtures/point_instancer.usda +22 -0
- baozi3d-0.1.0/crates/baozi-format-usd/tests/fixtures/point_instancer.usdc +0 -0
- baozi3d-0.1.0/crates/baozi-format-usd/tests/fixtures/point_instancer.usdz +0 -0
- baozi3d-0.1.0/crates/baozi-format-usd/tests/fixtures/point_instancer_masks.usda +35 -0
- baozi3d-0.1.0/crates/baozi-format-usd/tests/fixtures/point_instancer_masks.usdc +0 -0
- baozi3d-0.1.0/crates/baozi-format-usd/tests/fixtures/relationship_list_ops.usda +10 -0
- baozi3d-0.1.0/crates/baozi-format-usd/tests/fixtures/relationship_list_ops.usdc +0 -0
- baozi3d-0.1.0/crates/baozi-format-usd/tests/fixtures/skinned_morph.usda +44 -0
- baozi3d-0.1.0/crates/baozi-format-usd/tests/fixtures/visual_defaults.usda +94 -0
- baozi3d-0.1.0/crates/baozi-format-usd/tests/fixtures/visual_defaults.usdc +0 -0
- baozi3d-0.1.0/crates/baozi-format-usd/tests/image_load_policy.rs +458 -0
- baozi3d-0.1.0/crates/baozi-format-usd/tests/implicit_geometry.rs +677 -0
- baozi3d-0.1.0/crates/baozi-format-usd/tests/material_inheritance.rs +86 -0
- baozi3d-0.1.0/crates/baozi-format-usd/tests/materialx.rs +735 -0
- baozi3d-0.1.0/crates/baozi-format-usd/tests/packed_preview_surface_materials.rs +218 -0
- baozi3d-0.1.0/crates/baozi-format-usd/tests/parallel.rs +242 -0
- baozi3d-0.1.0/crates/baozi-format-usd/tests/point_instancer.rs +821 -0
- baozi3d-0.1.0/crates/baozi-format-usd/tests/reference_time.rs +34 -0
- baozi3d-0.1.0/crates/baozi-format-usd/tests/skel.rs +447 -0
- baozi3d-0.1.0/crates/baozi-format-usd/tests/subset_points.rs +210 -0
- baozi3d-0.1.0/crates/baozi-format-usd/tests/usd.rs +273 -0
- baozi3d-0.1.0/crates/baozi-format-usd/tests/usdz.rs +512 -0
- baozi3d-0.1.0/crates/baozi-format-usd/tests/visual_projection.rs +461 -0
- baozi3d-0.1.0/crates/baozi-format-usd/tests/xform.rs +306 -0
- baozi3d-0.1.0/crates/baozi-image-codec/Cargo.toml +35 -0
- baozi3d-0.1.0/crates/baozi-image-codec/LICENSE-APACHE +201 -0
- baozi3d-0.1.0/crates/baozi-image-codec/LICENSE-MIT +21 -0
- baozi3d-0.1.0/crates/baozi-image-codec/README.md +142 -0
- baozi3d-0.1.0/crates/baozi-image-codec/src/dds.rs +258 -0
- baozi3d-0.1.0/crates/baozi-image-codec/src/decode.rs +403 -0
- baozi3d-0.1.0/crates/baozi-image-codec/src/ktx2/container.rs +171 -0
- baozi3d-0.1.0/crates/baozi-image-codec/src/ktx2/mod.rs +220 -0
- baozi3d-0.1.0/crates/baozi-image-codec/src/ktx2/tests.rs +473 -0
- baozi3d-0.1.0/crates/baozi-image-codec/src/ktx2/uastc/tests.rs +313 -0
- baozi3d-0.1.0/crates/baozi-image-codec/src/ktx2/uastc.rs +563 -0
- baozi3d-0.1.0/crates/baozi-image-codec/src/ktx2/zstd.rs +121 -0
- baozi3d-0.1.0/crates/baozi-image-codec/src/lib.rs +520 -0
- baozi3d-0.1.0/crates/baozi-image-codec/src/output.rs +230 -0
- baozi3d-0.1.0/crates/baozi-image-codec/src/pixels.rs +182 -0
- baozi3d-0.1.0/crates/baozi-image-codec/src/raster/jpeg.rs +424 -0
- baozi3d-0.1.0/crates/baozi-image-codec/src/raster/webp.rs +196 -0
- baozi3d-0.1.0/crates/baozi-image-codec/src/raster.rs +658 -0
- baozi3d-0.1.0/crates/baozi-image-codec/src/resize.rs +250 -0
- baozi3d-0.1.0/crates/baozi-image-codec/tests/texture_targets.rs +447 -0
- baozi3d-0.1.0/crates/baozi-image-codec/tests/transcode/dds.rs +202 -0
- baozi3d-0.1.0/crates/baozi-image-codec/tests/transcode/decode.rs +171 -0
- baozi3d-0.1.0/crates/baozi-image-codec/tests/transcode/jpeg.rs +493 -0
- baozi3d-0.1.0/crates/baozi-image-codec/tests/transcode/parallel.rs +364 -0
- baozi3d-0.1.0/crates/baozi-image-codec/tests/transcode/webp.rs +89 -0
- baozi3d-0.1.0/crates/baozi-image-codec/tests/transcode.rs +749 -0
- baozi3d-0.1.0/crates/baozi-import/Cargo.toml +43 -0
- baozi3d-0.1.0/crates/baozi-import/LICENSE-APACHE +201 -0
- baozi3d-0.1.0/crates/baozi-import/LICENSE-MIT +21 -0
- baozi3d-0.1.0/crates/baozi-import/README.md +49 -0
- baozi3d-0.1.0/crates/baozi-import/src/archive.rs +1242 -0
- baozi3d-0.1.0/crates/baozi-import/src/budget.rs +363 -0
- baozi3d-0.1.0/crates/baozi-import/src/context/nested.rs +174 -0
- baozi3d-0.1.0/crates/baozi-import/src/context/stream.rs +146 -0
- baozi3d-0.1.0/crates/baozi-import/src/context.rs +706 -0
- baozi3d-0.1.0/crates/baozi-import/src/control.rs +35 -0
- baozi3d-0.1.0/crates/baozi-import/src/diagnostic.rs +220 -0
- baozi3d-0.1.0/crates/baozi-import/src/error.rs +568 -0
- baozi3d-0.1.0/crates/baozi-import/src/format.rs +197 -0
- baozi3d-0.1.0/crates/baozi-import/src/fs.rs +296 -0
- baozi3d-0.1.0/crates/baozi-import/src/io/observing.rs +203 -0
- baozi3d-0.1.0/crates/baozi-import/src/io.rs +364 -0
- baozi3d-0.1.0/crates/baozi-import/src/lib.rs +46 -0
- baozi3d-0.1.0/crates/baozi-import/src/limits.rs +238 -0
- baozi3d-0.1.0/crates/baozi-import/src/observation.rs +119 -0
- baozi3d-0.1.0/crates/baozi-import/src/options.rs +231 -0
- baozi3d-0.1.0/crates/baozi-import/src/path.rs +722 -0
- baozi3d-0.1.0/crates/baozi-import/src/registry.rs +795 -0
- baozi3d-0.1.0/crates/baozi-import/src/report.rs +105 -0
- baozi3d-0.1.0/crates/baozi-import/src/util/alloc.rs +50 -0
- baozi3d-0.1.0/crates/baozi-import/src/util/binary/read.rs +223 -0
- baozi3d-0.1.0/crates/baozi-import/src/util/binary/transaction.rs +220 -0
- baozi3d-0.1.0/crates/baozi-import/src/util/binary.rs +542 -0
- baozi3d-0.1.0/crates/baozi-import/src/util/mod.rs +11 -0
- baozi3d-0.1.0/crates/baozi-import/src/util/number.rs +357 -0
- baozi3d-0.1.0/crates/baozi-import/src/util/text.rs +338 -0
- baozi3d-0.1.0/crates/baozi-import/src/util/uri.rs +382 -0
- baozi3d-0.1.0/crates/baozi-import/src/util/xml.rs +715 -0
- baozi3d-0.1.0/crates/baozi-import/tests/binary_derive.rs +488 -0
- baozi3d-0.1.0/crates/baozi-import/tests/binary_derive_ui.md +130 -0
- baozi3d-0.1.0/crates/baozi-import/tests/custom_properties.rs +57 -0
- baozi3d-0.1.0/crates/baozi-import/tests/import.rs +1002 -0
- baozi3d-0.1.0/crates/baozi-import/tests/list_dir.rs +559 -0
- baozi3d-0.1.0/crates/baozi-import/tests/nested.rs +774 -0
- baozi3d-0.1.0/crates/baozi-import/tests/numbers.rs +220 -0
- baozi3d-0.1.0/crates/baozi-import/tests/observations.rs +288 -0
- baozi3d-0.1.0/crates/baozi-import/tests/resources.rs +459 -0
- baozi3d-0.1.0/crates/baozi-postprocess/Cargo.toml +35 -0
- baozi3d-0.1.0/crates/baozi-postprocess/LICENSE-APACHE +201 -0
- baozi3d-0.1.0/crates/baozi-postprocess/LICENSE-MIT +21 -0
- baozi3d-0.1.0/crates/baozi-postprocess/README.md +71 -0
- baozi3d-0.1.0/crates/baozi-postprocess/src/context.rs +366 -0
- baozi3d-0.1.0/crates/baozi-postprocess/src/error.rs +64 -0
- baozi3d-0.1.0/crates/baozi-postprocess/src/lib.rs +25 -0
- baozi3d-0.1.0/crates/baozi-postprocess/src/passes/attribute_remap.rs +297 -0
- baozi3d-0.1.0/crates/baozi-postprocess/src/passes/bake_uv_transforms.rs +731 -0
- baozi3d-0.1.0/crates/baozi-postprocess/src/passes/bone_weights.rs +124 -0
- baozi3d-0.1.0/crates/baozi-postprocess/src/passes/bounds.rs +52 -0
- baozi3d-0.1.0/crates/baozi-postprocess/src/passes/cache_opt.rs +276 -0
- baozi3d-0.1.0/crates/baozi-postprocess/src/passes/convert_materials.rs +155 -0
- baozi3d-0.1.0/crates/baozi-postprocess/src/passes/fingerprint.rs +282 -0
- baozi3d-0.1.0/crates/baozi-postprocess/src/passes/fix_normals.rs +560 -0
- baozi3d-0.1.0/crates/baozi-postprocess/src/passes/float_scale.rs +70 -0
- baozi3d-0.1.0/crates/baozi-postprocess/src/passes/join_vertices.rs +651 -0
- baozi3d-0.1.0/crates/baozi-postprocess/src/passes/lod.rs +385 -0
- baozi3d-0.1.0/crates/baozi-postprocess/src/passes/mod.rs +66 -0
- baozi3d-0.1.0/crates/baozi-postprocess/src/passes/narrow_positions.rs +69 -0
- baozi3d-0.1.0/crates/baozi-postprocess/src/passes/normalize.rs +482 -0
- baozi3d-0.1.0/crates/baozi-postprocess/src/passes/normals.rs +620 -0
- baozi3d-0.1.0/crates/baozi-postprocess/src/passes/normals_api.rs +68 -0
- baozi3d-0.1.0/crates/baozi-postprocess/src/passes/normals_buckets.rs +353 -0
- baozi3d-0.1.0/crates/baozi-postprocess/src/passes/optimize_graph.rs +454 -0
- baozi3d-0.1.0/crates/baozi-postprocess/src/passes/optimize_meshes.rs +626 -0
- baozi3d-0.1.0/crates/baozi-postprocess/src/passes/ordered.rs +195 -0
- baozi3d-0.1.0/crates/baozi-postprocess/src/passes/overdraw.rs +356 -0
- baozi3d-0.1.0/crates/baozi-postprocess/src/passes/position_ids.rs +136 -0
- baozi3d-0.1.0/crates/baozi-postprocess/src/passes/pretransform.rs +527 -0
- baozi3d-0.1.0/crates/baozi-postprocess/src/passes/redundant_materials.rs +531 -0
- baozi3d-0.1.0/crates/baozi-postprocess/src/passes/sanitize.rs +415 -0
- baozi3d-0.1.0/crates/baozi-postprocess/src/passes/scene_references.rs +241 -0
- baozi3d-0.1.0/crates/baozi-postprocess/src/passes/simplify/features.rs +359 -0
- baozi3d-0.1.0/crates/baozi-postprocess/src/passes/simplify/mesh/connectivity.rs +210 -0
- baozi3d-0.1.0/crates/baozi-postprocess/src/passes/simplify/mesh/queue.rs +195 -0
- baozi3d-0.1.0/crates/baozi-postprocess/src/passes/simplify/mesh.rs +358 -0
- baozi3d-0.1.0/crates/baozi-postprocess/src/passes/simplify/qem.rs +161 -0
- baozi3d-0.1.0/crates/baozi-postprocess/src/passes/simplify.rs +380 -0
- baozi3d-0.1.0/crates/baozi-postprocess/src/passes/space/animation.rs +80 -0
- baozi3d-0.1.0/crates/baozi-postprocess/src/passes/space/geometry.rs +197 -0
- baozi3d-0.1.0/crates/baozi-postprocess/src/passes/space/node.rs +126 -0
- baozi3d-0.1.0/crates/baozi-postprocess/src/passes/space/texture.rs +532 -0
- baozi3d-0.1.0/crates/baozi-postprocess/src/passes/space.rs +511 -0
- baozi3d-0.1.0/crates/baozi-postprocess/src/passes/split_bones.rs +698 -0
- baozi3d-0.1.0/crates/baozi-postprocess/src/passes/split_meshes.rs +248 -0
- baozi3d-0.1.0/crates/baozi-postprocess/src/passes/tangents.rs +401 -0
- baozi3d-0.1.0/crates/baozi-postprocess/src/passes/topology.rs +237 -0
- baozi3d-0.1.0/crates/baozi-postprocess/src/passes/transcode_images.rs +433 -0
- baozi3d-0.1.0/crates/baozi-postprocess/src/passes/triangulate.rs +268 -0
- baozi3d-0.1.0/crates/baozi-postprocess/src/passes/vertex_fetch.rs +116 -0
- baozi3d-0.1.0/crates/baozi-postprocess/src/passes/vertex_map.rs +440 -0
- baozi3d-0.1.0/crates/baozi-postprocess/src/pipeline.rs +594 -0
- baozi3d-0.1.0/crates/baozi-postprocess/src/util.rs +24 -0
- baozi3d-0.1.0/crates/baozi-postprocess/tests/arena_remap.rs +422 -0
- baozi3d-0.1.0/crates/baozi-postprocess/tests/fingerprint.rs +178 -0
- baozi3d-0.1.0/crates/baozi-postprocess/tests/geometry_overdraw.rs +345 -0
- baozi3d-0.1.0/crates/baozi-postprocess/tests/geometry_simplify.rs +646 -0
- baozi3d-0.1.0/crates/baozi-postprocess/tests/geometry_vertex_fetch.rs +269 -0
- baozi3d-0.1.0/crates/baozi-postprocess/tests/gpu_pipeline.rs +357 -0
- baozi3d-0.1.0/crates/baozi-postprocess/tests/lod.rs +471 -0
- baozi3d-0.1.0/crates/baozi-postprocess/tests/normal_frames.rs +212 -0
- baozi3d-0.1.0/crates/baozi-postprocess/tests/normalize.rs +632 -0
- baozi3d-0.1.0/crates/baozi-postprocess/tests/parallel.rs +265 -0
- baozi3d-0.1.0/crates/baozi-postprocess/tests/postprocess/appearance_optimization.rs +792 -0
- baozi3d-0.1.0/crates/baozi-postprocess/tests/postprocess/cleanup.rs +708 -0
- baozi3d-0.1.0/crates/baozi-postprocess/tests/postprocess/join_and_cache.rs +358 -0
- baozi3d-0.1.0/crates/baozi-postprocess/tests/postprocess/optimize_graph.rs +691 -0
- baozi3d-0.1.0/crates/baozi-postprocess/tests/postprocess/optimize_meshes.rs +734 -0
- baozi3d-0.1.0/crates/baozi-postprocess/tests/postprocess/pipeline.rs +274 -0
- baozi3d-0.1.0/crates/baozi-postprocess/tests/postprocess/remap.rs +423 -0
- baozi3d-0.1.0/crates/baozi-postprocess/tests/postprocess/split_bones.rs +879 -0
- baozi3d-0.1.0/crates/baozi-postprocess/tests/postprocess/uv_and_tangents.rs +494 -0
- baozi3d-0.1.0/crates/baozi-postprocess/tests/postprocess.rs +1386 -0
- baozi3d-0.1.0/crates/baozi-postprocess/tests/smoothing_groups.rs +304 -0
- baozi3d-0.1.0/crates/baozi-postprocess/tests/transcode_images.rs +472 -0
- baozi3d-0.1.0/pyproject.toml +51 -0
- baozi3d-0.1.0/python/baozi3d/__init__.py +62 -0
- baozi3d-0.1.0/python/baozi3d/_baozi3d.pyi +340 -0
- baozi3d-0.1.0/python/baozi3d/_typing.py +33 -0
- baozi3d-0.1.0/python/baozi3d/py.typed +0 -0
baozi3d-0.1.0/Cargo.toml
ADDED
|
@@ -0,0 +1,94 @@
|
|
|
1
|
+
[workspace]
|
|
2
|
+
resolver = "3"
|
|
3
|
+
members = [
|
|
4
|
+
"crates/baozi-core",
|
|
5
|
+
"crates/baozi-eval",
|
|
6
|
+
"crates/baozi-eval-derive",
|
|
7
|
+
"crates/baozi-image-codec",
|
|
8
|
+
"crates/baozi-import",
|
|
9
|
+
"crates/baozi-binary-derive",
|
|
10
|
+
"crates/baozi-postprocess",
|
|
11
|
+
"crates/baozi-format-mesh",
|
|
12
|
+
"crates/baozi-format-gltf",
|
|
13
|
+
"crates/baozi-draco",
|
|
14
|
+
"crates/baozi-format-3mf",
|
|
15
|
+
"crates/baozi-format-fbx",
|
|
16
|
+
"crates/baozi-format-collada",
|
|
17
|
+
"crates/baozi-format-usd",
|
|
18
|
+
"crates/baozi-format-bvh",
|
|
19
|
+
"crates/baozi-format-robotics",
|
|
20
|
+
"crates/baozi-export",
|
|
21
|
+
"crates/baozi-export-gltf",
|
|
22
|
+
"crates/baozi-export-usd",
|
|
23
|
+
"crates/baozi-export-3mf",
|
|
24
|
+
"crates/baozi",
|
|
25
|
+
"crates/baozi-cli",
|
|
26
|
+
"tools/ci",
|
|
27
|
+
"tools/consumers/gltf-conformance",
|
|
28
|
+
"tools/consumers/fbx-conformance",
|
|
29
|
+
"tools/consumers/collada-conformance",
|
|
30
|
+
"tools/consumers/assets",
|
|
31
|
+
"tools/consumers/render-wgpu",
|
|
32
|
+
]
|
|
33
|
+
exclude = [
|
|
34
|
+
"bindings/baozi-python",
|
|
35
|
+
"bindings/baozi-wasm",
|
|
36
|
+
"fuzz",
|
|
37
|
+
"integrations/baozi-bevy",
|
|
38
|
+
"web/demo/wasm",
|
|
39
|
+
]
|
|
40
|
+
|
|
41
|
+
[workspace.package]
|
|
42
|
+
version = "0.1.0"
|
|
43
|
+
edition = "2024"
|
|
44
|
+
rust-version = "1.95"
|
|
45
|
+
license = "MIT OR Apache-2.0"
|
|
46
|
+
homepage = "https://frankorz.com/baozi/"
|
|
47
|
+
repository = "https://github.com/Latias94/baozi"
|
|
48
|
+
authors = ["Mingzhen Zhuang <superfrankie621@gmail.com>"]
|
|
49
|
+
|
|
50
|
+
[workspace.dependencies]
|
|
51
|
+
baozi = { path = "crates/baozi", version = "0.1.0", default-features = false }
|
|
52
|
+
baozi-postprocess = { path = "crates/baozi-postprocess", version = "0.1.0", default-features = false }
|
|
53
|
+
baozi-format-mesh = { path = "crates/baozi-format-mesh", version = "0.1.0", default-features = false }
|
|
54
|
+
baozi-format-gltf = { path = "crates/baozi-format-gltf", version = "0.1.0" }
|
|
55
|
+
baozi-draco = { path = "crates/baozi-draco", version = "0.1.0" }
|
|
56
|
+
baozi-format-3mf = { path = "crates/baozi-format-3mf", version = "0.1.0" }
|
|
57
|
+
baozi-format-fbx = { path = "crates/baozi-format-fbx", version = "0.1.0" }
|
|
58
|
+
baozi-format-collada = { path = "crates/baozi-format-collada", version = "0.1.0" }
|
|
59
|
+
baozi-format-usd = { path = "crates/baozi-format-usd", version = "0.1.0" }
|
|
60
|
+
baozi-format-bvh = { path = "crates/baozi-format-bvh", version = "0.1.0" }
|
|
61
|
+
baozi-format-robotics = { path = "crates/baozi-format-robotics", version = "0.1.0", default-features = false }
|
|
62
|
+
baozi-export = { path = "crates/baozi-export", version = "0.1.0", default-features = false }
|
|
63
|
+
baozi-export-gltf = { path = "crates/baozi-export-gltf", version = "0.1.0", default-features = false }
|
|
64
|
+
baozi-export-usd = { path = "crates/baozi-export-usd", version = "0.1.0" }
|
|
65
|
+
baozi-export-3mf = { path = "crates/baozi-export-3mf", version = "0.1.0" }
|
|
66
|
+
criterion = { version = "0.8", default-features = false }
|
|
67
|
+
baozi-core = { path = "crates/baozi-core", version = "0.1.0" }
|
|
68
|
+
baozi-eval = { path = "crates/baozi-eval", version = "0.1.0", default-features = false }
|
|
69
|
+
baozi-eval-derive = { path = "crates/baozi-eval-derive", version = "0.1.0" }
|
|
70
|
+
baozi-binary-derive = { path = "crates/baozi-binary-derive", version = "0.1.0" }
|
|
71
|
+
baozi-image-codec = { path = "crates/baozi-image-codec", version = "0.1.0" }
|
|
72
|
+
baozi-import = { path = "crates/baozi-import", version = "0.1.0", default-features = false }
|
|
73
|
+
thiserror = "2"
|
|
74
|
+
bytemuck = { version = "1", features = ["derive"] }
|
|
75
|
+
serde = { version = "1", features = ["derive"] }
|
|
76
|
+
serde_json = { version = "1", features = ["raw_value"] }
|
|
77
|
+
mint = "0.5"
|
|
78
|
+
memchr = "2"
|
|
79
|
+
base64 = "0.23"
|
|
80
|
+
fluent-uri = "0.4.1"
|
|
81
|
+
encoding_rs = "0.8"
|
|
82
|
+
flate2 = { version = "1.1", default-features = false, features = ["rust_backend"] }
|
|
83
|
+
rawzip = "0.5.3"
|
|
84
|
+
rayon = "1.11"
|
|
85
|
+
quick-xml = "0.42"
|
|
86
|
+
tracing = "0.1"
|
|
87
|
+
bitflags = "2"
|
|
88
|
+
earcut = "0.4"
|
|
89
|
+
mikktspace = { package = "bevy_mikktspace", version = "1" }
|
|
90
|
+
glam = "0.34"
|
|
91
|
+
|
|
92
|
+
[profile.release]
|
|
93
|
+
lto = "thin"
|
|
94
|
+
codegen-units = 1
|
|
@@ -0,0 +1,201 @@
|
|
|
1
|
+
Apache License
|
|
2
|
+
Version 2.0, January 2004
|
|
3
|
+
http://www.apache.org/licenses/
|
|
4
|
+
|
|
5
|
+
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
|
|
6
|
+
|
|
7
|
+
1. Definitions.
|
|
8
|
+
|
|
9
|
+
"License" shall mean the terms and conditions for use, reproduction,
|
|
10
|
+
and distribution as defined by Sections 1 through 9 of this document.
|
|
11
|
+
|
|
12
|
+
"Licensor" shall mean the copyright owner or entity authorized by
|
|
13
|
+
the copyright owner that is granting the License.
|
|
14
|
+
|
|
15
|
+
"Legal Entity" shall mean the union of the acting entity and all
|
|
16
|
+
other entities that control, are controlled by, or are under common
|
|
17
|
+
control with that entity. For the purposes of this definition,
|
|
18
|
+
"control" means (i) the power, direct or indirect, to cause the
|
|
19
|
+
direction or management of such entity, whether by contract or
|
|
20
|
+
otherwise, or (ii) ownership of fifty percent (50%) or more of the
|
|
21
|
+
outstanding shares, or (iii) beneficial ownership of such entity.
|
|
22
|
+
|
|
23
|
+
"You" (or "Your") shall mean an individual or Legal Entity
|
|
24
|
+
exercising permissions granted by this License.
|
|
25
|
+
|
|
26
|
+
"Source" form shall mean the preferred form for making modifications,
|
|
27
|
+
including but not limited to software source code, documentation
|
|
28
|
+
source, and configuration files.
|
|
29
|
+
|
|
30
|
+
"Object" form shall mean any form resulting from mechanical
|
|
31
|
+
transformation or translation of a Source form, including but
|
|
32
|
+
not limited to compiled object code, generated documentation,
|
|
33
|
+
and conversions to other media types.
|
|
34
|
+
|
|
35
|
+
"Work" shall mean the work of authorship, whether in Source or
|
|
36
|
+
Object form, made available under the License, as indicated by a
|
|
37
|
+
copyright notice that is included in or attached to the work
|
|
38
|
+
(an example is provided in the Appendix below).
|
|
39
|
+
|
|
40
|
+
"Derivative Works" shall mean any work, whether in Source or Object
|
|
41
|
+
form, that is based on (or derived from) the Work and for which the
|
|
42
|
+
editorial revisions, annotations, elaborations, or other modifications
|
|
43
|
+
represent, as a whole, an original work of authorship. For the purposes
|
|
44
|
+
of this License, Derivative Works shall not include works that remain
|
|
45
|
+
separable from, or merely link (or bind by name) to the interfaces of,
|
|
46
|
+
the Work and Derivative Works thereof.
|
|
47
|
+
|
|
48
|
+
"Contribution" shall mean any work of authorship, including
|
|
49
|
+
the original version of the Work and any modifications or additions
|
|
50
|
+
to that Work or Derivative Works thereof, that is intentionally
|
|
51
|
+
submitted to Licensor for inclusion in the Work by the copyright owner
|
|
52
|
+
or by an individual or Legal Entity authorized to submit on behalf of
|
|
53
|
+
the copyright owner. For the purposes of this definition, "submitted"
|
|
54
|
+
means any form of electronic, verbal, or written communication sent
|
|
55
|
+
to the Licensor or its representatives, including but not limited to
|
|
56
|
+
communication on electronic mailing lists, source code control systems,
|
|
57
|
+
and issue tracking systems that are managed by, or on behalf of, the
|
|
58
|
+
Licensor for the purpose of discussing and improving the Work, but
|
|
59
|
+
excluding communication that is conspicuously marked or otherwise
|
|
60
|
+
designated in writing by the copyright owner as "Not a Contribution."
|
|
61
|
+
|
|
62
|
+
"Contributor" shall mean Licensor and any individual or Legal Entity
|
|
63
|
+
on behalf of whom a Contribution has been received by Licensor and
|
|
64
|
+
subsequently incorporated within the Work.
|
|
65
|
+
|
|
66
|
+
2. Grant of Copyright License. Subject to the terms and conditions of
|
|
67
|
+
this License, each Contributor hereby grants to You a perpetual,
|
|
68
|
+
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
|
69
|
+
copyright license to reproduce, prepare Derivative Works of,
|
|
70
|
+
publicly display, publicly perform, sublicense, and distribute the
|
|
71
|
+
Work and such Derivative Works in Source or Object form.
|
|
72
|
+
|
|
73
|
+
3. Grant of Patent License. Subject to the terms and conditions of
|
|
74
|
+
this License, each Contributor hereby grants to You a perpetual,
|
|
75
|
+
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
|
76
|
+
(except as stated in this section) patent license to make, have made,
|
|
77
|
+
use, offer to sell, sell, import, and otherwise transfer the Work,
|
|
78
|
+
where such license applies only to those patent claims licensable
|
|
79
|
+
by such Contributor that are necessarily infringed by their
|
|
80
|
+
Contribution(s) alone or by combination of their Contribution(s)
|
|
81
|
+
with the Work to which such Contribution(s) was submitted. If You
|
|
82
|
+
institute patent litigation against any entity (including a
|
|
83
|
+
cross-claim or counterclaim in a lawsuit) alleging that the Work
|
|
84
|
+
or a Contribution incorporated within the Work constitutes direct
|
|
85
|
+
or contributory patent infringement, then any patent licenses
|
|
86
|
+
granted to You under this License for that Work shall terminate
|
|
87
|
+
as of the date such litigation is filed.
|
|
88
|
+
|
|
89
|
+
4. Redistribution. You may reproduce and distribute copies of the
|
|
90
|
+
Work or Derivative Works thereof in any medium, with or without
|
|
91
|
+
modifications, and in Source or Object form, provided that You
|
|
92
|
+
meet the following conditions:
|
|
93
|
+
|
|
94
|
+
(a) You must give any other recipients of the Work or
|
|
95
|
+
Derivative Works a copy of this License; and
|
|
96
|
+
|
|
97
|
+
(b) You must cause any modified files to carry prominent notices
|
|
98
|
+
stating that You changed the files; and
|
|
99
|
+
|
|
100
|
+
(c) You must retain, in the Source form of any Derivative Works
|
|
101
|
+
that You distribute, all copyright, patent, trademark, and
|
|
102
|
+
attribution notices from the Source form of the Work,
|
|
103
|
+
excluding those notices that do not pertain to any part of
|
|
104
|
+
the Derivative Works; and
|
|
105
|
+
|
|
106
|
+
(d) If the Work includes a "NOTICE" text file as part of its
|
|
107
|
+
distribution, then any Derivative Works that You distribute must
|
|
108
|
+
include a readable copy of the attribution notices contained
|
|
109
|
+
within such NOTICE file, excluding those notices that do not
|
|
110
|
+
pertain to any part of the Derivative Works, in at least one
|
|
111
|
+
of the following places: within a NOTICE text file distributed
|
|
112
|
+
as part of the Derivative Works; within the Source form or
|
|
113
|
+
documentation, if provided along with the Derivative Works; or,
|
|
114
|
+
within a display generated by the Derivative Works, if and
|
|
115
|
+
wherever such third-party notices normally appear. The contents
|
|
116
|
+
of the NOTICE file are for informational purposes only and
|
|
117
|
+
do not modify the License. You may add Your own attribution
|
|
118
|
+
notices within Derivative Works that You distribute, alongside
|
|
119
|
+
or as an addendum to the NOTICE text from the Work, provided
|
|
120
|
+
that such additional attribution notices cannot be construed
|
|
121
|
+
as modifying the License.
|
|
122
|
+
|
|
123
|
+
You may add Your own copyright statement to Your modifications and
|
|
124
|
+
may provide additional or different license terms and conditions
|
|
125
|
+
for use, reproduction, or distribution of Your modifications, or
|
|
126
|
+
for any such Derivative Works as a whole, provided Your use,
|
|
127
|
+
reproduction, and distribution of the Work otherwise complies with
|
|
128
|
+
the conditions stated in this License.
|
|
129
|
+
|
|
130
|
+
5. Submission of Contributions. Unless You explicitly state otherwise,
|
|
131
|
+
any Contribution intentionally submitted for inclusion in the Work
|
|
132
|
+
by You to the Licensor shall be under the terms and conditions of
|
|
133
|
+
this License, without any additional terms or conditions.
|
|
134
|
+
Notwithstanding the above, nothing herein shall supersede or modify
|
|
135
|
+
the terms of any separate license agreement you may have executed
|
|
136
|
+
with Licensor regarding such Contributions.
|
|
137
|
+
|
|
138
|
+
6. Trademarks. This License does not grant permission to use the trade
|
|
139
|
+
names, trademarks, service marks, or product names of the Licensor,
|
|
140
|
+
except as required for reasonable and customary use in describing the
|
|
141
|
+
origin of the Work and reproducing the content of the NOTICE file.
|
|
142
|
+
|
|
143
|
+
7. Disclaimer of Warranty. Unless required by applicable law or
|
|
144
|
+
agreed to in writing, Licensor provides the Work (and each
|
|
145
|
+
Contributor provides its Contributions) on an "AS IS" BASIS,
|
|
146
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
|
|
147
|
+
implied, including, without limitation, any warranties or conditions
|
|
148
|
+
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
|
|
149
|
+
PARTICULAR PURPOSE. You are solely responsible for determining the
|
|
150
|
+
appropriateness of using or redistributing the Work and assume any
|
|
151
|
+
risks associated with Your exercise of permissions under this License.
|
|
152
|
+
|
|
153
|
+
8. Limitation of Liability. In no event and under no legal theory,
|
|
154
|
+
whether in tort (including negligence), contract, or otherwise,
|
|
155
|
+
unless required by applicable law (such as deliberate and grossly
|
|
156
|
+
negligent acts) or agreed to in writing, shall any Contributor be
|
|
157
|
+
liable to You for damages, including any direct, indirect, special,
|
|
158
|
+
incidental, or consequential damages of any character arising as a
|
|
159
|
+
result of this License or out of the use or inability to use the
|
|
160
|
+
Work (including but not limited to damages for loss of goodwill,
|
|
161
|
+
work stoppage, computer failure or malfunction, or any and all
|
|
162
|
+
other commercial damages or losses), even if such Contributor
|
|
163
|
+
has been advised of the possibility of such damages.
|
|
164
|
+
|
|
165
|
+
9. Accepting Warranty or Additional Liability. While redistributing
|
|
166
|
+
the Work or Derivative Works thereof, You may choose to offer,
|
|
167
|
+
and charge a fee for, acceptance of support, warranty, indemnity,
|
|
168
|
+
or other liability obligations and/or rights consistent with this
|
|
169
|
+
License. However, in accepting such obligations, You may act only
|
|
170
|
+
on Your own behalf and on Your sole responsibility, not on behalf
|
|
171
|
+
of any other Contributor, and only if You agree to indemnify,
|
|
172
|
+
defend, and hold each Contributor harmless for any liability
|
|
173
|
+
incurred by, or claims asserted against, such Contributor by reason
|
|
174
|
+
of your accepting any such warranty or additional liability.
|
|
175
|
+
|
|
176
|
+
END OF TERMS AND CONDITIONS
|
|
177
|
+
|
|
178
|
+
APPENDIX: How to apply the Apache License to your work.
|
|
179
|
+
|
|
180
|
+
To apply the Apache License to your work, attach the following
|
|
181
|
+
boilerplate notice, with the fields enclosed by brackets "[]"
|
|
182
|
+
replaced with your own identifying information. (Don't include
|
|
183
|
+
the brackets!) The text should be enclosed in the appropriate
|
|
184
|
+
comment syntax for the file format. We also recommend that a
|
|
185
|
+
file or class name and description of purpose be included on the
|
|
186
|
+
same "printed page" as the copyright notice for easier
|
|
187
|
+
identification within third-party archives.
|
|
188
|
+
|
|
189
|
+
Copyright [yyyy] [name of copyright owner]
|
|
190
|
+
|
|
191
|
+
Licensed under the Apache License, Version 2.0 (the "License");
|
|
192
|
+
you may not use this file except in compliance with the License.
|
|
193
|
+
You may obtain a copy of the License at
|
|
194
|
+
|
|
195
|
+
http://www.apache.org/licenses/LICENSE-2.0
|
|
196
|
+
|
|
197
|
+
Unless required by applicable law or agreed to in writing, software
|
|
198
|
+
distributed under the License is distributed on an "AS IS" BASIS,
|
|
199
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
200
|
+
See the License for the specific language governing permissions and
|
|
201
|
+
limitations under the License.
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 Mingzhen Zhuang and Baozi contributors
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
baozi3d-0.1.0/PKG-INFO
ADDED
|
@@ -0,0 +1,143 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: baozi3d
|
|
3
|
+
Version: 0.1.0
|
|
4
|
+
Classifier: Development Status :: 4 - Beta
|
|
5
|
+
Classifier: Intended Audience :: Developers
|
|
6
|
+
Classifier: Operating System :: MacOS
|
|
7
|
+
Classifier: Operating System :: Microsoft :: Windows
|
|
8
|
+
Classifier: Operating System :: POSIX :: Linux
|
|
9
|
+
Classifier: Programming Language :: Python :: 3
|
|
10
|
+
Classifier: Programming Language :: Python :: 3 :: Only
|
|
11
|
+
Classifier: Programming Language :: Python :: 3.9
|
|
12
|
+
Classifier: Programming Language :: Python :: 3.10
|
|
13
|
+
Classifier: Programming Language :: Python :: 3.11
|
|
14
|
+
Classifier: Programming Language :: Python :: 3.12
|
|
15
|
+
Classifier: Programming Language :: Python :: 3.13
|
|
16
|
+
Classifier: Programming Language :: Rust
|
|
17
|
+
Classifier: Topic :: Multimedia :: Graphics :: 3D Modeling
|
|
18
|
+
Classifier: Topic :: Software Development :: Libraries
|
|
19
|
+
Classifier: Typing :: Typed
|
|
20
|
+
Requires-Dist: numpy>=1.26
|
|
21
|
+
License-File: LICENSE-APACHE
|
|
22
|
+
License-File: LICENSE-MIT
|
|
23
|
+
License-File: THIRD_PARTY_NOTICES.md
|
|
24
|
+
Summary: Import, condition, evaluate, and export 3D assets with Baozi
|
|
25
|
+
Keywords: 3d,gltf,glb,fbx,usd,mesh,geometry,asset-pipeline
|
|
26
|
+
Home-Page: https://frankorz.com/baozi/
|
|
27
|
+
Author-email: Mingzhen Zhuang <superfrankie621@gmail.com>
|
|
28
|
+
License-Expression: MIT OR Apache-2.0
|
|
29
|
+
Requires-Python: >=3.9
|
|
30
|
+
Description-Content-Type: text/markdown; charset=UTF-8; variant=GFM
|
|
31
|
+
Project-URL: Changelog, https://github.com/Latias94/baozi/blob/main/CHANGELOG.md
|
|
32
|
+
Project-URL: Documentation, https://frankorz.com/baozi/
|
|
33
|
+
Project-URL: Homepage, https://frankorz.com/baozi/
|
|
34
|
+
Project-URL: Issues, https://github.com/Latias94/baozi/issues
|
|
35
|
+
Project-URL: Repository, https://github.com/Latias94/baozi
|
|
36
|
+
|
|
37
|
+
# Baozi for Python
|
|
38
|
+
|
|
39
|
+
[](https://pypi.org/project/baozi3d/)
|
|
40
|
+
[](https://pypi.org/project/baozi3d/)
|
|
41
|
+
[](https://github.com/Latias94/baozi/actions/workflows/bindings.yml)
|
|
42
|
+
[](https://github.com/Latias94/baozi#license)
|
|
43
|
+
|
|
44
|
+
The `baozi3d` package imports, conditions, evaluates, and exports 3D scenes from Python. PyPI releases are wheel-only. The wheels target the CPython `abi3-py39` stable ABI and require CPython 3.9 or later and NumPy 1.26 or later. A local source build uses the full repository checkout for the Rust workspace dependencies and requires Rust 1.95 or later and maturin.
|
|
45
|
+
|
|
46
|
+
```sh
|
|
47
|
+
python -m pip install baozi3d
|
|
48
|
+
```
|
|
49
|
+
|
|
50
|
+
## Load and process a scene
|
|
51
|
+
|
|
52
|
+
```python
|
|
53
|
+
from pathlib import Path
|
|
54
|
+
|
|
55
|
+
import baozi3d
|
|
56
|
+
|
|
57
|
+
report = baozi3d.load_file(
|
|
58
|
+
Path("model.obj"),
|
|
59
|
+
limits=baozi3d.ImportLimits(max_file_bytes=64 * 1024 * 1024),
|
|
60
|
+
pipeline=baozi3d.PipelineOptions(triangulate=True, generate_normals=True),
|
|
61
|
+
)
|
|
62
|
+
scene = report.scene
|
|
63
|
+
scene.validate()
|
|
64
|
+
|
|
65
|
+
if report.has_warnings or report.has_errors:
|
|
66
|
+
for diagnostic in report.diagnostics:
|
|
67
|
+
print(diagnostic.severity, diagnostic.code, diagnostic.message)
|
|
68
|
+
print(scene.space)
|
|
69
|
+
quality = scene.quality()
|
|
70
|
+
print(quality.is_watertight, quality.boundary_edges, quality.surface_area)
|
|
71
|
+
|
|
72
|
+
primitive = scene.meshes[0].primitives[0]
|
|
73
|
+
print(report.format, primitive.topology, primitive.positions().shape)
|
|
74
|
+
|
|
75
|
+
fitted = scene.normalize(anchor="center", target_extent=2.0)
|
|
76
|
+
result = fitted.export_bytes("model.glb")
|
|
77
|
+
glb = result.bytes
|
|
78
|
+
if result.has_losses:
|
|
79
|
+
for warning in result.diagnostics:
|
|
80
|
+
print(warning.code, warning.message)
|
|
81
|
+
fitted.export_file(Path("model.usdz"))
|
|
82
|
+
```
|
|
83
|
+
|
|
84
|
+
`load_file(path, *, mode="lenient", limits=None, pipeline=None)` accepts a string or `PathLike[str]` and resolves dependencies through the native filesystem relative to the model directory. `load_bytes(name, data, *, mode="lenient", limits=None, pipeline=None)` accepts `bytes` and uses `name` as a format hint. Use it for self-contained assets. A sidecar unavailable to `load_bytes` is observed as `failed`. A missing file resolved through `load_file` is observed as `missing`.
|
|
85
|
+
|
|
86
|
+
The import plugins support OBJ/MTL, PLY, STL, glTF/GLB/VRM, 3MF, FBX, COLLADA, USD/USDZ, BVH, URDF, and MJCF within Baozi's format profiles. Both loaders return `ImportReport` with the `scene`, a format ID, `diagnostics`, and `observed_assets`. Use `has_warnings` and `has_errors` to check for the corresponding diagnostic severities. Each observation contains a path, status, and byte count when loaded. [Format profiles](https://github.com/Latias94/baozi/blob/main/docs/formats/support-matrix.md)
|
|
87
|
+
|
|
88
|
+
`ImportLimits` and `PipelineOptions` are typed dictionaries. Integer limit values override the corresponding defaults. Pipeline keys enable the selected passes.
|
|
89
|
+
|
|
90
|
+
- `ImportLimits` accepts `max_file_bytes`, `max_total_bytes`, `max_files`, `max_asset_observation_bytes`, `max_vertices`, `max_indices`, `max_meshes`, `max_nodes`, `max_depth`, `max_image_bytes`, `max_custom_properties`, `max_custom_property_bytes`, and `max_diagnostics`.
|
|
91
|
+
- `PipelineOptions` accepts `triangulate`, `remove_degenerates`, `generate_normals`, `generate_tangents`, `unify_vertices`, `generate_bounds`, and `optimize_vertex_cache`.
|
|
92
|
+
|
|
93
|
+
## Inspect and edit scenes
|
|
94
|
+
|
|
95
|
+
- `Scene.meshes`, `nodes`, `materials`, and `animations` expose scene entities in arena order. Their IDs are zero-based. `Node.meshes` contains mesh IDs, and `Node.local_transform` is a 4×4 matrix in column order.
|
|
96
|
+
- `Scene.space` is a read-only `SceneSpace` with handedness, up and front axes, meters per unit, front-face winding, and UV origin. Individual fields are `None` when unspecified. `str(scene.space)` gives Baozi's human-readable description.
|
|
97
|
+
- `Scene.compute_bounds()` returns base-pose scene-space `Bounds` with `min` and `max` triples, or `None` if no bounds are available. `Scene.validate()` checks references and payloads. `Scene.inspect_features()` maps core feature names such as `PositionsF64` to entity identifiers such as `mesh#0`.
|
|
98
|
+
- `Scene.quality()` returns a read-only `MeshQualityReport` with topology counts, `is_watertight`, `surface_area`, and `signed_volume`. It measures base-pose mesh placements in scene units without holding the GIL. Treat signed volume as a physical volume only for closed, consistently wound surfaces.
|
|
99
|
+
- `Scene.condition(pipeline=None)` applies the selected passes. `Scene.normalize(*, anchor="center", target_extent=None, mode="root_transform")` fits geometry in scene space. The anchors are `none`, `center`, and `ground`. `root_transform` applies the fit through the hierarchy, and `bake_geometry` writes the fit into static geometry. When supplied, `target_extent` sets the longest side in scene units.
|
|
100
|
+
- `Scene.bake_frame(clip, time_seconds)` samples transforms, deformation, and glTF node
|
|
101
|
+
visibility by clip ID and returns a static scene. Other glTF animation pointer properties
|
|
102
|
+
keep their authored values. `Node.visible` is local to the node and
|
|
103
|
+
`Node.effective_visible` also accounts for its ancestors.
|
|
104
|
+
|
|
105
|
+
Conditioning, normalization, and baking return independent scene snapshots. Existing mesh and primitive objects remain valid. `Scene.diagnostics` contains diagnostics from the operation that produced a conditioned or normalized scene. For load-time diagnostics, use `ImportReport.diagnostics`. Baozi releases the GIL during native import, scene processing, and export work.
|
|
106
|
+
|
|
107
|
+
## Export scenes
|
|
108
|
+
|
|
109
|
+
`Scene.export_bytes(name, *, mode="lenient")` returns an `ExportBytesResult` with read-only `bytes`, `format`, and `diagnostics` properties. Use `result.bytes` or `bytes(result)` to get the self-contained payload. `Scene.export_file(path, *, mode="lenient")` returns an `ExportReport` with `format`, `diagnostics`, and `written_sidecars`.
|
|
110
|
+
|
|
111
|
+
The extension selects the output format. Supported exporters include glTF/GLB, USD/USDZ, OBJ, PLY, STL, and 3MF. `ExportReport.format` gives the encoder ID, such as `gltf` for both `.gltf` and `.glb` and `usd` for `.usdz`. `ExportBytesResult.format` gives the encoder ID for most outputs and `glb` for binary glTF.
|
|
112
|
+
|
|
113
|
+
Both methods return export warnings in `diagnostics` in lenient mode. `has_losses` is true when diagnostics are present, and `is_lossless` is true when the list is empty. Strict mode rejects losses with a `BaoziExportError` whose `code` identifies the loss. For example, `gltf.position_precision` reports conversion from double-precision positions to glTF's 32-bit positions.
|
|
114
|
+
|
|
115
|
+
## NumPy geometry buffers
|
|
116
|
+
|
|
117
|
+
`Mesh.primitives` contains the mesh's drawable primitives in order. A primitive exposes its topology, vertex and corner counts, and optional material ID. Its array methods return C-contiguous views.
|
|
118
|
+
|
|
119
|
+
| Method | Shape | dtype | Row order |
|
|
120
|
+
| --- | --- | --- | --- |
|
|
121
|
+
| `positions()` | `(vertex_count, 3)` | `float32` or `float64` | Mesh-local vertices, in core storage precision |
|
|
122
|
+
| `normals()` | `(N, 3)` | `float32` | The vertex, corner, or face domain reported by `normal_domain` |
|
|
123
|
+
| `texcoords(set=0)` | `(N, 2)` or `(N, 3)` | `float32` | The domain of that set in `texcoord_sets` |
|
|
124
|
+
| `indices()` | `(corner_count,)` | `uint32` | Explicit corner-to-vertex indices |
|
|
125
|
+
|
|
126
|
+
Missing normals, missing or out-of-range UV sets, and unindexed primitives return `None` from their corresponding methods. Each UV set reports its domain, component count, and optional name in `texcoord_sets`.
|
|
127
|
+
|
|
128
|
+
Baozi loads NumPy when an array accessor first needs it. The first request for each available stream copies its values into an independent, contiguous Rust buffer with the GIL released. Subsequent calls return fresh read-only NumPy views over the same buffer in constant time. Each view has independent array metadata and keeps its buffer readable after the scene, mesh, and primitive objects are collected. Use `array.copy()` to obtain a writable array.
|
|
129
|
+
|
|
130
|
+
## Errors and typing
|
|
131
|
+
|
|
132
|
+
`BaoziError` is the base for `BaoziImportError`, `BaoziValidationError`, `BaoziPostProcessError`, `BaoziEvalError`, `BaoziExportError`, `BaoziLimitExceededError`, and `BaoziCancelledError`. Exceptions raised by Baozi expose a machine-readable `code` and a list of `diagnostics`. Directly constructed exceptions start with an empty code and their own empty diagnostic list. Diagnostics have a severity, code, message, and optional `SourceLocation` with a path, line, column, and byte range. The import and export modes are `lenient` and `strict`.
|
|
133
|
+
|
|
134
|
+
The package includes PEP 561 type information. From an active virtual environment in this directory, build the extension and run the Python checks with the repository's corpus fixtures available.
|
|
135
|
+
|
|
136
|
+
```sh
|
|
137
|
+
python -m pip install maturin numpy pytest mypy
|
|
138
|
+
maturin develop --locked
|
|
139
|
+
python -m pytest
|
|
140
|
+
python -m mypy --strict python/baozi3d tests/type_smoke.py
|
|
141
|
+
python -m mypy.stubtest baozi3d
|
|
142
|
+
```
|
|
143
|
+
|
baozi3d-0.1.0/README.md
ADDED
|
@@ -0,0 +1,106 @@
|
|
|
1
|
+
# Baozi for Python
|
|
2
|
+
|
|
3
|
+
[](https://pypi.org/project/baozi3d/)
|
|
4
|
+
[](https://pypi.org/project/baozi3d/)
|
|
5
|
+
[](https://github.com/Latias94/baozi/actions/workflows/bindings.yml)
|
|
6
|
+
[](https://github.com/Latias94/baozi#license)
|
|
7
|
+
|
|
8
|
+
The `baozi3d` package imports, conditions, evaluates, and exports 3D scenes from Python. PyPI releases are wheel-only. The wheels target the CPython `abi3-py39` stable ABI and require CPython 3.9 or later and NumPy 1.26 or later. A local source build uses the full repository checkout for the Rust workspace dependencies and requires Rust 1.95 or later and maturin.
|
|
9
|
+
|
|
10
|
+
```sh
|
|
11
|
+
python -m pip install baozi3d
|
|
12
|
+
```
|
|
13
|
+
|
|
14
|
+
## Load and process a scene
|
|
15
|
+
|
|
16
|
+
```python
|
|
17
|
+
from pathlib import Path
|
|
18
|
+
|
|
19
|
+
import baozi3d
|
|
20
|
+
|
|
21
|
+
report = baozi3d.load_file(
|
|
22
|
+
Path("model.obj"),
|
|
23
|
+
limits=baozi3d.ImportLimits(max_file_bytes=64 * 1024 * 1024),
|
|
24
|
+
pipeline=baozi3d.PipelineOptions(triangulate=True, generate_normals=True),
|
|
25
|
+
)
|
|
26
|
+
scene = report.scene
|
|
27
|
+
scene.validate()
|
|
28
|
+
|
|
29
|
+
if report.has_warnings or report.has_errors:
|
|
30
|
+
for diagnostic in report.diagnostics:
|
|
31
|
+
print(diagnostic.severity, diagnostic.code, diagnostic.message)
|
|
32
|
+
print(scene.space)
|
|
33
|
+
quality = scene.quality()
|
|
34
|
+
print(quality.is_watertight, quality.boundary_edges, quality.surface_area)
|
|
35
|
+
|
|
36
|
+
primitive = scene.meshes[0].primitives[0]
|
|
37
|
+
print(report.format, primitive.topology, primitive.positions().shape)
|
|
38
|
+
|
|
39
|
+
fitted = scene.normalize(anchor="center", target_extent=2.0)
|
|
40
|
+
result = fitted.export_bytes("model.glb")
|
|
41
|
+
glb = result.bytes
|
|
42
|
+
if result.has_losses:
|
|
43
|
+
for warning in result.diagnostics:
|
|
44
|
+
print(warning.code, warning.message)
|
|
45
|
+
fitted.export_file(Path("model.usdz"))
|
|
46
|
+
```
|
|
47
|
+
|
|
48
|
+
`load_file(path, *, mode="lenient", limits=None, pipeline=None)` accepts a string or `PathLike[str]` and resolves dependencies through the native filesystem relative to the model directory. `load_bytes(name, data, *, mode="lenient", limits=None, pipeline=None)` accepts `bytes` and uses `name` as a format hint. Use it for self-contained assets. A sidecar unavailable to `load_bytes` is observed as `failed`. A missing file resolved through `load_file` is observed as `missing`.
|
|
49
|
+
|
|
50
|
+
The import plugins support OBJ/MTL, PLY, STL, glTF/GLB/VRM, 3MF, FBX, COLLADA, USD/USDZ, BVH, URDF, and MJCF within Baozi's format profiles. Both loaders return `ImportReport` with the `scene`, a format ID, `diagnostics`, and `observed_assets`. Use `has_warnings` and `has_errors` to check for the corresponding diagnostic severities. Each observation contains a path, status, and byte count when loaded. [Format profiles](https://github.com/Latias94/baozi/blob/main/docs/formats/support-matrix.md)
|
|
51
|
+
|
|
52
|
+
`ImportLimits` and `PipelineOptions` are typed dictionaries. Integer limit values override the corresponding defaults. Pipeline keys enable the selected passes.
|
|
53
|
+
|
|
54
|
+
- `ImportLimits` accepts `max_file_bytes`, `max_total_bytes`, `max_files`, `max_asset_observation_bytes`, `max_vertices`, `max_indices`, `max_meshes`, `max_nodes`, `max_depth`, `max_image_bytes`, `max_custom_properties`, `max_custom_property_bytes`, and `max_diagnostics`.
|
|
55
|
+
- `PipelineOptions` accepts `triangulate`, `remove_degenerates`, `generate_normals`, `generate_tangents`, `unify_vertices`, `generate_bounds`, and `optimize_vertex_cache`.
|
|
56
|
+
|
|
57
|
+
## Inspect and edit scenes
|
|
58
|
+
|
|
59
|
+
- `Scene.meshes`, `nodes`, `materials`, and `animations` expose scene entities in arena order. Their IDs are zero-based. `Node.meshes` contains mesh IDs, and `Node.local_transform` is a 4×4 matrix in column order.
|
|
60
|
+
- `Scene.space` is a read-only `SceneSpace` with handedness, up and front axes, meters per unit, front-face winding, and UV origin. Individual fields are `None` when unspecified. `str(scene.space)` gives Baozi's human-readable description.
|
|
61
|
+
- `Scene.compute_bounds()` returns base-pose scene-space `Bounds` with `min` and `max` triples, or `None` if no bounds are available. `Scene.validate()` checks references and payloads. `Scene.inspect_features()` maps core feature names such as `PositionsF64` to entity identifiers such as `mesh#0`.
|
|
62
|
+
- `Scene.quality()` returns a read-only `MeshQualityReport` with topology counts, `is_watertight`, `surface_area`, and `signed_volume`. It measures base-pose mesh placements in scene units without holding the GIL. Treat signed volume as a physical volume only for closed, consistently wound surfaces.
|
|
63
|
+
- `Scene.condition(pipeline=None)` applies the selected passes. `Scene.normalize(*, anchor="center", target_extent=None, mode="root_transform")` fits geometry in scene space. The anchors are `none`, `center`, and `ground`. `root_transform` applies the fit through the hierarchy, and `bake_geometry` writes the fit into static geometry. When supplied, `target_extent` sets the longest side in scene units.
|
|
64
|
+
- `Scene.bake_frame(clip, time_seconds)` samples transforms, deformation, and glTF node
|
|
65
|
+
visibility by clip ID and returns a static scene. Other glTF animation pointer properties
|
|
66
|
+
keep their authored values. `Node.visible` is local to the node and
|
|
67
|
+
`Node.effective_visible` also accounts for its ancestors.
|
|
68
|
+
|
|
69
|
+
Conditioning, normalization, and baking return independent scene snapshots. Existing mesh and primitive objects remain valid. `Scene.diagnostics` contains diagnostics from the operation that produced a conditioned or normalized scene. For load-time diagnostics, use `ImportReport.diagnostics`. Baozi releases the GIL during native import, scene processing, and export work.
|
|
70
|
+
|
|
71
|
+
## Export scenes
|
|
72
|
+
|
|
73
|
+
`Scene.export_bytes(name, *, mode="lenient")` returns an `ExportBytesResult` with read-only `bytes`, `format`, and `diagnostics` properties. Use `result.bytes` or `bytes(result)` to get the self-contained payload. `Scene.export_file(path, *, mode="lenient")` returns an `ExportReport` with `format`, `diagnostics`, and `written_sidecars`.
|
|
74
|
+
|
|
75
|
+
The extension selects the output format. Supported exporters include glTF/GLB, USD/USDZ, OBJ, PLY, STL, and 3MF. `ExportReport.format` gives the encoder ID, such as `gltf` for both `.gltf` and `.glb` and `usd` for `.usdz`. `ExportBytesResult.format` gives the encoder ID for most outputs and `glb` for binary glTF.
|
|
76
|
+
|
|
77
|
+
Both methods return export warnings in `diagnostics` in lenient mode. `has_losses` is true when diagnostics are present, and `is_lossless` is true when the list is empty. Strict mode rejects losses with a `BaoziExportError` whose `code` identifies the loss. For example, `gltf.position_precision` reports conversion from double-precision positions to glTF's 32-bit positions.
|
|
78
|
+
|
|
79
|
+
## NumPy geometry buffers
|
|
80
|
+
|
|
81
|
+
`Mesh.primitives` contains the mesh's drawable primitives in order. A primitive exposes its topology, vertex and corner counts, and optional material ID. Its array methods return C-contiguous views.
|
|
82
|
+
|
|
83
|
+
| Method | Shape | dtype | Row order |
|
|
84
|
+
| --- | --- | --- | --- |
|
|
85
|
+
| `positions()` | `(vertex_count, 3)` | `float32` or `float64` | Mesh-local vertices, in core storage precision |
|
|
86
|
+
| `normals()` | `(N, 3)` | `float32` | The vertex, corner, or face domain reported by `normal_domain` |
|
|
87
|
+
| `texcoords(set=0)` | `(N, 2)` or `(N, 3)` | `float32` | The domain of that set in `texcoord_sets` |
|
|
88
|
+
| `indices()` | `(corner_count,)` | `uint32` | Explicit corner-to-vertex indices |
|
|
89
|
+
|
|
90
|
+
Missing normals, missing or out-of-range UV sets, and unindexed primitives return `None` from their corresponding methods. Each UV set reports its domain, component count, and optional name in `texcoord_sets`.
|
|
91
|
+
|
|
92
|
+
Baozi loads NumPy when an array accessor first needs it. The first request for each available stream copies its values into an independent, contiguous Rust buffer with the GIL released. Subsequent calls return fresh read-only NumPy views over the same buffer in constant time. Each view has independent array metadata and keeps its buffer readable after the scene, mesh, and primitive objects are collected. Use `array.copy()` to obtain a writable array.
|
|
93
|
+
|
|
94
|
+
## Errors and typing
|
|
95
|
+
|
|
96
|
+
`BaoziError` is the base for `BaoziImportError`, `BaoziValidationError`, `BaoziPostProcessError`, `BaoziEvalError`, `BaoziExportError`, `BaoziLimitExceededError`, and `BaoziCancelledError`. Exceptions raised by Baozi expose a machine-readable `code` and a list of `diagnostics`. Directly constructed exceptions start with an empty code and their own empty diagnostic list. Diagnostics have a severity, code, message, and optional `SourceLocation` with a path, line, column, and byte range. The import and export modes are `lenient` and `strict`.
|
|
97
|
+
|
|
98
|
+
The package includes PEP 561 type information. From an active virtual environment in this directory, build the extension and run the Python checks with the repository's corpus fixtures available.
|
|
99
|
+
|
|
100
|
+
```sh
|
|
101
|
+
python -m pip install maturin numpy pytest mypy
|
|
102
|
+
maturin develop --locked
|
|
103
|
+
python -m pytest
|
|
104
|
+
python -m mypy --strict python/baozi3d tests/type_smoke.py
|
|
105
|
+
python -m mypy.stubtest baozi3d
|
|
106
|
+
```
|