1#ifndef BulletWorldManager_h
2#define BulletWorldManager_h
12#include <QScopedPointer>
16#include "IsisBullet.h"
17#include "BulletTargetShape.h"\
54 bool raycast(
const btVector3 &observer,
const btVector3 &lookdir,
55 btCollisionWorld::RayResultCallback &hits )
const;
57 const btCollisionWorld &
getWorld()
const;
Bullet Target Shape for planetary bodies.
Bullet World manager maintains a proper state for target bodies.
bool raycast(const btVector3 &observer, const btVector3 &lookdir, btCollisionWorld::RayResultCallback &hits) const
Perform ray casting from a position and a look direction.
QScopedPointer< btCollisionWorld > m_world
! The interface for overlaps in the world's aabb acceleration tree.
void addTarget(BulletTargetShape *target)
Add a Bullet shape to the collision world.
virtual ~BulletWorldManager()
Destroys the BulletWorldManager.
void initWorld()
Initialize the collision world for object ray tracing.
QScopedPointer< btCollisionDispatcher > m_dispatcher
! The collision configuration for the world.
QMutex m_mutex
! The Bullet collision world that contains the representation of the body.
QString name() const
Name of the world.
QScopedPointer< btDefaultCollisionConfiguration > m_collision
! The name of the Bullet world.
BulletTargetShape * getTarget(const int &index=0) const
Return a collision object by index into the world.
const btCollisionWorld & getWorld() const
Get the Collision World where the targets exist.
QScopedPointer< btBroadphaseInterface > m_broadphase
! The dispatcher for the world.
BulletWorldManager()
Default empty constructor.
int size() const
Number of collision objects in the world.
This is free and unencumbered software released into the public domain.