• Skip to content
  • Skip to link menu
KDE API Reference
  • KDE API Reference
  • kdeedu API Reference
  • KDE Home
  • Contact Us
 

step/stepcore

  • StepCore
  • CollisionSolver
Public Types | Public Member Functions | Protected Attributes | List of all members
StepCore::CollisionSolver Class Referenceabstract
Collision and constraint solvers

#include <collisionsolver.h>

Inheritance diagram for StepCore::CollisionSolver:
Inheritance graph
[legend]

Public Types

enum  { InternalError = Solver::CollisionError }
 

Public Member Functions

 CollisionSolver ()
 
virtual ~CollisionSolver ()
 
virtual void bodyAdded (BodyList &, Body *)
 
virtual void bodyRemoved (BodyList &, Body *)
 
virtual int checkContacts (BodyList &bodies, bool collisions=false, int *count=NULL)=0
 
virtual void getContactsInfo (ConstraintsInfo &info, bool collisions=false)=0
 
double localError () const
 
virtual void resetCaches ()
 
virtual void setToleranceAbs (double toleranceAbs)
 
virtual int solveCollisions (BodyList &bodies)=0
 
double toleranceAbs () const
 
- Public Member Functions inherited from StepCore::Object
 Object (const QString &name=QString())
 
virtual ~Object ()
 
const QString & name () const
 
void setName (const QString &name)
 

Protected Attributes

double _localError
 
double _toleranceAbs
 
- Protected Attributes inherited from StepCore::Object
QString _name
 

Detailed Description

Collision solver interface.

Provides generic interface for collision solvers.

Definition at line 85 of file collisionsolver.h.

Member Enumeration Documentation

anonymous enum
Enumerator
InternalError 

Definition at line 132 of file collisionsolver.h.

Constructor & Destructor Documentation

StepCore::CollisionSolver::CollisionSolver ( )
inline

Definition at line 90 of file collisionsolver.h.

virtual StepCore::CollisionSolver::~CollisionSolver ( )
inlinevirtual

Definition at line 91 of file collisionsolver.h.

Member Function Documentation

virtual void StepCore::CollisionSolver::bodyAdded ( BodyList &  ,
Body *   
)
inlinevirtual

Reimplemented in StepCore::GJKCollisionSolver.

Definition at line 128 of file collisionsolver.h.

virtual void StepCore::CollisionSolver::bodyRemoved ( BodyList &  ,
Body *   
)
inlinevirtual

Reimplemented in StepCore::GJKCollisionSolver.

Definition at line 129 of file collisionsolver.h.

virtual int StepCore::CollisionSolver::checkContacts ( BodyList &  bodies,
bool  collisions = false,
int *  count = NULL 
)
pure virtual

Check (and update) state of the contact.

Parameters
contactcontact to check (only body0 and body1 fields must be set)
Returns
state of the contact (equals to contact->state)Check and count contacts between several bodies
Parameters
bodieslist of bodies to check
countnumber of contacts
Returns
maximum contact state (i.e. maximum value of Contact::state)

Implemented in StepCore::GJKCollisionSolver.

virtual void StepCore::CollisionSolver::getContactsInfo ( ConstraintsInfo &  info,
bool  collisions = false 
)
pure virtual

Fill the constraint info structure with the contacts computed by checkContacts()

Parameters
infoConstraintsInfo structure to fill

Implemented in StepCore::GJKCollisionSolver.

double StepCore::CollisionSolver::localError ( ) const
inline

Get error estimation from last step.

Definition at line 98 of file collisionsolver.h.

virtual void StepCore::CollisionSolver::resetCaches ( )
inlinevirtual

Reset internal caches of collision information.

Todo:
do it automatically by checking the cache

Reimplemented in StepCore::GJKCollisionSolver.

Definition at line 126 of file collisionsolver.h.

virtual void StepCore::CollisionSolver::setToleranceAbs ( double  toleranceAbs)
inlinevirtual

Set absolute allowed tolerance.

Definition at line 96 of file collisionsolver.h.

virtual int StepCore::CollisionSolver::solveCollisions ( BodyList &  bodies)
pure virtual

Solve the collisions between bodies.

Implemented in StepCore::GJKCollisionSolver.

double StepCore::CollisionSolver::toleranceAbs ( ) const
inline

Get absolute allowed tolerance.

Definition at line 94 of file collisionsolver.h.

Member Data Documentation

double StepCore::CollisionSolver::_localError
protected

Definition at line 139 of file collisionsolver.h.

double StepCore::CollisionSolver::_toleranceAbs
protected

Definition at line 137 of file collisionsolver.h.


The documentation for this class was generated from the following file:
  • collisionsolver.h
This file is part of the KDE documentation.
Documentation copyright © 1996-2014 The KDE developers.
Generated on Tue Oct 14 2014 22:43:06 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

step/stepcore

Skip menu "step/stepcore"
  • Main Page
  • Namespace List
  • Namespace Members
  • Alphabetical List
  • Class List
  • Class Hierarchy
  • Class Members
  • File List
  • File Members
  • Modules
  • Related Pages

kdeedu API Reference

Skip menu "kdeedu API Reference"
  • Analitza
  •     lib
  • kalgebra
  • kalzium
  •   libscience
  • kanagram
  • kig
  •   lib
  • klettres
  • kstars
  • libkdeedu
  •   keduvocdocument
  • marble
  • parley
  • rocs
  •   App
  •   RocsCore
  •   VisualEditor
  •   stepcore

Search



Report problems with this website to our bug tracking system.
Contact the specific authors with questions and comments about the page contents.

KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal