Voxvision
1
Creating and manipulating voxel octrees
|
Algorithms for searching in tree. More...
#include "tree.h"
Go to the source code of this file.
Functions | |
VOX_EXPORT const struct vox_node * | vox_ray_tree_intersection (const struct vox_node *tree, const vox_dot origin, const vox_dot dir, vox_dot res) |
Find intersection of a tree and a ray. More... | |
VOX_EXPORT int | vox_tree_ball_collidep (const struct vox_node *tree, const vox_dot center, float radius) |
Find out if a ball collides with voxels in a tree. More... | |
Algorithms for searching in tree.
Searching for intersection with a ray and a tree and (maybe) other
VOX_EXPORT const struct vox_node* vox_ray_tree_intersection | ( | const struct vox_node * | tree, |
const vox_dot | origin, | ||
const vox_dot | dir, | ||
vox_dot | res | ||
) |
Find intersection of a tree and a ray.
tree | a tree |
origin | starting point of the ray |
dir | direction of the ray |
res | where result is stored |
VOX_EXPORT int vox_tree_ball_collidep | ( | const struct vox_node * | tree, |
const vox_dot | center, | ||
float | radius | ||
) |
Find out if a ball collides with voxels in a tree.
tree | the tree |
center | center of the ball |
radius | radius of the ball |