Fermat
Public Types | Public Methods | Public Members | Static Public Members | List of all members
DirectLightingRL Struct Reference

Detailed description

A model of TPTDirectLightingSampler, implementing NEE sample generation from an emissive mesh using the novel adaptively clustered Reinforcement-Learning algorithm implemented in Clustered RL

#include <direct_lighting_rl.h>

Public Types

typedef AdaptiveClusteredRLView RLMap
 

Public Methods

FERMAT_HOST_DEVICE DirectLightingRL ()
 
FERMAT_HOST_DEVICE DirectLightingRL (RLMap _rl, VTLMeshView _vtls)
 
FERMAT_DEVICE uint32 preprocess_vertex (const RenderingContextView &renderer, const EyeVertex &ev, const uint32 pixel, const uint32 bounce, const bool is_secondary_diffuse, const float cone_radius, const cugar::Bbox3f scene_bbox)
 
FERMAT_DEVICE uint32 sample (const uint32 nee_slot, const float z[3], VertexGeometryId *light_vertex, VertexGeometry *light_vertex_geom, float *light_pdf, Edf *light_edf)
 
FERMAT_DEVICE void map (const uint32 prev_nee_slot, const uint32 triId, const cugar::Vector2f uv, const VertexGeometry light_vertex_geom, float *light_pdf, Edf *light_edf)
 
FERMAT_DEVICE void update (const uint32 nee_slot, const uint32 nee_cluster, const cugar::Vector3f w, const bool occluded)
 

Public Members

RLMap vtl_rl
 
VTLMeshView vtls
 

Static Public Members

static const uint32 INVALID_SLOT = 0xFFFFFFFF
 
static const uint32 INVALID_SAMPLE = 0xFFFFFFFF
 

Constructor & Destructor Documentation

◆ DirectLightingRL() [1/2]

FERMAT_HOST_DEVICE DirectLightingRL::DirectLightingRL ( )
inline

empty constructor

◆ DirectLightingRL() [2/2]

FERMAT_HOST_DEVICE DirectLightingRL::DirectLightingRL ( RLMap  _rl,
VTLMeshView  _vtls 
)
inline

constructor

Member Function Documentation

◆ map()

FERMAT_DEVICE void DirectLightingRL::map ( const uint32  prev_nee_slot,
const uint32  triId,
const cugar::Vector2f  uv,
const VertexGeometry  light_vertex_geom,
float *  light_pdf,
Edf light_edf 
)
inline

map a light vertex at the slot given at the previous vertex

◆ preprocess_vertex()

FERMAT_DEVICE uint32 DirectLightingRL::preprocess_vertex ( const RenderingContextView renderer,
const EyeVertex ev,
const uint32  pixel,
const uint32  bounce,
const bool  is_secondary_diffuse,
const float  cone_radius,
const cugar::Bbox3f  scene_bbox 
)
inline

preprocess a path vertex and return a hash slot used for NEE

◆ sample()

FERMAT_DEVICE uint32 DirectLightingRL::sample ( const uint32  nee_slot,
const float  z[3],
VertexGeometryId light_vertex,
VertexGeometry light_vertex_geom,
float *  light_pdf,
Edf light_edf 
)
inline

sample a light vertex at a given slot

◆ update()

FERMAT_DEVICE void DirectLightingRL::update ( const uint32  nee_slot,
const uint32  nee_cluster,
const cugar::Vector3f  w,
const bool  occluded 
)
inline

update with the resulting NEE sample


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