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

Module managing all tessellation objects. More...

#include <tessellation.hpp>

Public Member Functions

 Tessellationmodule (cmzn_tessellationmodule_id in_tessellationmodule_id)
 
 Tessellationmodule (const Tessellationmodule &tessellationModule)
 
Tessellationmoduleoperator= (const Tessellationmodule &tessellationModule)
 
bool isValid () const
 
cmzn_tessellationmodule_id getId () const
 
Tessellation createTessellation ()
 
Tessellationiterator createTessellationiterator ()
 
Tessellation findTessellationByName (const char *name)
 
int beginChange ()
 
int endChange ()
 
Tessellation getDefaultTessellation ()
 
int setDefaultTessellation (const Tessellation &tessellation)
 
Tessellation getDefaultPointsTessellation ()
 
int setDefaultPointsTessellation (const Tessellation &tessellation)
 
int readDescription (const char *description)
 
char * writeDescription ()
 
Tessellationmodulenotifier createTessellationmodulenotifier ()
 

Protected Attributes

cmzn_tessellationmodule_id id
 

Detailed Description

Module managing all tessellation objects.

Module managing all tessellation objects. It maintains separate default tessellations for points and continuous graphics, the default points tessellation having only 1 point in each direction.

Member Function Documentation

int OpenCMISS::Zinc::Tessellationmodule::beginChange ( )
inline

Begin caching or increment cache level for this tessellation module. Call this function before making multiple changes to minimise number of change messages sent to clients. Must remember to end_change after completing changes. Can be nested.

See also
Tessellationmodule::endChange
Returns
Status OpenCMISS::Zinc::OK on success, otherwise OpenCMISS::Zinc::ERROR_ARGUMENT.
Tessellation OpenCMISS::Zinc::Tessellationmodule::createTessellation ( )
inline

Create and return a new tessellation.

tessellation will belong to.

Returns
Handle to new tessellation, or NULL/invalid handle on failure.
Tessellationiterator OpenCMISS::Zinc::Tessellationmodule::createTessellationiterator ( )
inline

Create a tessellation iterator object for iterating through the tessellations in the tessellation module, in alphabetical order of name. The iterator initially points at the position before the first tessellation, so the first call to the iterator next() method returns the first tessellation and advances the iterator. The iterator becomes invalid if tessellations are added, removed or renamed while in use.

See also
Tessellationiterator::next

tessellations are to be iterated over.

Returns
Handle to tessellation iterator, or NULL/invalid handle on failure.
Tessellationmodulenotifier OpenCMISS::Zinc::Tessellationmodule::createTessellationmodulenotifier ( )
inline

Create a notifier for getting callbacks for changes to the tessellations in the tessellation module.

Returns
Handle to new tessellation module notifier, or NULL/invalid handle on failure.
int OpenCMISS::Zinc::Tessellationmodule::endChange ( )
inline

Decrement cache level or end caching of changes for the tessellation module. Call tessellation module begin change method before making multiple changes and call this afterwards. When change level is restored to zero, cached change messages are sent out to clients.

See also
Tessellationmodule::beginChange
Returns
Status OpenCMISS::Zinc::OK on success, any other value on failure.
Tessellation OpenCMISS::Zinc::Tessellationmodule::findTessellationByName ( const char *  name)
inline

Find the tessellation with the specified name, if any.

Parameters
nameThe name of the tessellation.
Returns
Handle to tessellation, or NULL/invalid handle if not found or failed.
Tessellation OpenCMISS::Zinc::Tessellationmodule::getDefaultPointsTessellation ( )
inline

Get the default tessellation to be used by new points and streamlines graphics. If there is none, one is automatically created with minimum divisions 1, refinement factors 1, and circle divisions 12, and given the name "default_points".

Returns
Handle to default points tessellation, or NULL/invalid handle if none or failed.
Tessellation OpenCMISS::Zinc::Tessellationmodule::getDefaultTessellation ( )
inline

Get the default tessellation to be used by new lines, surfaces and isosurfaces graphics. If there is none, one is automatically created with minimum divisions 1, refinement factors 6, and circle divisions 12, and given the name "default".

Returns
Handle to default tessellation, or NULL/invalid handle if none or failed.
cmzn_tessellationmodule_id OpenCMISS::Zinc::Tessellationmodule::getId ( ) const
inline

Return the C handle of the Tessellationmodule object.

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

Check if this is a valid Tessellationmodule object.

Returns
Status True if object is valid, false otherwise.
int OpenCMISS::Zinc::Tessellationmodule::readDescription ( const char *  description)
inline

Read the json description to the tessellation module. This will change the tessellations in the tessellation module.

The string containing json description

Returns
OpenCMISS::Zinc::OK on success, otherwise ERROR status.
int OpenCMISS::Zinc::Tessellationmodule::setDefaultPointsTessellation ( const Tessellation tessellation)
inline

Set the default tessellation to be used by new points and streamlines graphics.

Parameters
tessellationThe tessellation to set as default for points.
Returns
OpenCMISS::Zinc::OK on success otherwise OpenCMISS::Zinc::ERROR_ARGUMENT.
int OpenCMISS::Zinc::Tessellationmodule::setDefaultTessellation ( const Tessellation tessellation)
inline

Set the default tessellation to be used by new lines, surfaces and isosurfaces graphics.

Parameters
tessellationThe tessellation to set as default.
Returns
OpenCMISS::Zinc::OK on success otherwise OpenCMISS::Zinc::ERROR_ARGUMENT.
char* OpenCMISS::Zinc::Tessellationmodule::writeDescription ( )
inline

Write the json file describing the tessellations in the tessellation module, which can be used to store the current tessellation settings.

Returns
c string containing the json description of tessellation module, otherwise 0;

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