Base class for objects that can be drawn in the game loop. More...
#include <Drawable.h>
Protected Member Functions | |
Drawable (const Drawable &)=delete | |
Drawable & | operator= (const Drawable &)=delete |
void | SubmitDrawRegistration () |
Submits the draw registration for the GameObject. | |
void | SubmitDrawDeregistration () |
Submits the draw deregistration for the GameObject. | |
Private Member Functions | |
virtual void | Draw () |
Virtual method to be implemented by derived classes for draw functionality. | |
virtual void | Draw2D () |
Virtual method to be implemented by derived classes for 2D draw functionality. | |
void | SceneRegistration () |
Registers the GameObject for drawing in the scene. | |
void | SceneDeregistration () |
Deregisters the GameObject from drawing in the scene. | |
Private Attributes | |
RegistrationState | RegStateCurr |
The current registration state of the GameObject. | |
DrawRegistrationCommand * | ptrDrawRegistrationCmd |
Pointer to the draw registration command for the GameObject. | |
DrawDeregistrationCommand * | ptrDrawDeregistrationCmd |
Pointer to the draw deregistration command for the GameObject. | |
DrawableManager::StorageListRef | pMyDeleteRef |
Reference to the storage list iterator for the GameObject. | |
Friends | |
class | DrawableAttorney |
Base class for objects that can be drawn in the game loop.
The Drawable
class provides a base implementation for objects that need to be drawn during the game loop. It manages registration and deregistration with the DrawableManager
and provides virtual draw methods that can be overridden by derived classes.
|
inlineprivatevirtual |
Virtual method to be implemented by derived classes for 2D draw functionality.
Reimplemented in Canvas.