Main Page | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Class Members | File Members | Related Pages

vtkRayCastStructures.h

Go to the documentation of this file.
00001 /*=========================================================================
00002 
00003   Program:   Visualization Toolkit
00004   Module:    $RCSfile: vtkRayCastStructures.h,v $
00005 
00006   Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
00007   All rights reserved.
00008   See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
00009 
00010      This software is distributed WITHOUT ANY WARRANTY; without even
00011      the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
00012      PURPOSE.  See the above copyright notice for more information.
00013 
00014 =========================================================================*/
00015 
00026 #ifndef __vtkRayCastStructures_h
00027 #define __vtkRayCastStructures_h
00028 
00029 typedef struct 
00030 {
00031   // These are the input values that define the ray. Depending on
00032   // whether we are casting a WorldRay or a ViewRay, these are in
00033   // world coordinates or view coordinates.
00034   float Origin[3];
00035   float Direction[3];
00036 
00037   // The pixel location for the ray that is being cast can be
00038   // important, for example if hardware ray bounding is being used
00039   // and the location in the depth buffer must be matched to this
00040   // ray.
00041   int   Pixel[2];
00042 
00043   // The world coordinate location of the camera is important for the
00044   // ray caster to be able to return a Z value for the intersection
00045   float CameraPosition[3];
00046 
00047   // This input value defines the size of the image
00048   int   ImageSize[2];
00049 
00050   // These are input values for clipping but may be changed
00051   // along the way
00052   float NearClip;
00053   float FarClip;
00054 
00055   // These are the return values - RGBA and Z
00056   float Color[4];
00057   float Depth;
00058 
00059 
00060   // Some additional space that may be useful for the
00061   // specific implementation of the ray caster. This structure
00062   // is a convenient place to put it, since there is one
00063   // per thread so that writing to these locations is safe
00064 
00065   // Ray information transformed into local coordinates
00066   float                        TransformedStart[4];
00067   float                        TransformedEnd[4];
00068   float                        TransformedDirection[4];
00069   float                        TransformedIncrement[3];
00070   
00071   // The number of steps we want to take if this is
00072   // a ray caster that takes steps
00073   int                          NumberOfStepsToTake;
00074   
00075   // The number of steps we actually take if this is
00076   // a ray caster that takes steps
00077   int                          NumberOfStepsTaken;
00078 
00079 } vtkRayCastRayInfo;
00080 
00081 #endif

Generated on Mon Jan 21 23:07:17 2008 for VTK by  doxygen 1.4.3-20050530