HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
DM_SceneHook Class Referenceabstract

A Scene Hook creates new scene render hooks when new viewports are created. More...

#include <DM_SceneHook.h>

Public Member Functions

 DM_SceneHook (const char *hook_name, int priority)
 
virtual ~DM_SceneHook ()
 
const char * getName () const
 
int getPriority () const
 
virtual DM_SceneRenderHooknewSceneRender (DM_VPortAgent &vport, DM_SceneHookType type, DM_SceneHookPolicy policy)=0
 Called when a viewport needs to create a new hook. Each viewport has its own scene hook. More...
 
virtual void retireSceneRender (DM_VPortAgent &vport, DM_SceneRenderHook *hook)=0
 Called when a viewport no longer requires the hook. When a viewport is destroyed, it retires all its hooks. Because a hook could be shared between all viewports, this method gives the scene hook the opportunity to delete it, dereference it, etc. The viewport doing the retiring is passed in along with the hook it is retiring. More...
 

Detailed Description

A Scene Hook creates new scene render hooks when new viewports are created.

Examples:
DM/DM_BackgroundHook.C, DM/DM_InfoHook.C, DM/DM_LightBloomHook.C, DM/DM_ObjectPathHook.C, DM/DM_OverdrawHook.C, and DM/DM_SceneBoundsHook.C.

Definition at line 121 of file DM_SceneHook.h.

Constructor & Destructor Documentation

DM_SceneHook::DM_SceneHook ( const char *  hook_name,
int  priority 
)

Create a scene hook which creates scene render hook instances for specific viewports. Only one scene hook is ever created, and it is responsible for managing the scene render hooks for viewports. Each hook requires a name (for error reporting) and a priority level to resolve multiple scene hook conflicts.

virtual DM_SceneHook::~DM_SceneHook ( )
virtual

Member Function Documentation

const char* DM_SceneHook::getName ( void  ) const
inline

Definition at line 133 of file DM_SceneHook.h.

int DM_SceneHook::getPriority ( ) const
inline

Definition at line 134 of file DM_SceneHook.h.

virtual DM_SceneRenderHook* DM_SceneHook::newSceneRender ( DM_VPortAgent vport,
DM_SceneHookType  type,
DM_SceneHookPolicy  policy 
)
pure virtual

Called when a viewport needs to create a new hook. Each viewport has its own scene hook.

virtual void DM_SceneHook::retireSceneRender ( DM_VPortAgent vport,
DM_SceneRenderHook hook 
)
pure virtual

Called when a viewport no longer requires the hook. When a viewport is destroyed, it retires all its hooks. Because a hook could be shared between all viewports, this method gives the scene hook the opportunity to delete it, dereference it, etc. The viewport doing the retiring is passed in along with the hook it is retiring.


The documentation for this class was generated from the following file: