Documentation
¶
Index ¶
- type FilmSplat
- type Handler
- func (h *Handler) TraceRay(objTree *object.ObjectTree, ray *optics.Ray, level int64)
- func (h *Handler) TraceScene(job RenderJob) error
- func (h *Handler) TraceSpectral(job RenderJob, index ...int) []renderfilm.SpectralSample
- func (h *Handler) TraceSpectralSample(job RenderJob, ray *optics.Ray, wavelengthSampler optics.WavelengthSampler, ...) renderfilm.SpectralSample
- type IntegratorKind
- type PreparedIntegratorState
- type RenderJob
- type SceneIntegrator
- type SegmentTransmittance
- type SurfaceInteraction
- type TileCoordinate
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type FilmSplat ¶
type FilmSplat struct {
Pixel int
WavelengthNM float64
WavelengthPDF float64
Value float64
// contains filtered or unexported fields
}
FilmSplat is an unnormalized contribution produced by a global path sample.
type Handler ¶
type Handler struct {
MaxRayLevel int64 `json:"max_ray_level"`
RussianRouletteDepth int64 `json:"russian_roulette_depth"`
MaxArc float64 `json:"max_arc"` // total geodesic distance budget per ray (0 ⇒ unbounded)
Space geometry.SceneSpace `json:"-"`
BlockCols int `json:"block_cols"`
BlockRows int `json:"block_rows"`
WavelengthSampler optics.WavelengthSampler `json:"-"`
RayPool sync.Pool `json:"ray_pool"`
}
func NewHandler ¶
func NewHandler(space geometry.SceneSpace) *Handler
func (*Handler) TraceScene ¶
TraceScene selects one scene-level integrator and delegates the complete render schedule to it.
func (*Handler) TraceSpectral ¶
func (h *Handler) TraceSpectral(job RenderJob, index ...int) []renderfilm.SpectralSample
func (*Handler) TraceSpectralSample ¶
func (h *Handler) TraceSpectralSample( job RenderJob, ray *optics.Ray, wavelengthSampler optics.WavelengthSampler, u float64, index ...int, ) renderfilm.SpectralSample
type IntegratorKind ¶
type IntegratorKind string
IntegratorKind is the serialized name of a light-transport algorithm.
const ( IntegratorPathTracing IntegratorKind = "path" IntegratorBDPT IntegratorKind = "bdpt" IntegratorLightTracing IntegratorKind = "light_tracing" )
func ParseIntegratorKind ¶
func ParseIntegratorKind(value string) (IntegratorKind, error)
ParseIntegratorKind accepts only canonical Engine protocol names.
type PreparedIntegratorState ¶
type PreparedIntegratorState interface {
// contains filtered or unexported methods
}
type RenderJob ¶
type RenderJob struct {
// contains filtered or unexported fields
}
RenderJob is the single resolved representation of one render. Its public construction validates all required values; runtime-only state is attached to a private copy by Handler.TraceScene.
func NewRenderJob ¶
func (RenderJob) Integrator ¶
func (j RenderJob) Integrator() IntegratorKind
func (RenderJob) WavelengthSamples ¶
type SceneIntegrator ¶
type SceneIntegrator interface {
Prepare(*RenderJob) (PreparedIntegratorState, error)
Run(*RenderJob, PreparedIntegratorState) error
EffectiveSampleCount(*RenderJob) int64
ConcurrentFilmWrites() bool
}
SceneIntegrator owns a work-distribution model. Algorithms are injected as kernels, so pixel-driven and splat-driven transports share one lifecycle without pretending to have the same scheduling semantics.
func NewSceneIntegrator ¶
func NewSceneIntegrator(kind IntegratorKind) (SceneIntegrator, error)
NewSceneIntegrator resolves configuration once, before rendering begins.
type SegmentTransmittance ¶
SegmentTransmittance is scalar attenuation at the path's sampled wavelength.
func (SegmentTransmittance) ApplyToPower ¶
func (t SegmentTransmittance) ApplyToPower(value float64) float64
func (SegmentTransmittance) ApplyToRay ¶
func (t SegmentTransmittance) ApplyToRay(ray *renderray.Ray)