Equalizer  1.2.1
Public Member Functions | Protected Member Functions
seq::ViewData Class Reference

Stores per-view data. More...

#include <viewData.h>

+ Inheritance diagram for seq::ViewData:
+ Collaboration diagram for seq::ViewData:

List of all members.

Public Member Functions

 ViewData ()
 Construct a new view data.
virtual ~ViewData ()
 Destruct this view data.
Operations
virtual bool handleEvent (const eq::ConfigEvent *event)
 Handle the given event.
void spinModel (const float x, const float y, const float z)
 Rotate the model matrix by the given increments.
void moveModel (const float x, const float y, const float z)
 Move the model matrix by the given increments.
void showStatistics (const bool on)
 Enable or disable statistics rendering.
virtual bool update ()
 Update the view data.
Data Access.
const Matrix4f & getModelMatrix () const
bool getStatistics () const

Protected Member Functions

virtual void serialize (co::DataOStream &os, const uint64_t dirtyBits)
 Worker for pack() and getInstanceData().
virtual void deserialize (co::DataIStream &is, const uint64_t dirtyBits)
 Worker for unpack() and applyInstanceData().

Detailed Description

Stores per-view data.

Definition at line 28 of file viewData.h.


Constructor & Destructor Documentation

Construct a new view data.

Version:
1.0
virtual seq::ViewData::~ViewData ( ) [virtual]

Destruct this view data.

Version:
1.0

Member Function Documentation

virtual void seq::ViewData::deserialize ( co::DataIStream ,
const uint64_t   
) [protected, virtual]

Worker for unpack() and applyInstanceData().

This function is called with the dirty bits send by the master instance. The dirty bits are received beforehand, and do not need to be deserialized by the overriding method.

See also:
serialize()
Version:
1.0

Reimplemented from co::Serializable.

const Matrix4f& seq::ViewData::getModelMatrix ( ) const [inline]
Returns:
the current model matrix (global camera).
Version:
1.0

Definition at line 81 of file viewData.h.

bool seq::ViewData::getStatistics ( ) const [inline]
Returns:
true is statistics are rendered.
Version:
1.0

Definition at line 84 of file viewData.h.

virtual bool seq::ViewData::handleEvent ( const eq::ConfigEvent event) [virtual]

Handle the given event.

The default implementation provides a pointer-based camera model and some key event handling, all of which can be modified by overwriting this method and handling the appropriate events.

Version:
1.0
void seq::ViewData::moveModel ( const float  x,
const float  y,
const float  z 
)

Move the model matrix by the given increments.

Version:
1.0
virtual void seq::ViewData::serialize ( co::DataOStream ,
const uint64_t   
) [protected, virtual]

Worker for pack() and getInstanceData().

Override this and deserialize() if you want to distribute subclassed data.

This method is called with DIRTY_ALL from getInstanceData() and with the actual dirty bits from pack(), which also resets the dirty state afterwards. The dirty bits are transmitted beforehand, and do not need to be transmitted by the overriding method.

Version:
1.0

Reimplemented from co::Serializable.

void seq::ViewData::showStatistics ( const bool  on)

Enable or disable statistics rendering.

The statistics are rendered in the views where they are enabled. The default event handler of this view toggles the statistics rendering state when 's' is pressed.

Parameters:
onthe state of the statistics rendering.
Version:
1.0
void seq::ViewData::spinModel ( const float  x,
const float  y,
const float  z 
)

Rotate the model matrix by the given increments.

Version:
1.0
virtual bool seq::ViewData::update ( ) [virtual]

Update the view data.

Called once at the end of each frame to trigger animations. The default implementation updates the camera data.

Returns:
true to request a redraw.
Version:
1.0

The documentation for this class was generated from the following file:
Generated on Fri Jun 8 2012 15:44:37 for Equalizer 1.2.1 by  doxygen 1.8.0