Renderer¶
-
template<IsSpectral TSpectral>
class Renderer¶ Abstract base class for scene renderers.
Renderer provides the interface and common helpers for rendering a SceneView into a FrameBuffer. Derived classes implement specific rendering algorithms (e.g., rasterization, ray tracing).
- Template Parameters:
TSpectral – Spectral type for the rendering pipeline
Subclassed by huira::RasterRenderer< TSpectral >
Public Functions
-
virtual ~Renderer() = default¶
-
virtual void render(SceneView<TSpectral> &scene_view, FrameBuffer<TSpectral> &frame_buffer, float exposure_time) = 0¶
Protected Functions
-
void render_unresolved_(SceneView<TSpectral> &scene_view, FrameBuffer<TSpectral> &frame_buffer)¶
Render unresolved point sources (stars and unresolved objects) into the frame buffer.
This method implements an optimized pipeline for rendering point sources that cannot be resolved into visible geometry. It supports both delta-function (no PSF) and spatially- distributed PSF rendering with adaptive radius culling for performance.
The rendering pipeline:
Collects all stars and unresolved objects into a unified list
Builds a radius LUT and assigns per-source effective PSF radii based on irradiance
Projects sources to screen space and bins them into tiles
Renders each tile in parallel into local buffers
Combines tile buffers into the final frame buffer
Performance optimizations:
Adaptive PSF radius: dim sources use smaller kernels
Tiled rendering: parallel processing with minimal synchronization
Depth occlusion testing: skip sources behind resolved geometry
- Template Parameters:
TSpectral – Spectral type for the rendering pipeline
- Parameters:
scene_view – The scene view containing stars and unresolved objects
frame_buffer – The frame buffer to render into
-
inline std::shared_ptr<CameraModel<TSpectral>> get_camera(SceneView<TSpectral> &scene_view) const¶
Protected Attributes
-
RandomSampler<float> sampler_¶