RayCastHit Class Reference

Raycast intersection class. More...

Public Attributes

real distance
 The distance from start at which the ray intersects the object.
 
wVector normal
 The normal at the hit point in the global frame of reference.
 
PhyObjectobject
 Object intersected by the ray.
 
wVector position
 The actual point at which the ray intersects the object in the global frame of reference.
 

Detailed Description

Raycast intersection class.

Motivation
an helper class with information about a raycast hit
Description
a list of objects of this type is returned by the World::worldRayCast() function. This class contains information about a RayCast hit: the object intersecting the ray, the distance from the ray start (normalized between 0 and 1), the actual point at which the ray hits the object and the normal at contact point

Definition at line 194 of file world.h.

Member Data Documentation

real distance

The distance from start at which the ray intersects the object.

This is in the range [0; 1]: 0 means the ray start point, 1 the ray end point. Intermediate values correspond to values along the ray

Definition at line 201 of file world.h.

Referenced by SingleIR::set(), SingleIR::SingleIR(), and SingleIR::update().

wVector normal

The normal at the hit point in the global frame of reference.

Definition at line 206 of file world.h.

PhyObject* object

Object intersected by the ray.

Definition at line 197 of file world.h.

Referenced by SingleIR::set(), SingleIR::SingleIR(), and SingleIR::update().

wVector position

The actual point at which the ray intersects the object in the global frame of reference.

Definition at line 204 of file world.h.


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