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

Scene render hook instance, which does the actual rendering for a viewport. More...

#include <DM_SceneHook.h>

Public Member Functions

 DM_SceneRenderHook (DM_VPortAgent &vport, DM_ViewportType view_mask)
 
virtual ~DM_SceneRenderHook ()
 
virtual bool supportsRenderer (GR_RenderVersion version)
 Restrict hook to only certain Viewport Renderer versions This method allows you to restrict this hook to only operate in some of the viewport renderers (H11 - GL3). If the viewport is set to a a renderer and this method returns false, it will be skipped. The default action is to support all viewport renderers. More...
 
virtual bool render (RE_Render *r, const DM_SceneHookData &hook_data)=0
 Render method called when the rendering task is required. render() performs the rendering task for the hook, or returns false if if it cannot. The RE_Render contains the active GL context and the hook_data contains viewport-specific and hook-specific data. More...
 
virtual void viewportClosed ()
 Callback method when the viewport is no longer visible. Called when the viewport is temporarily closed (quad/single switch, pane switch). This gives the hook the opportunity to clean up expensive GL objects or caches. More...
 
DM_VPortAgentviewport () const
 Viewport this scene render is attached to. More...
 
DM_ViewportType getViewportMask () const
 

Detailed Description

Scene render hook instance, which does the actual rendering for a viewport.

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 78 of file DM_SceneHook.h.

Constructor & Destructor Documentation

DM_SceneRenderHook::DM_SceneRenderHook ( DM_VPortAgent vport,
DM_ViewportType  view_mask 
)

A Scene render hook has a parent viewport and a view type mask which determines which viewport types it will display in (eg. perspective, ortho, UV, all)

virtual DM_SceneRenderHook::~DM_SceneRenderHook ( )
virtual

Member Function Documentation

DM_ViewportType DM_SceneRenderHook::getViewportMask ( ) const
inline

Definition at line 111 of file DM_SceneHook.h.

virtual bool DM_SceneRenderHook::render ( RE_Render r,
const DM_SceneHookData hook_data 
)
pure virtual

Render method called when the rendering task is required. render() performs the rendering task for the hook, or returns false if if it cannot. The RE_Render contains the active GL context and the hook_data contains viewport-specific and hook-specific data.

virtual bool DM_SceneRenderHook::supportsRenderer ( GR_RenderVersion  version)
inlinevirtual

Restrict hook to only certain Viewport Renderer versions This method allows you to restrict this hook to only operate in some of the viewport renderers (H11 - GL3). If the viewport is set to a a renderer and this method returns false, it will be skipped. The default action is to support all viewport renderers.

Definition at line 93 of file DM_SceneHook.h.

DM_VPortAgent& DM_SceneRenderHook::viewport ( ) const
inline

Viewport this scene render is attached to.

Definition at line 110 of file DM_SceneHook.h.

virtual void DM_SceneRenderHook::viewportClosed ( )
virtual

Callback method when the viewport is no longer visible. Called when the viewport is temporarily closed (quad/single switch, pane switch). This gives the hook the opportunity to clean up expensive GL objects or caches.


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