18 #ifndef EQFABRIC_OBSERVER_H
19 #define EQFABRIC_OBSERVER_H
21 #include <eq/fabric/api.h>
22 #include <eq/fabric/eye.h>
23 #include <eq/fabric/focusMode.h>
24 #include <eq/fabric/object.h>
25 #include <eq/fabric/types.h>
62 EQFABRIC_INL
void setEyeBase(
const float eyeBase );
65 EQFABRIC_INL
float getEyeBase()
const;
112 ObserverPath getPath()
const;
129 virtual void backup();
130 virtual void restore();
141 virtual void serialize( co::DataOStream& os,
142 const uint64_t dirtyBits );
144 virtual void deserialize( co::DataIStream& is,
145 const uint64_t dirtyBits );
146 virtual void setDirty(
const uint64_t bits );
151 DIRTY_EYE_POSITION = Object::DIRTY_CUSTOM << 0,
152 DIRTY_HEAD = Object::DIRTY_CUSTOM << 1,
153 DIRTY_FOCUS = Object::DIRTY_CUSTOM << 2,
154 DIRTY_TRACKER = Object::DIRTY_CUSTOM << 3,
155 DIRTY_OBSERVER_BITS =
156 DIRTY_EYE_POSITION | DIRTY_HEAD | DIRTY_FOCUS | DIRTY_TRACKER |
161 virtual uint64_t getRedistributableBits()
const
162 {
return DIRTY_OBSERVER_BITS; }
177 std::string vrpnTracker;
185 template<
class C,
class O >
186 EQFABRIC_INL std::ostream& operator << ( std::ostream&,
187 const Observer< C, O >& );
190 #endif // EQFABRIC_OBSERVER_H
const C * getConfig() const
EQFABRIC_INL bool setHeadMatrix(const Matrix4f &matrix)
Set the head matrix.
EQFABRIC_INL void setFocusDistance(const float focusDistance)
Set the focal distance.
EQFABRIC_INL void setVRPNTracker(const std::string &index)
Set the VRPN tracker device.
Base data transport class for observers.
FocusMode getFocusMode() const
A visitor to traverse leaf nodes of a graph.
const Matrix4f & getHeadMatrix() const
EQFABRIC_INL void setEyePosition(const Eye eye, const Vector3f &pos)
Set the position of the given eye relative to the observer.
int32_t getOpenCVCamera() const
EQFABRIC_INL const Vector3f & getEyePosition(const Eye eye) const
const std::string & getVRPNTracker() const
Eye
Eye pass bit mask for which is enabled.
LeafVisitor< O > Visitor
The observer visitor type.
vmml::vector< 3, float > Vector3f
A three-component float vector.
float getFocusDistance() const
FocusMode
The algorithm to use for observer focal distance calculation.
vmml::matrix< 4, 4, float > Matrix4f
A 4x4 float matrix.
EQFABRIC_INL VisitorResult accept(Visitor &visitor)
Traverse this observer using a observer visitor.
Internal base class for all distributed, inheritable Equalizer objects.
EQFABRIC_INL void setFocusMode(const FocusMode focusMode)
Set the focal mode.
EQFABRIC_INL void setOpenCVCamera(const int32_t index)
Set the index of the OpenCV camera for tracking.