User Tools

Site Tools


DzRenderMgr

Manager responsible for renderers and rendering.

More...

Inherits :

Enumerations

Static Methods

DAZ Script
StringgetIconSuffix ()
StringgetMetaXmlFileName ( String imageName, Boolean basenameOnly )
StringgetRenderBaseFileName ( String imageName, Boolean basenameOnly )
StringgetRenderIconFileName ( String imageName, Boolean basenameOnly )

Methods

Signals

Detailed Description

Responsible for the management of renderers, and more generally the process of performing a render.

There is only one instance of this manager in an application. This instance is created and owned by DzApp. Request the instance via DzApp::getRenderMgr().

See Also:

Enumerations


: RenderPriority

Possible render priorities that are used to order various operations when rendering. Most notably, DzNodes and DzMaterials are processed according to their priority when rendering.

  • RENDER_PRIORITY_LOWEST - The lowest priority.
  • RENDER_PRIORITY_LOW - A low priority.
  • RENDER_PRIORITY_BELOW_NORMAL - A below normal priority.
  • RENDER_PRIORITY_NORMAL - The normal priority.
  • RENDER_PRIORITY_ABOVE_NORMAL - An above normal priority.
  • RENDER_PRIORITY_HIGH - A high priority.
  • RENDER_PRIORITY_HIGHEST - The highest priority.

Static Methods


String : getIconSuffix()

Return Value:

  • The suffix used for files generated as icons for renders to help improve performance and responsiveness.

String : getMetaXmlFileName( String imageName, Boolean basenameOnly )

Parameter(s):

  • imageName - The path of the rendered file to get the metadata file for.
  • shortname - If true, only the shortname of the file is returned, otherwise the full path of the file is returned.

Return Value:

  • The name of the XML file that holds metadata for imageName.

String : getRenderBaseFileName( String imageName, Boolean basenameOnly )

Parameter(s):

  • imageName - The path of the rendered file to get a base filename for.
  • basename - If true, only the basename of the file is returned, otherwise the basename is preceded by the path.

Return Value:

  • The base filename of the file for imageName.

String : getRenderIconFileName( String imageName, Boolean basenameOnly )

Parameter(s):

  • imageName - The path of the rendered file to get the icon file for.
  • shortname - If true, only the shortname of the file is returned, otherwise the full path of the file is returned.

Return Value:

  • The name of the icon file for imageName.

Methods


void : addRenderDirectory( String directory, Boolean saveSetting=true )

Adds a directory to the list of known render directories.

Parameter(s):

  • directory - The path of the directory to add.
  • saveSetting - If true, saves the setting immediately. If false, waits until the application exits to save the setting.

Boolean : doIPRRender( DzCamera camera, DzRenderHandler renderHandler, DzRenderOptions opt=null )

Interactively and progressively renders the scene with the given render settings, using the given handler from the given camera.

Parameter(s):

  • opt - The render settings to use for the render. If NULL, the current user render settings are used.
  • renderHandler - The render handler to use for the render.
  • camera - The camera to use for the render.

Return Value:

  • true if the render was performed successfully, otherwise false.

Boolean : doRender( DzRenderOptions opt=null )

Renders the scene with the given render settings. If no render settings are specified, then the current application render settings are used.

Parameter(s):

  • opt - The render settings to use for the render. If null, the current user render settings are used.

Return Value:

  • true if the render operation succeeds, otherwise false.

DzRenderer : findRenderer( String className )

Return Value:

  • The renderer with the given class name (if any), otherwise null.

DzRenderer : getActiveRenderer()

Return Value:

  • The active renderer for the application. This will be NULL if no renderers are available.

Array : getBaseAndRelativePath( String absPath )

Parameter(s):

  • absPath - The absolute path to split into its base and relative parts.

Return Value:

  • A list where the first item is the base path and any additional items represent the relative portion of the path.

String : getLastSavedRenderPath()

Return Value:

  • The path to the last successfully saved render, otherwise an empty string.

Number : getNumRenderDirectories()

Return Value:

  • The number of render directories.

Number : getNumRenderers()

