Photon Engine 2.0.0-beta
A physically based renderer.
Loading...
Searching...
No Matches
IdealReflector.h
Go to the documentation of this file.
1#pragma once
2
7
8#include <memory>
9
10namespace ph
11{
12
14{
15public:
16 explicit IdealReflector(std::shared_ptr<FresnelEffect> fresnel);
17
19 std::shared_ptr<FresnelEffect> fresnel,
20 std::shared_ptr<TTexture<math::Spectrum>> reflectionScale);
21
22 ESurfacePhenomenon getPhenomenonOf(SurfaceElemental elemental) const override;
23
24private:
25 void calcBsdf(
26 const BsdfQueryContext& ctx,
27 const BsdfEvalInput& in,
28 BsdfEvalOutput& out) const override;
29
30 void genBsdfSample(
31 const BsdfQueryContext& ctx,
32 const BsdfSampleInput& in,
33 SampleFlow& sampleFlow,
34 BsdfSampleOutput& out) const override;
35
36 void calcBsdfPdf(
37 const BsdfQueryContext& ctx,
38 const BsdfPdfInput& in,
39 BsdfPdfOutput& out) const override;
40
41private:
42 std::shared_ptr<FresnelEffect> m_fresnel;
43 std::shared_ptr<TTexture<math::Spectrum>> m_reflectionScale;
44};
45
46}// end namespace ph
Input for BsdfEvalQuery.
Definition BsdfEvalQuery.h:20
Output for BsdfEvalQuery.
Definition BsdfEvalQuery.h:47
Input for BsdfPdfQuery.
Definition BsdfPdfQuery.h:19
Output for BsdfPdfQuery.
Definition BsdfPdfQuery.h:46
The environment a BSDF query is performed under.
Definition BsdfQueryContext.h:13
Input for BsdfSampleQuery.
Definition BsdfSampleQuery.h:21
Output for BsdfSampleQuery.
Definition BsdfSampleQuery.h:45
Definition IdealReflector.h:14
IdealReflector(std::shared_ptr< FresnelEffect > fresnel)
Definition IdealReflector.cpp:17
ESurfacePhenomenon getPhenomenonOf(SurfaceElemental elemental) const override
Get the phenomenon of a surface component. One can also setup query for a specific elemental....
Definition IdealReflector.cpp:39
A sample with arbitrary dimensions with fine-grained sampling control.
Definition SampleFlow.h:19
Describes how light interacts with a surface.
Definition SurfaceOptics.h:17
Definition TTexture.h:12
The root for all renderer implementations.
Definition EEngineProject.h:6
ESurfacePhenomenon
Available surface phenomena.
Definition surface_optics_fwd.h:16
int SurfaceElemental
Definition surface_optics_fwd.h:30