NL3D::UVisualCollisionManager Class Reference

#include <u_visual_collision_manager.h>

Inheritance diagram for NL3D::UVisualCollisionManager:

NL3D::CVisualCollisionManagerUser

Detailed Description

Interface to visual collision manager.
Author:
Lionel Berenguier

Nevrax France

Date:
2001

Definition at line 47 of file u_visual_collision_manager.h.

Public Member Functions

virtual uint addMeshCollision (const std::vector< CVector > &vertices, const std::vector< uint16 > &triangles)=0
virtual UVisualCollisionEntitycreateEntity ()=0
virtual void deleteEntity (UVisualCollisionEntity *entity)=0
virtual float getCameraCollision (const CVector &start, const CVector &end, float radius, bool cone)=0
virtual void removeMeshCollision (uint id)=0
virtual void setLandscape (ULandscape *landscape)=0
virtual void setSunContributionPower (float power, float maxThreshold)=0

Protected Member Functions

 UVisualCollisionManager ()
virtual ~UVisualCollisionManager ()


Constructor & Destructor Documentation

NL3D::UVisualCollisionManager::UVisualCollisionManager  )  [inline, protected]
 

Definition at line 50 of file u_visual_collision_manager.h.

00050 {}

virtual NL3D::UVisualCollisionManager::~UVisualCollisionManager  )  [inline, protected, virtual]
 

Definition at line 51 of file u_visual_collision_manager.h.

00051 {}


Member Function Documentation

virtual uint NL3D::UVisualCollisionManager::addMeshCollision const std::vector< CVector > &  vertices,
const std::vector< uint16 > &  triangles
[pure virtual]
 

Add a Mesh to the collision manager. For now it is used only for Camera Collision number of vertices and number of triangles must not exceed 65535

Returns:
the id used for remove, 0 if not succeed

Implemented in NL3D::CVisualCollisionManagerUser.

virtual UVisualCollisionEntity* NL3D::UVisualCollisionManager::createEntity  )  [pure virtual]
 

create an entity. NB: CVisualCollisionManager owns this ptr, and you must delete it with deleteEntity(). NB: all CVisualCollisionEntity are deleted when this manager is deleted.

Implemented in NL3D::CVisualCollisionManagerUser.

virtual void NL3D::UVisualCollisionManager::deleteEntity UVisualCollisionEntity entity  )  [pure virtual]
 

delete an entity.

Implemented in NL3D::CVisualCollisionManagerUser.

virtual float NL3D::UVisualCollisionManager::getCameraCollision const CVector start,
const CVector end,
float  radius,
bool  cone
[pure virtual]
 

Get Typical Camera 3rd person collision. For landscape, it is done only against TileFaces (ie only under approx 50 m) return a [0,1] value. 0 => collision at start. 1 => no collision.

Parameters:
radius is the radius of the 'cylinder'
cone if true, the object tested is a cone (radius goes to end)

Implemented in NL3D::CVisualCollisionManagerUser.

virtual void NL3D::UVisualCollisionManager::removeMeshCollision uint  id  )  [pure virtual]
 

Remove a Mesh from the collision manager.

Implemented in NL3D::CVisualCollisionManagerUser.

virtual void NL3D::UVisualCollisionManager::setLandscape ULandscape landscape  )  [pure virtual]
 

setup the landscape used for this collision manager. ptr is kept, and manager must be cleared when the landscape is deleted.

Implemented in NL3D::CVisualCollisionManagerUser.

virtual void NL3D::UVisualCollisionManager::setSunContributionPower float  power,
float  maxThreshold
[pure virtual]
 

Build a lighting table to remap sun contribution from landscape to sun contribution for objects. The value remap the landscape sun contribution (0 ~ 1) to an object sun contribution (0 ~1) using the following formula:

objectSunContribution = min ( powf ( landscapeSunContribution / maxThreshold, power ), 1 );

Default is 0.5 (=> sqrt) for power and 0.5 for maxThreshold.

Implemented in NL3D::CVisualCollisionManagerUser.


The documentation for this class was generated from the following file:
Generated on Tue Mar 16 08:53:31 2004 for NeL by doxygen 1.3.6