Powertek.Rt.PtRtTriangle Class Reference

PtRtTriangle, Triangle Primitive. More...

Collaboration diagram for Powertek.Rt.PtRtTriangle:

Collaboration graph
[legend]

List of all members.

Public Member Functions

object Clone ()
 PtRtTriangle ()
void InitData (Vertex3f vertex1, Vertex3f vertex2, Vertex3f vertex3, Vertex3f normal1, Vertex3f normal2, Vertex3f normal3, bool isGLData)
void InitData (Vertex3f vertex1, Vertex3f vertex2, Vertex3f vertex3, Vertex2f uv1, Vertex2f uv2, Vertex2f uv3, bool isGLData)
void InitData (Vertex3f vertex1, Vertex3f vertex2, Vertex3f vertex3, Vertex2f uv1, Vertex2f uv2, Vertex2f uv3, Vertex3f normal1, Vertex3f normal2, Vertex3f normal3, bool isGLData)
void CalcBoundingBox ()
Vertex3f GetFaceNormal ()
Vertex3f GetNormal (ref PtRay ray, ref IntersectionInfo info, bool useSmoothing)
PtIntersectionType Intersect (PtRay ray, ref IntersectionInfo info, PtIntersectionMode mode)
void CalcAndAssignNormalsAndUV (ref PtRay ray, ref IntersectionInfo info, bool enableSmoothFaceNormal)
void AssignNormalAndUV (PtRay ray, IntersectionInfo info, bool enableSmoothFaceNormal)
void AssignUV (PtRay ray, IntersectionInfo info, bool enableSmoothFaceNormal)
bool IsLightFacing (ref Vertex3f light)
void IntersectGL (PtRay ray, ref IntersectionInfo info)
void Render ()
void RenderLine ()
void RenderWithMat (bool enableSmoothFaceNormal)
void RenderForSelection ()

Public Attributes

Vertex3f V0
Vertex2f UV0
Vertex3f FaceNormal
Vertex3f N0
bool hasUvs = false
bool hasNormal = false
bool isSmoothed = false
Byte selColorR = 0
Byte selColorG = 0
Byte selColorB = 0
int MatID = 0
int ID = 0
int subBBID = -1
PtBoundingBoxRts bb = null

Static Public Attributes

static float EPSILON = 0.00001f


Detailed Description


Constructor & Destructor Documentation

Powertek.Rt.PtRtTriangle.PtRtTriangle (  ) 


Member Function Documentation

void Powertek.Rt.PtRtTriangle.AssignNormalAndUV ( PtRay  ray,
IntersectionInfo  info,
bool  enableSmoothFaceNormal 
)

Calculate and Assign the Normals and UV Coords at the info.IntersectionPoint, use this, if intersection was already calculated for this tri.

Parameters:
ray 
info 
enableSmoothFaceNormal 

void Powertek.Rt.PtRtTriangle.AssignUV ( PtRay  ray,
IntersectionInfo  info,
bool  enableSmoothFaceNormal 
)

Assign the UV Coords at the info.IntersectionPoint, info.Mu and info.Mv must be already assigned.

Parameters:
ray 
info 
enableSmoothFaceNormal 

void Powertek.Rt.PtRtTriangle.CalcAndAssignNormalsAndUV ( ref PtRay  ray,
ref IntersectionInfo  info,
bool  enableSmoothFaceNormal 
)

Calculate and Assign the Normals and UV Coords at the info.IntersectionPoint.

Parameters:
ray 
info 
enableSmoothFaceNormal 

void Powertek.Rt.PtRtTriangle.CalcBoundingBox (  ) 

CalcBoundingBox.

object Powertek.Rt.PtRtTriangle.Clone (  ) 

Clone Object.

Returns:

Vertex3f Powertek.Rt.PtRtTriangle.GetFaceNormal (  ) 

Return Face Normal.

Returns:

Vertex3f Powertek.Rt.PtRtTriangle.GetNormal ( ref PtRay  ray,
ref IntersectionInfo  info,
bool  useSmoothing 
)

Return Normal at info.IntersectionPoint, info mU and mV must be already assigned.

Parameters:
ray 
info 
useSmoothing 
Returns:

void Powertek.Rt.PtRtTriangle.InitData ( Vertex3f  vertex1,
Vertex3f  vertex2,
Vertex3f  vertex3,
Vertex2f  uv1,
Vertex2f  uv2,
Vertex2f  uv3,
Vertex3f  normal1,
Vertex3f  normal2,
Vertex3f  normal3,
bool  isGLData 
)

InitData.

Parameters:
vertex1 
vertex2 
vertex3 
uv1 
uv2 
uv3 
normal1 
normal2 
normal3 
isGLData 

void Powertek.Rt.PtRtTriangle.InitData ( Vertex3f  vertex1,
Vertex3f  vertex2,
Vertex3f  vertex3,
Vertex2f  uv1,
Vertex2f  uv2,
Vertex2f  uv3,
bool  isGLData 
)

InitData.

Parameters:
vertex1 
vertex2 
vertex3 
uv1 
uv2 
uv3 
isGLData 

void Powertek.Rt.PtRtTriangle.InitData ( Vertex3f  vertex1,
Vertex3f  vertex2,
Vertex3f  vertex3,
Vertex3f  normal1,
Vertex3f  normal2,
Vertex3f  normal3,
bool  isGLData 
)

InitData.

Parameters:
vertex1 
vertex2 
vertex3 
normal1 
normal2 
normal3 
isGLData 

PtIntersectionType Powertek.Rt.PtRtTriangle.Intersect ( PtRay  ray,
ref IntersectionInfo  info,
PtIntersectionMode  mode 
)

Intersect with ray.

Parameters:
ray 
info 
mode 
Returns:

void Powertek.Rt.PtRtTriangle.IntersectGL ( PtRay  ray,
ref IntersectionInfo  info 
)

Intersect Helper for GL Acceleration, we know already that we have a intersect, so only calc the distance, and the tri helper.

Parameters:
ray 
info 

bool Powertek.Rt.PtRtTriangle.IsLightFacing ( ref Vertex3f  light  ) 

Check if the Triangle Faces the light.

Parameters:
light 
Returns:

void Powertek.Rt.PtRtTriangle.Render (  ) 

Render Triangle with OpenGL.

void Powertek.Rt.PtRtTriangle.RenderForSelection (  ) 

Render Triangle with selection color.

void Powertek.Rt.PtRtTriangle.RenderLine (  ) 

Render Triangle as LineStrip with OpenGL.

void Powertek.Rt.PtRtTriangle.RenderWithMat ( bool  enableSmoothFaceNormal  ) 

Render Triangle with Texture or material.

Parameters:
enableSmoothFaceNormal 


Member Data Documentation

Helper BB.

float Powertek.Rt.PtRtTriangle.EPSILON = 0.00001f [static]

EPSILON.

FaceNormal.

has assigned Normal

has Uv Coords

Triangle ID.

Has a smoothed Normal.

Material ID of this Triangle.

Edge Normals.

Selection Color B.

Selection Color G.

Selection Color R.

subBBID

Edge UV Coords.

Edge Vertices.


The documentation for this class was generated from the following file:

Generated on Thu Nov 20 04:45:49 2008 for Powertek.Rt, 1.0.0.60 by  doxygen 1.5.7.1