Panda3D
Public Member Functions | Static Public Member Functions
PhysxContactPair Class Reference

An instance of this class is send with contact reporting events. More...

#include "physxContactPair.h"

Inheritance diagram for PhysxContactPair:
TypedReferenceCount TypedObject ReferenceCount MemoryBase MemoryBase

List of all members.

Public Member Functions

 PhysxContactPair (const NxContactPair pair)
virtual TypeHandle force_init_type ()
PhysxActorget_actor_a () const
 Returns the first of the two actors that makes up this pair.
PhysxActorget_actor_b () const
 Returns the second of the two actors that make up his pair.
PhysxContactPoint get_contact_point (unsigned int idx) const
 Returns an instance of PhysxContactPoint, which represents a single entry of this pair's contact stream.
unsigned int get_num_contact_points ()
 Returns the total number of contact points reported in this pair's contact stream.
LVector3f get_sum_friction_force () const
 Returns the total tangential force that was applied for this pair.
LVector3f get_sum_normal_force () const
 Returns the total contact normal force that was applied for this pair, to maintain nonpenetration constraints.
virtual TypeHandle get_type () const
bool is_deleted_a () const
 Returns true if the first of the two actors is deleted.
bool is_deleted_b () const
 Returns true if the second of the two actors is deleted.
 MAKE_SEQ (get_contact_points, get_num_contact_points, get_contact_point)

Static Public Member Functions

static TypeHandle get_class_type ()
static void init_type ()
 This function is declared non-inline to work around a compiler bug in g++ 2.96.

Detailed Description

An instance of this class is send with contact reporting events.

It contains detailed information on the contact.

Definition at line 34 of file physxContactPair.h.


Member Function Documentation

Returns the first of the two actors that makes up this pair.

Definition at line 29 of file physxContactPair.cxx.

Returns the second of the two actors that make up his pair.

Definition at line 47 of file physxContactPair.cxx.

Returns an instance of PhysxContactPoint, which represents a single entry of this pair's contact stream.

This method is a helper for iterating over the pair's contact stream.

Definition at line 158 of file physxContactPair.cxx.

Returns the total number of contact points reported in this pair's contact stream.

This method is a helper for iterating over the pair's contact stream.

Definition at line 129 of file physxContactPair.cxx.

Returns the total tangential force that was applied for this pair.

You should set the ContactPairFlag CPF_notify_forces in order to receive this value.

See also:
PhysxScene::set_actor_pair_flag
PhysxScene::set_actor_group_pair_flag

Definition at line 114 of file physxContactPair.cxx.

References PhysxManager::nxVec3_to_vec3().

Returns the total contact normal force that was applied for this pair, to maintain nonpenetration constraints.

You should set the ContactPairFlag CPF_notify_forces in order to receive this value.

See also:
PhysxScene::set_actor_pair_flag
PhysxScene::set_actor_group_pair_flag

Definition at line 96 of file physxContactPair.cxx.

References PhysxManager::nxVec3_to_vec3().

static void PhysxContactPair::init_type ( ) [inline, static]

This function is declared non-inline to work around a compiler bug in g++ 2.96.

Making it inline seems to cause problems in the optimizer.

Reimplemented from TypedReferenceCount.

Definition at line 62 of file physxContactPair.h.

References TypedReferenceCount::init_type().

Returns true if the first of the two actors is deleted.

Definition at line 65 of file physxContactPair.cxx.

Returns true if the second of the two actors is deleted.

Definition at line 77 of file physxContactPair.cxx.


The documentation for this class was generated from the following files:
 All Classes Functions Variables Enumerations