OpenCMISS-Zinc C++ API Documentation
Public Types | Public Member Functions | List of all members
OpenCMISS::Zinc::StreaminformationScene Class Reference

A scene-specific stream information object. More...

#include <streamscene.hpp>

Inheritance diagram for OpenCMISS::Zinc::StreaminformationScene:
OpenCMISS::Zinc::Streaminformation

Public Types

enum  IODataType { IO_DATA_TYPE_INVALID = CMZN_STREAMINFORMATION_SCENE_IO_DATA_TYPE_INVALID, IO_DATA_TYPE_COLOUR = CMZN_STREAMINFORMATION_SCENE_IO_DATA_TYPE_COLOUR, IO_DATA_TYPE_PER_VERTEX_VALUE = CMZN_STREAMINFORMATION_SCENE_IO_DATA_TYPE_PER_VERTEX_VALUE, IO_DATA_TYPE_PER_FACE_VALUE = CMZN_STREAMINFORMATION_SCENE_IO_DATA_TYPE_PER_FACE_VALUE }
 
enum  IOFormat { IO_FORMAT_INVALID = CMZN_STREAMINFORMATION_SCENE_IO_FORMAT_INVALID, IO_FORMAT_THREEJS = CMZN_STREAMINFORMATION_SCENE_IO_FORMAT_THREEJS, IO_FORMAT_DESCRIPTION = CMZN_STREAMINFORMATION_SCENE_IO_FORMAT_DESCRIPTION }
 
- Public Types inherited from OpenCMISS::Zinc::Streaminformation
enum  DataCompressionType {
  DATA_COMPRESSION_TYPE_INVALID = CMZN_STREAMINFORMATION_DATA_COMPRESSION_TYPE_INVALID, DATA_COMPRESSION_TYPE_DEFAULT = CMZN_STREAMINFORMATION_DATA_COMPRESSION_TYPE_DEFAULT, DATA_COMPRESSION_TYPE_NONE = CMZN_STREAMINFORMATION_DATA_COMPRESSION_TYPE_NONE, DATA_COMPRESSION_TYPE_GZIP = CMZN_STREAMINFORMATION_DATA_COMPRESSION_TYPE_GZIP,
  DATA_COMPRESSION_TYPE_BZ2 = CMZN_STREAMINFORMATION_DATA_COMPRESSION_TYPE_BZIP2
}
 

Public Member Functions

 StreaminformationScene (cmzn_streaminformation_scene_id streaminformation_scene_id)
 
bool isValid () const
 
cmzn_streaminformation_scene_id getDerivedId () const
 
Scenefilter getScenefilter ()
 
int setScenefilter (const Scenefilter &scenefilter)
 
IODataType getIODataType ()
 
int setIODataType (IODataType ioDataType)
 
IOFormat getIOFormat ()
 
int setIOFormat (IOFormat ioFormat)
 
int getNumberOfTimeSteps ()
 
int setNumberOfTimeSteps (int numberOfTimeSteps)
 
double getFinishTime ()
 
int setFinishTime (double finishTime)
 
double getInitialTime ()
 
int setInitialTime (double initialTime)
 
int getNumberOfResourcesRequired ()
 
int setOverwriteSceneGraphics (int overwrite)
 
int getOutputTimeDependentVertices ()
 
int setOutputTimeDependentVertices (int outputTimeDependentVertices)
 
int getOutputTimeDependentColours ()
 
int setOutputTimeDependentColours (int outputTimeDependentColours)
 
int getOutputTimeDependentNormals ()
 
int setOutputTimeDependentNormals (int outputTimeDependentNormals)
 
- Public Member Functions inherited from OpenCMISS::Zinc::Streaminformation
 Streaminformation (cmzn_streaminformation_id in_streaminformation_id)
 
 Streaminformation (const Streaminformation &streamInformation)
 
Streaminformationoperator= (const Streaminformation &streamInformation)
 
bool isValid () const
 
cmzn_streaminformation_id getId () const
 
StreamresourceFile createStreamresourceFile (const char *file_name)
 
StreamresourceMemory createStreamresourceMemory ()
 
StreamresourceMemory createStreamresourceMemoryBuffer (const void *buffer, unsigned int buffer_length)
 
StreamresourceMemory createStreamresourceMemoryBufferCopy (const void *buffer, unsigned int buffer_length)
 
enum DataCompressionType getResourceDataCompressionType (const Streamresource &resource)
 
int setResourceDataCompressionType (const Streamresource &resource, DataCompressionType dataCompressionType)
 
enum DataCompressionType getDataCompressionType ()
 
int setDataCompressionType (DataCompressionType dataCompressionType)
 
StreaminformationImage castImage ()
 
StreaminformationRegion castRegion ()
 
StreaminformationScene castScene ()
 

Additional Inherited Members

- Protected Attributes inherited from OpenCMISS::Zinc::Streaminformation
cmzn_streaminformation_id id
 

Detailed Description

A scene-specific stream information object.

A scene-specific stream information object, used to specify one or more files/resources for a scene to write to, with attributes specified for them globally.

See also
Scene::createStreaminformationScene

Member Enumeration Documentation

Enumeration to indicate what the data should written out as.

Enumerator
IO_DATA_TYPE_INVALID 

Unspecified type

IO_DATA_TYPE_COLOUR 

Export data as colour

IO_DATA_TYPE_PER_VERTEX_VALUE 

Export data as field value on per vertex basis

IO_DATA_TYPE_PER_FACE_VALUE 

Export data as field value on per face basis

Enumeration of attributes that can be set by generic stream information region methods.

Enumerator
IO_FORMAT_INVALID 

Unspecified attribute

IO_FORMAT_THREEJS 

Export scene into ThreeJS compatible JSON file.

