Loading...
Searching...
No Matches
Public Member Functions | List of all members
standardLog< BSDF, REFERENCE, COMPONENT, UNIT > Struct Template Reference

standardLog loss function More...

#include <cosine_weighted_log.h>

Inherits sampledlossfunction< BSDF, REFERENCE, SAMPLELOSSFUNC, LINEARIZER, COMPONENT, UNIT >.

Public Member Functions

 BBM_IMPORT_CONFIG (BSDF)
 
 standardLog (const BSDF &bsdf, const REFERENCE &reference, const vec2d< Size_t > &samplesIn, const vec2d< Size_t > &samplesOut, const Vec2d &startIn=0, const Vec2d &endIn=Constants::Hemisphere(), const Vec2d &startOut=0, const Vec2d &endOut=Constants::Hemisphere())
 Constructor.
 
- Public Member Functions inherited from sampledlossfunction< BSDF, REFERENCE, SAMPLELOSSFUNC, LINEARIZER, COMPONENT, UNIT >
 BBM_IMPORT_CONFIG (BSDF)
 
 sampledlossfunction (const BSDF &bsdf, const REFERENCE &reference, const SAMPLELOSSFUNC &samplelossfunc, const LINEARIZER &linearizer)
 Constructor.
 
void update (void)
 Init (does nothing)
 
Size_t samples (void) const
 Returns the number of samples.
 
Value operator() (Size_t idx, Mask mask=true) const
 Compute the loss over the idx-th sample.
 
Value operator() (Mask mask=true) const
 Compute loss over all samples.
 

Detailed Description

template<typename BSDF, typename REFERENCE, bsdf_flag COMPONENT = bsdf_flag::All, unit_t UNIT = unit_t::Radiance>
requires concepts::matching_config<BSDF, REFERENCE> && concepts::bsdfmodel<BSDF> && concepts::bsdfmodel<REFERENCE>
struct bbm::standardLog< BSDF, REFERENCE, COMPONENT, UNIT >

standardLog loss function

Template Parameters
BSDF= bsdf to optimize
REFERENCE= bsdf to match
COMPONENT= which bsdf component to optimize
UNIT= unit over which to optimize

standardLog is a sampled loss function that computes the loss over two BSDFs using the standardLog_error and a spherical sampling of in and out directions (spherical_linearizer).

Implements: concepts::sampledlossfunction

Constructor & Destructor Documentation

◆ standardLog()

standardLog ( const BSDF &  bsdf,
const REFERENCE &  reference,
const vec2d< Size_t > &  samplesIn,
const vec2d< Size_t > &  samplesOut,
const Vec2d &  startIn = 0,
const Vec2d &  endIn = Constants::Hemisphere(),
const Vec2d &  startOut = 0,
const Vec2d &  endOut = Constants::Hemisphere() 
)
inline

Constructor.

Parameters
bsdf= bsdf to optimize
reference= bsdf to match
samplesIn= number of (phi, theta) samples for the 'in' direction
samplesOut= number of (phi, theta) samples for the 'out' direction
startIn= (phi,theta) angles to start sampling the 'in' direction (default: (0,0))
endIn= (phi,theta) angles to end sampling the 'in' direction (defailt: Hemisphere)
startOut= (phi,theta) angles to start sampling the 'out' direction (default: (0,0))
endOut= (phi,theta) angles to end sampling the 'out' direction (default: Hemisphere)

Member Function Documentation

◆ BBM_IMPORT_CONFIG()

BBM_IMPORT_CONFIG ( BSDF  )

The documentation for this struct was generated from the following file: