bundle.recon3d.stages.blender.base¶
Blender stage — base class and I/O contracts.
Takes a GaussiansOutput (PLY path) and produces a .blend file via a
headless Blender run. The stage is optional: it only participates in the
pipeline when Blender is discoverable on the host.
Blender-side logic lives in scripts/ as standalone .py files loaded
via --python. Parameters are passed as a JSON sidecar; no string
interpolation on the host side.
Extending¶
Subclass BlenderStage, set script_name to a script in scripts/,
and override _build_params to supply the script’s expected keys:
class BlenderTurntableStage(BlenderStage):
name: str = "blender_turntable"
script_name: str = "render_turntable"
def _build_params(self, inp, render_dir):
return {"blend_path": str(inp.blend_path), "frames": inp.frames, ...}
Attributes¶
Classes¶
Input contract for the Blender import stage. |
|
Output contract from the Blender import stage. |
|
Imports a 3DGS PLY into Blender headless and saves a |
Functions¶
|
Module Contents¶
- bundle.recon3d.stages.blender.base.log¶
- class bundle.recon3d.stages.blender.base.BlenderInput(/, **data: Any)[source]¶
Bases:
bundle.core.data.DataInput contract for the Blender import stage.
- gaussians_output: bundle.recon3d.stages.gaussians.base.GaussiansOutput¶
- blend_output: pathlib.Path¶
- engine: Literal['EEVEE', 'CYCLES'] = 'EEVEE'¶
- render_dir: pathlib.Path | None = None¶
- class bundle.recon3d.stages.blender.base.BlenderOutput(/, **data: Any)[source]¶
Bases:
bundle.core.data.DataOutput contract from the Blender import stage.
- blend_path: pathlib.Path¶
- render_dir: pathlib.Path | None = None¶
- class bundle.recon3d.stages.blender.base.BlenderStage(/, **data: Any)[source]¶
Bases:
bundle.recon3d.stages.base.StageImports a 3DGS PLY into Blender headless and saves a
.blendfile.Subclasses override
script_nameand_build_paramsto drive a different Blender script without touching the run machinery.- async run(input: bundle.core.data.Data) bundle.core.data.Data[source]¶
Execute the stage and return the output contract.
- bundle.recon3d.stages.blender.base.create_blender_stage() BlenderStage[source]¶