IO_FORMAT_DESCRIPTION 

Import/export scene configurations into the scene

Member Function Documentation

cmzn_streaminformation_scene_id OpenCMISS::Zinc::StreaminformationScene::getDerivedId ( ) const
inline

Return the C handle of the derived StreaminformationScene object.

Returns
C handle of the derived StreaminformationScene if this objects is valid, 0 otherwise.
double OpenCMISS::Zinc::StreaminformationScene::getFinishTime ( )
inline

Get the last time step to export.

Returns
positive integer number on success, 0 on failure.
double OpenCMISS::Zinc::StreaminformationScene::getInitialTime ( )
inline

Get the first time step to export.

Returns
positive integer number on success, 0 on failure.
int OpenCMISS::Zinc::StreaminformationScene::getNumberOfResourcesRequired ( )
inline

Get the the number of resources required to fully export the scene. Some formats require more than 1 resource to fully export the scene, use this function to find the number of resources required.

Returns
positive integer number on success, 0 on failure.
int OpenCMISS::Zinc::StreaminformationScene::getNumberOfTimeSteps ( )
inline

Get the number of time steps to export.

Returns
positive integer number on success, 0 on failure.
int OpenCMISS::Zinc::StreaminformationScene::getOutputTimeDependentColours ( )
inline

Get the flag which specifies colours should be output for each time step; The default value is 0;

Returns
1 if colours are set to be output for each time step, otherwise 0.
int OpenCMISS::Zinc::StreaminformationScene::getOutputTimeDependentNormals ( )
inline

Get the flag which specifies normals should be output for each time step; The default value is 0;

Returns
1 if normals are set to be output for each time step, otherwise 0.
int OpenCMISS::Zinc::StreaminformationScene::getOutputTimeDependentVertices ( )
inline

Get the flag which specifies vertices should be output for each time step; The default value is 1;

Returns
1 if vertices are set to be output for each time step, otherwise 0.
Scenefilter OpenCMISS::Zinc::StreaminformationScene::getScenefilter ( )
inline

Return the scenefilter that is set for this streaminformation

Returns
Handle to scene filter, or NULL/invalid handle if none or failed.
bool OpenCMISS::Zinc::StreaminformationScene::isValid ( ) const
inline

Check if this is a valid StreaminformationScene object.

Returns
Status True if object is valid, false otherwise.
int OpenCMISS::Zinc::StreaminformationScene::setFinishTime ( double  finishTime)
inline

Set the last time step to export.

Parameters
finishTimelast time step to be set for export.
Returns
Status OpenCMISS::Zinc::OK on success, any other value on failure.
int OpenCMISS::Zinc::StreaminformationScene::setInitialTime ( double  initialTime)
inline

Set the first time step to export.

Parameters
initialTimefirst time step to be set for export.
Returns
Status OpenCMISS::Zinc::OK on success, any other value on failure.
int OpenCMISS::Zinc::StreaminformationScene::setNumberOfTimeSteps ( int  numberOfTimeSteps)
inline

Set the number of time steps to export. This value along with finish time and initial time will determine at which time steps the graphics will be export. If initial time = 0.0, finish time = 1.0 and number of time steps = 11; graphics will be export at 0.0, 0.1, 0.2, 0.3, 0.4, 0.5, 0.6, 0.7, 0.8, 0.9 and 1.0.

See also
StreaminformationScene::setFinishTime
StreaminformationScene::setInitialTime
Parameters
numberOfTimeStepsnumber of time steps to be set for export.
Returns
Status OpenCMISS::Zinc::OK on success, any other value on failure.
int OpenCMISS::Zinc::StreaminformationScene::setOutputTimeDependentColours ( int  outputTimeDependentColours)
inline

Set the flag which specifies colours should be output for each time step; If this flag is set to 1, colours will be output at times determined by initial_time, finish_time and number_of_time_steps set by the caller. The default value is 0;

Parameters
outputTimeDependentColoursvalue to be assigned to the flag.
Returns
Status OpenCMISS::Zinc::OK on success, any other value on failure.
int OpenCMISS::Zinc::StreaminformationScene::setOutputTimeDependentNormals ( int  outputTimeDependentNormals)
inline

Set the flag which specifies normals should be output for each time step; If this flag is set to 1, normals will be output at times determined by initial_time, finish_time and number_of_time_steps set by the caller. The default value is 0;

Parameters
outputTimeDependentNormalsvalue to be assigned to the flag.
Returns
Status OpenCMISS::Zinc::OK on success, any other value on failure.
int OpenCMISS::Zinc::StreaminformationScene::setOutputTimeDependentVertices ( int  outputTimeDependentVertices)
inline

Set the flag which specifies vertices should be output for each time step; If this flag is set to 1, vertices will be output at times determined by initial_time, finish_time and number_of_time_steps set by the caller. The default value is 1;

Parameters
outputTimeDependentVerticesvalue to be assigned to the flag.
Returns
Status OpenCMISS::Zinc::OK on success, any other value on failure.
int OpenCMISS::Zinc::StreaminformationScene::setOverwriteSceneGraphics ( int  overwrite)
inline

Set a flag which determines graphics should be removed before new graphics settings are imported into scene.

Parameters
overwriteflag to indicate either graphics should be overwrite.
Returns
Status OpenCMISS::Zinc::OK on success, any other value on failure.
int OpenCMISS::Zinc::StreaminformationScene::setScenefilter ( const Scenefilter scenefilter)
inline

Set the scenefilter for the streaminformation_scene. This filter determines which graphics are included in the export.

Parameters
scenefilterThe scene filter to use, or NULL if none (all enable).
Returns
Status OpenCMISS::Zinc::OK on success, any other value on failure.

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