Clarisse 4.0 SP5b SDK  4.0.0.0.5.1
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
Public Member Functions | Friends | List of all members
CtxRaytrace Class Reference
Inheritance diagram for CtxRaytrace:
GeometryRaytraceData

Public Member Functions

void init (const unsigned int &size, const unsigned int &sampling_seed=0, const unsigned int &sampling_offset=0, const unsigned int &sampling_dimension=0)
 Initialize the context.
 
void clear ()
 Remove all intersections.
 
- Public Member Functions inherited from GeometryRaytraceData
 GeometryRaytraceData (const GeometryRaytraceData &src)
 
GeometryRaytraceCtxget_ctx ()
 Get the context of the raytracing.
 
const GeometryRaytraceCtxget_ctx () const
 
const GeometryMotionBlurSampleget_ray_motion_blur (const unsigned int &ray_index) const
 Get information about the motion blur sample used for a ray (filled by the raytracer)
 
Flags get_available_flag ()
 Get an unused flag.
 
Flags get_reserved_flags () const
 Get all flags that has been reserved manually.
 
Flags reserve_flags (const Flags &flags)
 Reserve several flags and returns flags that has been reserved successfully.
 
void release_flags (const Flags &flags)
 Release flags.
 
void release_all_flags ()
 Release all flags.
 

Friends

class CtxRaytracePool
 

Additional Inherited Members

- Public Types inherited from GeometryRaytraceData
enum  OpacityMode {
  OPACITY_ZERO = 0,
  OPACITY_FULL = 1,
  OPACITY_MATERIAL = 2
}
 Possible opacity modes. More...
 
enum  {
  HIT_NOTHING = 0,
  HIT_SOMETHING = 1,
  HIT_DEFERRED = 2
}
 Deprecated flags.
 
enum  {
  FLAG_NONE = 0,
  FLAG_HIT = 1 << 0,
  BUILTIN_FLAGS = FLAG_HIT
}
 Builtin flags.
 
typedef GeometryRaytraceCtx::Flags Flags
 
- Public Attributes inherited from GeometryRaytraceData
OpacityMode opacity_mode
 tell how to interpret the opacity of objects
 
bool process_matte_objects
 when true, the raytracing will consider matte objects has occluders
 
bool allow_deferring
 deprecated
 
unsigned int dimension
 first sampling dimension that can be used during the raytracing
 
GMathFrustumfrustum
 frustum containing the packet of rays (can be null)
 
GMathRayrays
 packet of rays to cast
 
unsigned int * seeds
 array of sampling seeds associated to each ray
 
unsigned int * ids
 array of sampling ids associated to each ray
 
double * tnear
 array of near clipping plane values for each ray
 
double * tfar
 array of far clipping plane values for each ray
 
GeometryIntersectionMapintersections
 pointer to the map holding the intersection results
 
union {
Flags * results
 deprecated
 
Flags * flags
 array of flags for each ray: used to tell if the ray has hit something but can be used to store additionnal information
 
}; 
 
unsigned int ray_count
 the number of rays in the packet
 
int first_ray
 the index of the first ray to process in the packet
 
int last_ray
 the index of the last ray to process in the packet
 

Member Function Documentation

void CtxRaytrace::init ( const unsigned int &  size,
const unsigned int &  sampling_seed = 0,
const unsigned int &  sampling_offset = 0,
const unsigned int &  sampling_dimension = 0 
)
inline

Initialize the context.

Parameters
[in]sizenumber of rays
[in]sampling_seedthe sampling seed used to generate rays
[in]sampling_offsetsample index to start from when assigning sample indices to each ray
[in]sampling_dimensionthe sampling dimension used to generate rays