Photon Engine 2.0.0-beta
A physically based renderer.
Loading...
Searching...
No Matches
ph::LerpedSurfaceOptics Class Reference

Linearly interpolate between two surface optics. More...

#include <LerpedSurfaceOptics.h>

Inheritance diagram for ph::LerpedSurfaceOptics:
ph::SurfaceOptics

Public Member Functions

 LerpedSurfaceOptics (const std::shared_ptr< SurfaceOptics > &optics0, const std::shared_ptr< SurfaceOptics > &optics1)
 
 LerpedSurfaceOptics (const std::shared_ptr< SurfaceOptics > &optics0, const std::shared_ptr< SurfaceOptics > &optics1, real ratio)
 Computes the final optics as optics0 * ratio + optics1 * (1 - ratio).
 
 LerpedSurfaceOptics (const std::shared_ptr< SurfaceOptics > &optics0, const std::shared_ptr< SurfaceOptics > &optics1, const std::shared_ptr< TTexture< math::Spectrum > > &ratio)
 Computes the final optics as optics0 * ratio + optics1 * (1 - ratio).
 
ESurfacePhenomenon getPhenomenonOf (SurfaceElemental elemental) const override
 Get the phenomenon of a surface component. One can also setup query for a specific elemental. See BsdfQueryContext.
 
std::string toString () const override
 
- Public Member Functions inherited from ph::SurfaceOptics
 SurfaceOptics ()
 
virtual ~SurfaceOptics ()=default
 
void calcBsdf (BsdfEvalQuery &eval) const
 Executes a BSDF evaluation query. Respects sidedness policy.
 
void genBsdfSample (BsdfSampleQuery &sample, SampleFlow &sampleFlow) const
 Executes a BSDF sample query. Respects sidedness policy.
 
void calcBsdfPdf (BsdfPdfQuery &pdfQuery) const
 Executes a BSDF sample PDF query. Respects sidedness policy.
 
SurfacePhenomena getAllPhenomena () const
 Get all phenomena that exist in this surface.
 
SurfaceElemental numElementals () const
 Get number of components this surface contains.
 

Additional Inherited Members

- Protected Attributes inherited from ph::SurfaceOptics
SurfacePhenomena m_phenomena
 
SurfaceElemental m_numElementals
 

Detailed Description

Linearly interpolate between two surface optics.

Constructor & Destructor Documentation

◆ LerpedSurfaceOptics() [1/3]

ph::LerpedSurfaceOptics::LerpedSurfaceOptics ( const std::shared_ptr< SurfaceOptics > & optics0,
const std::shared_ptr< SurfaceOptics > & optics1 )

◆ LerpedSurfaceOptics() [2/3]

ph::LerpedSurfaceOptics::LerpedSurfaceOptics ( const std::shared_ptr< SurfaceOptics > & optics0,
const std::shared_ptr< SurfaceOptics > & optics1,
real ratio )

Computes the final optics as optics0 * ratio + optics1 * (1 - ratio).

◆ LerpedSurfaceOptics() [3/3]

ph::LerpedSurfaceOptics::LerpedSurfaceOptics ( const std::shared_ptr< SurfaceOptics > & optics0,
const std::shared_ptr< SurfaceOptics > & optics1,
const std::shared_ptr< TTexture< math::Spectrum > > & ratio )

Computes the final optics as optics0 * ratio + optics1 * (1 - ratio).

Member Function Documentation

◆ getPhenomenonOf()

ESurfacePhenomenon ph::LerpedSurfaceOptics::getPhenomenonOf ( SurfaceElemental elemental) const
overridevirtual

Get the phenomenon of a surface component. One can also setup query for a specific elemental. See BsdfQueryContext.

Implements ph::SurfaceOptics.

◆ toString()

std::string ph::LerpedSurfaceOptics::toString ( ) const
inlineoverridevirtual

Reimplemented from ph::SurfaceOptics.


The documentation for this class was generated from the following files: