void TA::Physics::TestLineForCollision
(
|
const Vec3 &
|
v3Start,
|
|
const Vec3 &
|
v3Normal,
|
|
float
|
fLength,
|
|
Collision &
|
collision,
|
|
u32
|
nFlags
|
) |
|
|
|
Call this function to test a line segment for intersection with all geometry added to the physics simulation. The line is represented by a start point, a normalised direction and a length. Only the closest found intersection is returned. Call TA::Collision::CollisionOccurred to determine if an intersection was found. - Note:
- note that axis aligned line segments are generally more efficient.
- See also:
- TA::Physics::TestLineForCollision(const Vec3& v3Start, const Vec3& v3End, Collision& collision, u32 nFlags).
- Parameters:
-
| collision |
| | A collision object where to store the result. The contents of collision will be overwritten. |
| v3Start |
| | The start point of the line. |
| v3Normal |
| | The direction of the line as a normalised TA::Vec3. |
| fLength |
| | The length of the line. |
| nFlags |
| | Either a combination of FLAG_DYNAMIC_OBJECTS, FLAG_STATIC_OBJECTS, or one of FLAG_ALL_OBJECTS and FLAG_ALL_NON_DYNAMIC_OBJECTS. |
|
|