How theobaudoinlighting/blackframe-renderer works
Blackframe is a headless spectral rendering engine. Its main workflow parses a render request, reads and compiles a native scene, preflights the explicitly selected backend, renders, and writes image and metrics outputs. The README documents the major scene, transport, image, and backend capabilities; sampled code confirms key CLI, runner, JSON-reader, and CUDA-query responsibilities. Some internal links rely on README descriptions because the relevant implementation files were not sampled.
Main entry points: NativeSceneRunner.cpp Scene runner · SceneMisStages.cpp Spectral transport · CommandLine.cpp CLI parser · SceneCompiler.cpp Scene compiler
Components 20
Headless application
- CLI parser
Blackframe/Applications/Headless/Source/CommandLine.cpp - Scene runner
Blackframe/Applications/Headless/Source/NativeSceneRunner.cpp
Scene preparation
- Native JSON codec
Blackframe/Engine/Source/SceneDescriptionJsonReader.cpp - Asset resolver
Blackframe/Engine/Source/SceneAssetResolver.cpp - Mesh import
Blackframe/Engine/Source/TriangleMeshImport.cpp - Scene compiler
Blackframe/Engine/Source/SceneCompiler.cpp - Frame snapshot
Blackframe/Engine/Source/FrameScene.cpp
Rendering core
- Spectral transport
Blackframe/Engine/Source/SceneMisStages.cpp - Sampling and lights
Blackframe/Renderer/Source/LightSampler.cpp - Material closures
Blackframe/Renderer/Include/Blackframe/Renderer/ClosureMixture.hpp - Film accumulation
Blackframe/Renderer/Include/Blackframe/Renderer/Film.hpp - Image textures
Blackframe/Renderer/Source/HostImageCache.cpp
Execution backends
- Scalar reference
Blackframe/Engine/Source/SceneMisPathLoop.cpp - Embree CPU
Blackframe/Backends/CPU/Embree/Source/WavefrontMisTransport.cpp - CUDA wavefront
Blackframe/Backends/GPU/CUDA/Source/WavefrontTransport.cpp - CUDA scene query
Blackframe/Backends/GPU/CUDA/Source/SceneQuery.cpp
IPC and output
- Image and metrics output
Blackframe/Applications/Headless/Source/NativeSceneRunner.cpp - Local IPC
Blackframe/IPC/Source/LocalTransportPosix.cpp - Protocol framing
Blackframe/IPC/Source/LocalTransportFraming.hpp
Other components
- Render user
Connections 21
- Render user → CLI parser: submits request
- CLI parser → Scene runner: dispatches render
- Scene runner → Native JSON codec: loads scene
Blackframe/Applications/Headless/Source/NativeSceneRunner.cpp - Scene runner → Scene compiler: compiles scene
Blackframe/Applications/Headless/Source/NativeSceneRunner.cpp - Scene compiler → Frame snapshot: lowers scene
README.md - Scene compiler → Asset resolver: resolves assets
README.md - Native JSON codec → Mesh import: decodes meshes
README.md - Scene runner → Scalar reference: selects backend
README.md - Scene runner → Embree CPU: selects backend
README.md - Scene runner → CUDA wavefront: selects backend
README.md - Embree CPU → Spectral transport: executes transport
README.md - CUDA wavefront → Spectral transport: executes transport
README.md - Scalar reference → Spectral transport: executes transport
README.md - Spectral transport → Sampling and lights: uses light sampling
README.md - Spectral transport → Material closures: evaluates closures
README.md - Spectral transport → Film accumulation: accumulates samples
README.md - Spectral transport → Image textures: samples textures
README.md - CUDA wavefront → CUDA scene query: queries scene
Blackframe/Backends/GPU/CUDA/Source/SceneQuery.cpp - Scene runner → Image and metrics output: writes results
README.md - CLI parser → Local IPC: serves requests
- Local IPC → Protocol framing: frames messages
Blackframe/IPC/Source/LocalTransportPosix.cpp