My Project

#include <rayCone.h>
Public Member Functions  
int  read (FILE *fp, int *materialIndex) 
void  write (int indent, FILE *fp=stdout) 
double  intersect (Ray3D ray, struct RayIntersectionInfo &iInfo, double mx=1) 
BoundingBox3D  setBoundingBox (void) 
void  setUpOpenGL (int cplx) 
int  drawOpenGL (int materialIndex) 
Public Member Functions inherited from RayShape  
virtual int  isStatic (void) 
Public Attributes  
Point3D  center 
double  height 
double  radius 
class RayMaterial *  material 
Public Attributes inherited from RayShape  
BoundingBox3D  bBox 
int  openGLComplexity 
This class represents a cone whose central axis isparallel to the yaxis, and is defined by the center of the cone, the height from the tip to the base and the base of the cone.

virtual 
This method calls the necessary OpenGL commands to render the primitive.
Implements RayShape.

virtual 
This method computes the intersection of the shape with the ray. If the ray hits the shape and either mx is less than zero or the intersection occurs at a distance less than mx along the ray the intersection information in iInfo is set and a value greater than 0 is returned. Otherwise, 1 is returned. (This is useful for shadow testing when you may want to ignore hits beyond a certain distance).
Implements RayShape.
int RayCone::read  (  FILE *  fp, 
int *  materialIndex  
) 
This method reads in a RayCone from a .ray file. A pointer to the material associated to the triangle is set.

virtual 
This method sets and returns a bounding box containing the shape.
Implements RayShape.

virtual 
This method sets up all the stuff that's necessary prior to OpenGL rendering. The value cplx represents the desired resolution of tessalation for objects such as spheres, cylinders, etc..
Implements RayShape.

virtual 
Point3D RayCone::center 
The center of the cylinder
double RayCone::height 
The height of the cylinder
class RayMaterial* RayCone::material 
The material associated with the cylinder
double RayCone::radius 
The radius of the cylinder