Clarisse 5.0 SP8 SDK  5.0.5.8.0
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
Public Types | Public Member Functions | Static Public Member Functions | Protected Member Functions | Friends | List of all members
GasTree Class Reference
Inheritance diagram for GasTree:
GasUvTree

Public Types

typedef void(* LeafRayHitCallback )(void *data, const unsigned int &index, const CtxEval &eval_ctx, CtxShader &shader_ctx, GeometryRaytraceCtx &raytrace_ctx)
 
typedef void(* LeafFrustumHitCallback )(void *data, const unsigned int &index, const CtxEval &eval_ctx, CtxShader &shader_ctx, GeometryFrustumCtx &frustum_ctx)
 
typedef void(* LeafRayFrustumHitCallback )(void *data, const unsigned int &index, const CtxEval &eval_ctx, CtxShader &shader_ctx, GeometryRayFrustumCtx &ray_frustum_ctx)
 
typedef void(* SplitCallback )(const GasTreeSplitContext &ctx, unsigned int *ids, unsigned int count, unsigned int &split_index)
 

Public Member Functions

void create (const CoreBasicArray< GMathBbox3d > &bboxes, AppProgressBar *progress_bar=0)
 
void create (const CoreBasicArray< GMathBbox3f > &bboxes, AppProgressBar *progress_bar=0)
 
void create (const CoreBasicArray< GMathBbox3d > &bboxes, const CoreBasicArray< unsigned int > &bbox_indices, AppProgressBar *progress_bar=0)
 
void create (const CoreBasicArray< GMathBbox3f > &bboxes, const CoreBasicArray< unsigned int > &bbox_indices, AppProgressBar *progress_bar=0)
 
void create (const GMathBbox3f *bboxes, const unsigned int &bbox_count, AppProgressBar *progress_bar=0)
 
void create (const GMathBbox3f *bboxes, const unsigned int *bbox_indices, const unsigned int &index_count, AppProgressBar *progress_bar=0)
 
void set_leaf_indices (const unsigned int *indices)
 
CoreBasicArray< unsigned int > get_leaf_indices () const
 
bool refit (const CoreBasicArray< GMathBbox3f > &bboxes)
 
bool refit (const CoreBasicArray< GMathBbox3f > &bboxes, const CoreBasicArray< unsigned int > &bbox_indices)
 
bool is_empty () const
 
const unsigned int & get_leaf_count () const
 
const unsigned int & get_node_count () const
 
const unsigned int & get_depth () const
 
unsigned int get_leaf_index (const unsigned int &index) const
 
GMathBbox3f get_bbox () const
 
void get_leaf_bboxes (GMathBbox3f *bboxes) const
 
void get_leaf_bboxes (CoreArray< GMathBbox3f > &bboxes) const
 
void get_node_bboxes (const CoreBasicArray< unsigned int > &indices, GMathBbox3f *bboxes) const
 
void get_node_bbox (const unsigned int &index, GMathBbox3f &bbox) const
 
void get_node_bbox (const unsigned int &index, SimdF &bbox_min, SimdF &bbox_max) const
 
void get_node_children (const unsigned int &index, unsigned int &left_index, unsigned int &right_index) const
 
bool is_node_a_leaf (const unsigned int &index) const
 
unsigned int get_leaf_value (const unsigned int &index) const
 
void clear ()
 
virtual size_t get_memory_size () const
 
void print () const
 
void get_node_coverages (CoreArray< GMathVec4f > &coverages) const
 
void get_clusters (CoreVector< void * > &clusters, const unsigned int &max_cluster_count, const float &min_cluster_coverage) const
 
void get_clusters_bboxes (const CoreBasicArray< void * > &clusters, GMathBbox3f *bboxes) const
 
void get_island_nodes (CoreVector< unsigned int > &node_indices, const float &min_coverage) const
 
void get_leaves_indices (const unsigned int &node_index, CoreVector< unsigned int > &leaves_indices) const
 
void set_split_callback (SplitCallback callback)
 
void set_leaf_raytrace_callbacks (LeafRayHitCallback ray_hit_callback, LeafRayHitCallback ray_hit_nearest_callback, void *data)
 
void set_leaf_ray_frustum_callback (LeafRayFrustumHitCallback ray_frustum_hit_callback, void *data)
 
void set_leaf_frustum_callback (LeafFrustumHitCallback frustum_hit_callback, void *data)
 
void ray_hit (const CtxEval &eval_ctx, CtxShader &shader_ctx, GeometryRaytraceCtx &raytrace_ctx, const bool &use_shortcut=true) const
 
void ray_hit_nearest (const CtxEval &eval_ctx, CtxShader &shader_ctx, GeometryRaytraceCtx &raytrace_ctx, const bool &use_shortcut=true) const
 
void frustum_hit (const CtxEval &eval_ctx, CtxShader &shader_ctx, GeometryFrustumCtx &frustum_ctx, const bool &use_shortcut=true) const
 
void ray_frustum_hit (const CtxEval &eval_ctx, CtxShader &shader_ctx, GeometryRayFrustumCtx &ray_frustum_ctx, const bool &use_shortcut=true) const
 
void get_leaves_in_bbox (GasTreeCtx &tree_ctx, const GMathBbox3f &bbox, CoreVector< unsigned int > &leaves) const
 
unsigned int get_nearest_leaves (GasTreeCtx &tree_ctx, const GMathVec3f &position, const float &max_distance, const unsigned int &max_count, unsigned int *leaves, float *distances) const
 

Static Public Member Functions

static void split_sah_bins (const GasTreeSplitContext &ctx, unsigned int *ids, unsigned int count, unsigned int &split_index)
 
static void split_sah_bins_fast (const GasTreeSplitContext &ctx, unsigned int *ids, unsigned int count, unsigned int &split_index)
 
static void split_median (const GasTreeSplitContext &ctx, unsigned int *ids, unsigned int count, unsigned int &split_index)
 
static void split_hybrid (const GasTreeSplitContext &ctx, unsigned int *ids, unsigned int count, unsigned int &split_index)
 

Protected Member Functions

void ray_hit_extent (const CtxEval &eval_ctx, CtxShader &shader_ctx, GeometryRaytraceCtx &raytrace_ctx) const
 
void ray_hit_extent (const CtxEval &eval_ctx, CtxShader &shader_ctx, GeometryRaytraceCtx &raytrace_ctx, void *user_data) const
 

Friends

class GasTreeRaytracer< GasTree >
 
class GasTreeMotion