OpenCMISS-Zinc C++ API Documentation
Public Member Functions | Protected Attributes | List of all members
OpenCMISS::Zinc::Sceneviewermodule Class Reference

Module object for creating and managing scene viewers. More...

#include <sceneviewer.hpp>

Public Member Functions

 Sceneviewermodule (cmzn_sceneviewermodule_id in_sceneviewermodule_id)
 
 Sceneviewermodule (const Sceneviewermodule &sceneviewermodule)
 
Sceneviewermoduleoperator= (const Sceneviewermodule &sceneviewermodule)
 
bool isValid () const
 
cmzn_sceneviewermodule_id getId () const
 
Sceneviewer createSceneviewer (Sceneviewer::BufferingMode buffering_mode, Sceneviewer::StereoMode stereo_mode)
 
double getDefaultBackgroundColourAlpha ()
 
int setDefaultBackgroundColourAlpha (const double alpha)
 
int getDefaultBackgroundColourRGB (double *valuesOut3)
 
int setDefaultBackgroundColourRGB (const double *valuesIn3)
 
int getDefaultBackgroundColourRGBA (double *valuesOut4)
 
int setDefaultBackgroundColourRGBA (const double *valuesIn4)
 

Protected Attributes

cmzn_sceneviewermodule_id id
 

Detailed Description

Module object for creating and managing scene viewers.

Module object for creating and managing scene viewers.

Member Function Documentation

Sceneviewer OpenCMISS::Zinc::Sceneviewermodule::createSceneviewer ( Sceneviewer::BufferingMode  buffering_mode,
Sceneviewer::StereoMode  stereo_mode 
)
inline

Returns a handle to a scene viewer object. The scene viewer attributes for buffering mode and stereo mode are also set.

Parameters
buffering_modeThe buffering mode in use for the OpenGL context.
stereo_modeThe stereo mode in use for the OpenGL context.
Returns
Handle to new sceneviewer, or NULL/invalid handle on failure.
double OpenCMISS::Zinc::Sceneviewermodule::getDefaultBackgroundColourAlpha ( )
inline

Get the alpha opacity component of the default background colour for new scene viewers created from this scene viewer module. The initial default is 1.0 i.e. opaque.

Returns
Alpha value in [0.0, 1.0].
int OpenCMISS::Zinc::Sceneviewermodule::getDefaultBackgroundColourRGB ( double *  valuesOut3)
inline

Get the default background colour for new scene viewers created from this scene viewer module. The initial defaults are [0.0, 0.0, 0.0] i.e. black.

Parameters
valuesOut3Three colour components in order [red, green, blue], with values in [0, 1.0].
Returns
Result OK if successful, otherwise ERROR_ARGUMENT.
cmzn_sceneviewermodule_id OpenCMISS::Zinc::Sceneviewermodule::getId ( ) const
inline

Return the C handle of the Sceneviewermodule object.

Returns
C handle of Sceneviewermodule if this objects is valid, 0 otherwise.
bool OpenCMISS::Zinc::Sceneviewermodule::isValid ( ) const
inline

Check if this is a valid Sceneviewermodule object.

Returns
Status True if object is valid, false otherwise.
int OpenCMISS::Zinc::Sceneviewermodule::setDefaultBackgroundColourAlpha ( const double  alpha)
inline

Set the alpha opacity component of the default background colour for new scene viewers created from this scene viewer module. The remaining components of the default background colour are unchanged.

Parameters
alphaThe alpha value in [0, 1.0] where 0.0 is transparent, 1.0 is opaque.
Returns
Result OK if successful, otherwise ERROR_ARGUMENT.
int OpenCMISS::Zinc::Sceneviewermodule::setDefaultBackgroundColourRGB ( const double *  valuesIn3)
inline

Set the default background colour for new scene viewers created from this scene viewer module. Background colour alpha is unchanged.

Parameters
valuesIn3Three colour components in order [red, green, blue], with values in [0, 1.0].
Returns
Result OK if successful, otherwise ERROR_ARGUMENT.

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