VRENDER_COLLECT_RAY(3)

FUNCTION
vrender_collect_ray - Collect a ray projected from an image plane into a volume.

SYNOPSIS
#include <karma_vrender.h>

CONST signed char * vrender_collect_ray

(KVolumeRenderContext context, unsigned int eye_view, Kcoord_2d pos_2d, Kcoord_3d *ray_start, Kcoord_3d *direction, float *t_enter, float *t_leave, unsigned int *ray_length)

DESCRIPTION
Collect a ray projected from an image plane into a volume.

context
    The volume rendering context. This specifies the volume and view information.

eye_view
    The eye which sees the ray. See <-vrender_EYES-> for a list of legal values.

pos_2d
    The 2-dimensional position in the image plane to project from.

ray_start
    The 3-dimensional position of the starting point of the ray is written here. This point lies on the raster plane.

direction
    The 3-dimensional direction vector of the ray is written here. This is not normalised.

t_enter
    The distance down the ray corresponding to the first voxel is written here.

t_leave
    The distance down the ray corresponding to the last voxel is written here.

ray_length
    The length of the ray through the volume is written here. If the ray does not intersect the volume, 0 is written here.

RETURN VALUE
A pointer to the collected ray. This is a statically allocated array per context which is updated on each call. On error NULL is returned.

Multi-threading Level
Unsafe per context.

AUTHOR
Richard Gooch (rgooch@atnf.csiro.au)

AVAILABLITY
The Karma Distribution is available for anonymous ftp from: ftp://ftp.atnf.csiro.au/pub/software/karma/ ftp://wuarchive.wustl.edu/graphics/graphics/packages/karma/ ftp://ftp.pwr.wroc.pl/pub/karma/ The Karma Home Page is: http://www.atnf.csiro.au/karma/