Public Attributes

ISect Struct Reference

Search for all occurrences

Detailed Description

See also:
Class RenderGlobalContext, Class RenderInstance, Class ISectList.
Remarks:
This structure is available in release 2.0 and later only.
This structure is updated by the RenderGlobalContext::IntersectWorld() and RenderGlobalContext::IntersectRay() methods. It stores information about the intersection of a ray and a single triangle in a mesh.

#include <imtl.h>

Inheritance diagram for ISect:
Inheritance graph
[legend]

List of all members.

Public Attributes

float  t
  The ray that was intersected has a unit vector specifying a direction.
BOOL  exit
  TRUE if the ray is exiting the object; otherwise FALSE.
BOOL  backFace
  TRUE if the ray hits a back face of the triangle; otherwise FALSE.
RenderInstance inst
  Points to the render instance associated with this triangle hit.
int  fnum
  The face number of the triangle.
Point3  bc
  The barycentric coordinates of the intersection.
Point3  p
  The intersection point in object coordinates.
Point3  pc
  The intersection point in camera coordinates.
ULONG  matreq
  The material requirements of the intersected face.
int  mtlNum
  The material number for a multi-material.
ISect next
  Points to the next ISect structure in the list.

Member Data Documentation

float t

The ray that was intersected has a unit vector specifying a direction.

The ray defines an infinite line in the specified direction. If you take this value t and multiply it by the direction itself it gives a point on the ray. This specifies a distance along the vector. For instance if this way 5.0, the point would 5.0 units along the ray vector. This is the point of intersection along the ray.

BOOL exit

TRUE if the ray is exiting the object; otherwise FALSE.

BOOL backFace

TRUE if the ray hits a back face of the triangle; otherwise FALSE.

Points to the render instance associated with this triangle hit.

int fnum

The face number of the triangle.

The barycentric coordinates of the intersection.

The intersection point in object coordinates.

The intersection point in camera coordinates.

ULONG matreq

The material requirements of the intersected face.

See Material Requirements Flags.

int mtlNum

The material number for a multi-material.

Points to the next ISect structure in the list.