Public Types | Public Member Functions | Data Fields | Protected Member Functions | Protected Attributes | Private Member Functions | Private Attributes
scene Class Reference
Collaboration diagram for scene:
Collaboration graph
[legend]

Public Types

enum  modeType { mtStatic, mtFlightPath }
 

Public Member Functions

 scene (const objectRegistry &obr, const word &name)
 Construct from components. More...
 
virtual ~scene ()
 Destructor. More...
 
const HashPtrTable< DataEntry< vector >, word > & colours () const
 Return the colours. More...
 
label frameIndex () const
 Return the current frame index. More...
 
scalar position () const
 Return the current position (in range 0-1) More...
 
void read (const dictionary &dict)
 
void initialise (vtkRenderer *renderer, const word &outputName)
 
bool loop (vtkRenderer *renderer)
 Main control loop. More...
 
void saveImage (vtkRenderWindow *renderWindow) const
 Save image to file. More...
 

Data Fields

NamedEnum< modeType, 2 > modeTypeNames_
 

Protected Member Functions

void setCamera (vtkRenderer *renderer, const bool override) const
 
string frameIndexStr () const
 

Protected Attributes

HashPtrTable< DataEntry< vector >, wordcolours_
 Colours. More...
 
modeType mode_
 Mode. More...
 
autoPtr< DataEntry< point > > cameraPosition_
 Position. More...
 
autoPtr< DataEntry< point > > cameraFocalPoint_
 Focal point. More...
 
autoPtr< DataEntry< vector > > cameraUp_
 Up direction. More...
 
autoPtr< DataEntry< scalar > > cameraZoom_
 Zoom level. More...
 
autoPtr< DataEntry< scalar > > cameraViewAngle_
 View angle. More...
 
boundBox clipBox_
 Clipping box. More...
 
bool parallelProjection_
 Parallel projection flag. More...
 
label nFrameTotal_
 Number of frames. More...
 
scalar position_
 Position [0-1]. More...
 
scalar dPosition_
 Change in position per frame. More...
 
label currentFrameI_
 Index of current frame. More...
 
word outputName_
 Name prefix of output. More...
 

Private Member Functions

void readCamera (const dictionary &dict)
 Read camera properties. More...
 
void readColours (const dictionary &dict)
 Read solour properties. More...
 
 scene (const scene &)
 Disallow default bitwise copy construct. More...
 
void operator= (const scene &)
 Disallow default bitwise assignment. More...
 

Private Attributes

const objectRegistryobr_
 Reference to the object registry. More...
 
const word name_
 Object name. More...
 

Detailed Description

Definition at line 61 of file scene.H.

Member Enumeration Documentation

◆ modeType

enum modeType
Enumerator
mtStatic 
mtFlightPath 

Definition at line 65 of file scene.H.

Constructor & Destructor Documentation

◆ scene() [1/2]

scene ( const scene )
private

Disallow default bitwise copy construct.

◆ scene() [2/2]

scene ( const objectRegistry obr,
const word name 
)

Construct from components.

Definition at line 279 of file scene.C.

◆ ~scene()

~scene ( )
virtual

Destructor.

Definition at line 302 of file scene.C.

Member Function Documentation

◆ readCamera()

void readCamera ( const dictionary dict)
private

◆ readColours()

void readColours ( const dictionary dict)
private

Read solour properties.

Definition at line 157 of file scene.C.

References Foam::constant::universal::c, dict, forAll, and dictionary::toc().

Here is the call graph for this function:

◆ operator=()

void operator= ( const scene )
private

Disallow default bitwise assignment.

◆ setCamera()

void setCamera ( vtkRenderer *  renderer,
const bool  override 
) const
protected

Definition at line 241 of file scene.C.

References Foam::compressible::New(), Foam::pos(), dimensioned::value(), Vector< Cmpt >::x(), Vector< Cmpt >::y(), and Vector< Cmpt >::z().

Here is the call graph for this function:

◆ frameIndexStr()

Foam::string frameIndexStr ( ) const
protected

