Photon Engine 2.0.0-beta
A physically based renderer.
Loading...
Searching...
No Matches
IesData.h
Go to the documentation of this file.
1#pragma once
2
5
6#include <Common/primitive_type.h>
7
8#include <vector>
9
10namespace ph
11{
12
18{
19public:
20 explicit IesData(const Path& iesFilePath);
21
22 real sampleAttenuationFactor(real theta, real phi) const;
23 std::size_t numAttenuationFactorThetaSamples() const;
24 std::size_t numAttenuationFactorPhiSamples() const;
25
26private:
27 IesFile m_file;
28
34 std::vector<std::vector<real>> m_sphericalCandelas;
35
36 std::vector<std::vector<real>> m_sphericalAttenuationFactors;
37
38 enum class EReflectFrom
39 {
40 Theta_Head,
41 Theta_Tail,
42 Phi_Head,
43 Phi_Tail
44 };
45
46 void processCandelaValues();
47 void processAttenuationFactors();
48 void reflectCandelaValues(EReflectFrom reflectFrom, real reflectionMultiplier = 1.0_r);
49
50 static real calcBicubicWeight(real x);
51};
52
53}// end namespace ph
Definition IesData.h:18
IesData(const Path &iesFilePath)
Definition IesData.cpp:16
std::size_t numAttenuationFactorThetaSamples() const
Definition IesData.cpp:275
real sampleAttenuationFactor(real theta, real phi) const
Definition IesData.cpp:32
std::size_t numAttenuationFactorPhiSamples() const
Definition IesData.cpp:287
Definition IesFile.h:20
General path representation. Does not check whether the target actually exists (e....
Definition Path.h:21
The root for all renderer implementations.
Definition EEngineProject.h:6