PxBroadcast
Defined in include/foundation/PxBroadcast.h
Inheritance Relationships
Base Type
public Base
-
template<class Listener, class Base>
class PxBroadcast : public Base Broadcast class implementation, registering listeners.
Threading: All methods of this class should be thread safe as it can be called from the user thread or the physics processing thread(s). There is not internal locking
Public Functions
-
inline PxBroadcast()
The default constructor.
-
inline void registerListener(Listener &listener)
Register new listener.
Note
It is NOT SAFE to register and deregister listeners while allocations may be taking place. moreover, there is no thread safety to registration/deregistration.
- Parameters
listener – Listener to register.
-
inline void deregisterListener(Listener &listener)
Deregister an existing listener.
Note
It is NOT SAFE to register and deregister listeners while allocations may be taking place. moreover, there is no thread safety to registration/deregistration.
- Parameters
listener – Listener to deregister.
-
inline uint32_t getNbListeners() const
Get number of registered listeners.
- Returns
Number of listeners.
Public Static Attributes
-
static const uint32_t MAX_NB_LISTENERS = 16
Protected Functions
-
inline virtual ~PxBroadcast()
Protected Attributes
-
physx::PxInlineArray<Listener*, MAX_NB_LISTENERS, physx::PxAllocator> mListeners
-
inline PxBroadcast()