Photon Engine 2.0.0-beta
A physically based renderer.
Loading...
Searching...
No Matches
TIndirectLightEstimator.h
Go to the documentation of this file.
1#pragma once
2
3#include "Math/math_fwd.h"
6
7#include <cstddef>
8
9namespace ph { class Scene; }
10namespace ph { class SurfaceHit; }
11namespace ph { class SampleFlow; }
12
13namespace ph::lta
14{
15
16class RussianRoulette;
17
21template<ESidednessPolicy POLICY>
23{
24public:
25 explicit TIndirectLightEstimator(const Scene* scene);
26
37 [[nodiscard]]
39 const SurfaceHit& X,
40 SampleFlow& sampleFlow,
41 std::size_t pathLength,
42 const RussianRoulette& rr,
43 math::Spectrum* out_Lo = nullptr,
44 std::size_t rrBeginPathLength = 0,
45 const math::Spectrum& initialPathWeight = math::Spectrum(1)) const;
46
59 [[nodiscard]]
61 const SurfaceHit& X,
62 SampleFlow& sampleFlow,
63 std::size_t minPathLength,
64 std::size_t maxPathLength,
65 const RussianRoulette& rr,
66 math::Spectrum* out_Lo = nullptr,
67 std::size_t rrBeginPathLength = 0,
68 const math::Spectrum& initialPathWeight = math::Spectrum(1)) const;
69
70private:
71 const Scene* m_scene;
72};
73
74}// end namespace ph::lta
75
A sample with arbitrary dimensions with fine-grained sampling control.
Definition SampleFlow.h:19
A unified interface for accessing cooked content in a visual world.
Definition Scene.h:27
General information about a ray-surface intersection event.
Definition SurfaceHit.h:59
Russian roulette random termination scheme.
Definition RussianRoulette.h:16
Estimate indirect lighting for a surface point.
Definition TIndirectLightEstimator.h:23
TIndirectLightEstimator(const Scene *scene)
Definition TIndirectLightEstimator.ipp:19
bool bsdfSamplePathWithNee(const SurfaceHit &X, SampleFlow &sampleFlow, std::size_t pathLength, const RussianRoulette &rr, math::Spectrum *out_Lo=nullptr, std::size_t rrBeginPathLength=0, const math::Spectrum &initialPathWeight=math::Spectrum(1)) const
Constructing path with BSDF sampling and estimate lighting with both BSDF sampling and next-event est...
Definition TIndirectLightEstimator.ipp:26
Definition TTristimulusSpectrum.h:11
Light transport algorithms.
Definition enums.h:6
The root for all renderer implementations.
Definition EEngineProject.h:6