31 #ifndef PX_PHYSICS_PX_BASE 32 #define PX_PHYSICS_PX_BASE 58 eOWNS_MEMORY = (1<<0),
59 eIS_RELEASABLE = (1<<1)
85 virtual void release() = 0;
91 virtual const char* getConcreteTypeName()
const = 0;
101 template<
class T> T*
is() {
return typeMatch<T>() ? static_cast<T*>(
this) : NULL; }
111 template<
class T>
const T*
is()
const {
return typeMatch<T>() ? static_cast<const T*>(
this) : NULL; }
163 : mConcreteType(concreteType), mBaseFlags(baseFlags) {}
178 virtual bool isKindOf(
const char* superClass)
const {
return !::strcmp(superClass,
"PxBase"); }
Definition: GuContactBuffer.h:37
a structure containing per-type information for types inheriting from PxBase
Definition: PxTypeInfo.h:89
#define PX_FORCE_INLINE
Definition: PxPreprocessor.h:364
bool typeMatch() const
Definition: PxBase.h:180
virtual bool isKindOf(const char *superClass) const
Returns whether a given type name matches with the type of this instance.
Definition: PxBase.h:178
uint32_t PxU32
Definition: PxSimpleTypes.h:71
virtual ~PxBase()
Destructor.
Definition: PxBase.h:173
PX_FORCE_INLINE void setBaseFlags(PxBaseFlags inFlags)
Set PxBaseFlags.
Definition: PxBase.h:136
PxU16 PxType
Definition: PxBase.h:49
Output stream class for I/O.
Definition: PxIO.h:114
PxType mConcreteType
Definition: PxBase.h:191
PX_FORCE_INLINE PxBaseFlags getBaseFlags() const
Returns PxBaseFlags.
Definition: PxBase.h:145
PX_FORCE_INLINE void setBaseFlag(PxBaseFlag::Enum flag, bool value)
Set PxBaseFlag.
Definition: PxBase.h:127
Flags for PxBase.
Definition: PxBase.h:54
Enum
Definition: PxBase.h:56
const T * is() const
Definition: PxBase.h:111
PX_INLINE PxBase(PxType concreteType, PxBaseFlags baseFlags)
Constructor setting concrete type and base flags.
Definition: PxBase.h:162
T * is()
Definition: PxBase.h:101
PxBaseFlags mBaseFlags
Definition: PxBase.h:192
PxFlags< PxBaseFlag::Enum, PxU16 > PxBaseFlags
Definition: PxBase.h:63
PX_INLINE PxBase(PxBaseFlags baseFlags)
Deserialization constructor setting base flags.
Definition: PxBase.h:168
uint16_t PxU16
Definition: PxSimpleTypes.h:73
Base class for objects that can be members of a PxCollection.
Definition: PxBase.h:73
Definition: PxTypeInfo.h:57
PX_FORCE_INLINE PxType getConcreteType() const
Returns concrete type of object.
Definition: PxBase.h:119
#define PX_INLINE
Definition: PxPreprocessor.h:349
virtual bool isReleasable() const
Whether the object is subordinate.
Definition: PxBase.h:156