Definition at line 268 of file scene.C.

References Foam::name().

Here is the call graph for this function:

◆ colours()

const Foam::HashPtrTable< Foam::DataEntry< Foam::vector >, Foam::word > & colours ( ) const

Return the colours.

Definition at line 309 of file scene.C.

◆ frameIndex()

Foam::label frameIndex ( ) const

Return the current frame index.

Definition at line 315 of file scene.C.

◆ position()

Foam::scalar position ( ) const

Return the current position (in range 0-1)

Definition at line 321 of file scene.C.

◆ read()

void read ( const dictionary dict)

Definition at line 327 of file scene.C.

References dict, and dictionary::subDict().

Here is the call graph for this function:

◆ initialise()

void initialise ( vtkRenderer *  renderer,
const word outputName 
)

Definition at line 168 of file scene.C.

References Foam::max(), Foam::min(), Foam::compressible::New(), Vector< Cmpt >::x(), Vector< Cmpt >::y(), and Vector< Cmpt >::z().

Here is the call graph for this function:

◆ loop()

bool loop ( vtkRenderer *  renderer)

Main control loop.

Definition at line 334 of file scene.C.

◆ saveImage()

void saveImage ( vtkRenderWindow *  renderWindow) const

Save image to file.

Definition at line 364 of file scene.C.

References Foam::endl(), Foam::Info, Foam::mkDir(), and Foam::compressible::New().

Here is the call graph for this function:

Field Documentation

◆ modeTypeNames_

NamedEnum<modeType, 2> modeTypeNames_

Definition at line 67 of file scene.H.

Referenced by scene::readCamera().

◆ obr_

const objectRegistry& obr_
private

Reference to the object registry.

Definition at line 75 of file scene.H.

◆ name_

const word name_
private

Object name.

Definition at line 78 of file scene.H.

◆ colours_

HashPtrTable<DataEntry<vector>, word> colours_
protected

Colours.

Definition at line 101 of file scene.H.

◆ mode_

modeType mode_
protected

Mode.

Definition at line 107 of file scene.H.

Referenced by scene::readCamera().

◆ cameraPosition_

autoPtr<DataEntry<point> > cameraPosition_
protected

Position.

Definition at line 110 of file scene.H.

Referenced by scene::readCamera().

◆ cameraFocalPoint_

autoPtr<DataEntry<point> > cameraFocalPoint_
protected

Focal point.

Definition at line 113 of file scene.H.

Referenced by scene::readCamera().

◆ cameraUp_

autoPtr<DataEntry<vector> > cameraUp_
protected

Up direction.

Definition at line 116 of file scene.H.

Referenced by scene::readCamera().

◆ cameraZoom_

autoPtr<DataEntry<scalar> > cameraZoom_
protected

Zoom level.

Definition at line 119 of file scene.H.

Referenced by scene::readCamera().

◆ cameraViewAngle_

autoPtr<DataEntry<scalar> > cameraViewAngle_
protected

View angle.

Definition at line 122 of file scene.H.

Referenced by scene::readCamera().

◆ clipBox_

boundBox clipBox_
protected

Clipping box.

Definition at line 128 of file scene.H.

Referenced by scene::readCamera().

◆ parallelProjection_

bool parallelProjection_
protected

Parallel projection flag.

Definition at line 131 of file scene.H.

Referenced by scene::readCamera().

◆ nFrameTotal_

label nFrameTotal_
protected

Number of frames.

Definition at line 134 of file scene.H.

Referenced by scene::readCamera().

◆ position_

scalar position_
protected

Position [0-1].

Definition at line 137 of file scene.H.

Referenced by scene::readCamera().

◆ dPosition_

scalar dPosition_
protected

Change in position per frame.

Definition at line 140 of file scene.H.

Referenced by scene::readCamera().

◆ currentFrameI_

label currentFrameI_
protected

Index of current frame.

Definition at line 143 of file scene.H.

◆ outputName_

word outputName_
protected

Name prefix of output.

Definition at line 146 of file scene.H.


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