Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | File List | Namespace Members | Class Members | File Members | Related Pages

sheep::Contact Class Reference

#include <contact.h>

List of all members.

Public Types

enum  Type { SEPARATING_CONTACT, RESTING_CONTACT, COLLIDING_CONTACT }

Public Member Functions

void Update ()
Type GetType ()
bool operator== (const Contact &c) const
void CancelNormalVelocity ()
Vector3 GetNormalDerivative () const

Public Attributes

RigidObjectm_a
RigidObjectm_b
Feature m_fa
Feature m_fb
Vector3 m_pa
Vector3 m_pb
Vector3 m_va
Vector3 m_vb
Vector3 m_n
bool m_inactivated


Member Enumeration Documentation

enum sheep::Contact::Type
 

Enumeration values:
SEPARATING_CONTACT 
RESTING_CONTACT 
COLLIDING_CONTACT 

Definition at line 53 of file contact.h.


Member Function Documentation

void Contact::CancelNormalVelocity  ) 
 

Definition at line 120 of file contact.cpp.

References sheep::RigidBody::ApplyAngularImpulse(), sheep::RigidBody::ApplyLinearImpulse(), sheep::RigidObject::GetBody(), sheep::RigidBody::GetMass(), sheep::RigidBody::GetWorldInertiaTensor(), sheep::Matrix3::Inverse(), sheep::RigidBody::IsFrozen(), m_a, m_n, m_pa, m_pb, m_va, m_vb, sheep::Real, sheep::RigidBody::TransformVectorToWorld(), and Update().

Referenced by sheep::RCTracker::ResolveAll().

Vector3 Contact::GetNormalDerivative  )  const
 

Definition at line 164 of file contact.cpp.

References sheep::RigidBody::GetAngularVelocity(), sheep::RigidObject::GetBody(), sheep::RigidObject::GetModel(), m_a, m_fa, m_fb, sheep::Feature::m_id0, sheep::Feature::m_id1, m_n, m_pa, sheep::Feature::m_type, sheep::RigidModel::m_vertices, sheep::Vector3::Norm(), sheep::Vector3::Normalized(), and sheep::RigidBody::TransformPointToWorld().

Referenced by sheep::RCTracker::compute_b_vector().

Contact::Type Contact::GetType  )  [inline]
 

Definition at line 96 of file contact.h.

Referenced by sheep::Subspace::find_contacts().

bool Contact::operator== const Contact c  )  const [inline]
 

Definition at line 112 of file contact.h.

void Contact::Update  ) 
 

Definition at line 33 of file contact.cpp.

References sheep::feq(), sheep::fnz(), sheep::RigidObject::GetBody(), sheep::RigidObject::GetModel(), sheep::RigidBody::GetPointVelocity(), sheep::RigidBody::GetPosition(), sheep::RigidModel::IsPointInTriangle(), m_a, m_fa, m_fb, sheep::Feature::m_id0, sheep::Feature::m_id1, m_inactivated, m_n, m_pa, m_pb, sheep::Feature::m_type, sheep::RigidModel::Face::m_v0, sheep::RigidModel::Face::m_v1, sheep::RigidModel::Face::m_v2, m_va, m_vb, sheep::RigidModel::m_vertices, sheep::Vector3::Norm(), sheep::Vector3::Normalized(), sheep::Real, sheep::Vector3::SquareNorm(), sheep::RigidBody::TransformPointToBody(), and sheep::RigidBody::TransformPointToWorld().

Referenced by CancelNormalVelocity(), sheep::Subspace::find_contacts(), sheep::RCTracker::is_inactivated_rc::operator()(), sheep::ContactHandler::resolve_col_contact(), and sheep::RCTracker::ResolveAll().


Member Data Documentation

RigidObject* sheep::Contact::m_a
 

Definition at line 41 of file contact.h.

Referenced by CancelNormalVelocity(), sheep::RCTracker::compute_A_matrix(), sheep::RCTracker::compute_b_vector(), sheep::Subspace::find_contacts(), sheep::SWIFTCollisionDetector::FindContacts(), GetNormalDerivative(), sheep::ContactHandler::resolve_col_contact(), sheep::RCTracker::ResolveAll(), and Update().

RigidObject * sheep::Contact::m_b
 

Definition at line 41 of file contact.h.

Referenced by sheep::RCTracker::compute_A_matrix(), sheep::RCTracker::compute_b_vector(), sheep::Subspace::find_contacts(), sheep::SWIFTCollisionDetector::FindContacts(), sheep::ContactHandler::resolve_col_contact(), and sheep::RCTracker::ResolveAll().

Feature sheep::Contact::m_fa
 

Definition at line 42 of file contact.h.

Referenced by sheep::Subspace::find_contacts(), sheep::SWIFTCollisionDetector::FindContacts(), GetNormalDerivative(), and Update().

Feature sheep::Contact::m_fb
 

Definition at line 42 of file contact.h.

Referenced by sheep::Subspace::find_contacts(), sheep::SWIFTCollisionDetector::FindContacts(), GetNormalDerivative(), and Update().

bool sheep::Contact::m_inactivated
 

Definition at line 51 of file contact.h.

Referenced by sheep::RCTracker::is_inactivated_rc::operator()(), and Update().

Vector3 sheep::Contact::m_n
 

Definition at line 48 of file contact.h.

Referenced by CancelNormalVelocity(), sheep::RCTracker::compute_A_matrix(), sheep::RCTracker::compute_b_vector(), GetNormalDerivative(), sheep::ContactHandler::resolve_col_contact(), sheep::RCTracker::ResolveAll(), and Update().

Vector3 sheep::Contact::m_pa
 

Definition at line 46 of file contact.h.

Referenced by CancelNormalVelocity(), sheep::RCTracker::compute_A_matrix(), sheep::RCTracker::compute_b_vector(), GetNormalDerivative(), sheep::ContactHandler::resolve_col_contact(), sheep::RCTracker::ResolveAll(), and Update().

Vector3 sheep::Contact::m_pb
 

Definition at line 46 of file contact.h.

Referenced by CancelNormalVelocity(), sheep::RCTracker::compute_A_matrix(), sheep::RCTracker::compute_b_vector(), sheep::ContactHandler::resolve_col_contact(), sheep::RCTracker::ResolveAll(), and Update().

Vector3 sheep::Contact::m_va
 

Definition at line 47 of file contact.h.

Referenced by CancelNormalVelocity(), sheep::RCTracker::compute_b_vector(), sheep::ContactHandler::resolve_col_contact(), sheep::RCTracker::ResolveAll(), and Update().

Vector3 sheep::Contact::m_vb
 

Definition at line 47 of file contact.h.

Referenced by CancelNormalVelocity(), sheep::RCTracker::compute_b_vector(), sheep::ContactHandler::resolve_col_contact(), sheep::RCTracker::ResolveAll(), and Update().


The documentation for this class was generated from the following files:
Generated on Tue May 11 01:31:55 2004 for toxic by doxygen 1.3.6