Return Value:

  • The number of renderers available in the application.

DzElement : getOptionHelper()

TODO: Add description.


String : getRenderDirectoryPath( Number which )

Parameter(s):

  • which - The index of the render directory to be returned.

Return Value:

  • The given render directory.

Array : getRenderElementObjects()

TODO: Add description.


DzRenderer : getRenderer( Number which )

Return Value:

  • If which is within the range [0, getNumRenderers() - 1], the renderer at the given index, otherwise null.

Array : getRendererList()

Return Value:

  • A list of renderers available in the application.

DzRenderOptions : getRenderOptions()

Return Value:

  • The default render options object. This object stores the user's currently selected rendering options.

Boolean : hasRender()

Return Value:

  • true if there is a render that can be saved, otherwise false.

Boolean : isRendering()

Return Value:

  • true if the application is currently rendering, otherwise false.

void : rebuildRenderElements()

TODO: Add description.


void : removeAllRenderDirectories()

Removes all render directories.


Boolean : removeRenderDirectory( String directory )

Removes a directory from the list of known render directories.

Parameter(s):

  • directory - The name of the render directory to remove.

Return Value:

  • true if the directory was found in the list, otherwise false.

void : restoreDefaultRenderOptions()

TODO: Add description.


String : saveLastRender()

Displays a dialog for saving the last render, and saves the image(s)/movie if the user does not cancel.

Return Value:

  • The path to the file selected and successfully saved, otherwise an empty string.

void : setActiveRenderer( DzRenderer renderer )

Sets the active renderer for the application.

Parameter(s):

  • renderer - The renderer to make active.

void : showRenderDialog()

Displays the render options dialog to the user. This only works if the application is being run with the interface on, if the interface is off, this function does nothing.


void : stopIPRRender()

TODO: Add description.

Signals


void : activeRendererChanged( DzRenderer renderer )

Signature:“activeRendererChanged(DzRenderer*)”

Emitted when the active render engine has changed.

Parameter(s):

  • renderer - The new active render engine.

void : activeRendererIPRRenderHandlerChanged( DzRenderer renderer, iprrenderhandler_dz handler )

TODO: Add description.


void : doIPRRenderStop()

TODO: Add description.


void : hasRenderChanged( Boolean state )

Signature:“hasRenderChanged(bool)”

Emitted when the value returned by DzRenderMgr::hasRender() has changed, signaling a new render operation. This signifies whether or not a call to saveLastRender() will be valid.


void : IPRRenderStarted()

TODO: Add description.


void : IPRRenderStopped()

TODO: Add description.


void : renderDirectoryListChanged()

TODO: Add description.


void : renderElementsListChanged()

TODO: Add description.


void : rendererAdded( DzRenderer renderer )

Signature:“rendererAdded(DzRenderer*)”

Emitted when a new render engine is added to the manager. This only occurs at startup as plug-ins are being loaded.

Parameter(s):

  • renderer - The new render engine that was added to the manager.

void : rendererIPRRenderHandlerChanged( DzRenderer renderer, iprrenderhandler_dz handler )

TODO: Add description.


void : rendererModeChanged( DzRenderer renderer )

TODO: Add description.


void : renderFinished( Boolean succeeded )

Signature:“renderFinished(bool)”

Emitted just after a rendering operation is finished. This is only emitted when a render operation is performed by calling DzRenderMgr::doRender() - this includes all rendering operations that are started by the user from the interface. This may not include rendering operations performed by plug-ins, scripts, etc which do not call doRender().

Parameter(s):

  • succeeded - true if the render was successful, false if the render failed or was cancelled by the user.

See Also:


void : renderFolderChanged()

TODO: Add description.


void : renderOptionDefaultsRestored()

TODO: Add description.


void : renderStarting()

Signature:“renderStarting()”

Emitted just before a rendering operation begins. This is only emitted when a render operation is performed by calling DzRenderMgr::doRender() - this includes all rendering operations that are started by the user from the interface. This may not include rendering operations performed by plug-ins, scripts, etc which do not call doRender().

See Also: