TuttleOFX  1
OFX::Interact Class Reference

Wraps up an OFX interact object for an Image Effect. It won't work for any other plug-in type at present (it would need to be broken into a hierarchy of classes). More...

#include <ofxsInteract.h>

Inheritance diagram for OFX::Interact:
Collaboration diagram for OFX::Interact:

Public Member Functions

 Interact (OfxInteractHandle handle)
 ctor
virtual ~Interact ()=0
 virtual destructor
bool verifyMagic () const
PropertySetgetProperties ()
int getBitDepth (void) const
 The bitdepth of each component in the openGL frame buffer.
bool hasAlpha (void) const
 Does the openGL frame buffer have an alpha.
OfxPointD getPixelScale (void) const
 Returns the size of a real screen pixel under the interact's cannonical projection.
OfxRGBColourD getBackgroundColour (void) const
 the background colour
void addParamToSlaveTo (Param *p)
 Set a param that the interact should be redrawn on if its value changes.
void removeParamToSlaveTo (Param *p)
 Remova a param that the interact should be redrawn on if its value changes.
void requestRedraw (void) const
 Request a redraw.
void swapBuffers (void) const
 Swap a buffer in the case of a double bufferred interact, this is possibly a silly one.

Protected Attributes

OfxInteractHandle _interactHandle
 The handle for this interact.
PropertySet _interactProperties
 The property set on this interact.
std::list< Param * > _slaveParams
 List of params we are currently slaved to.
ImageEffect_effect
 The instance we are associated with.

Private Attributes

const int _magic
 to check for handles being nice

Static Private Attributes

static const int kMagic = 0x06012013
 magic number for Interact, and current day :-)

Detailed Description

Wraps up an OFX interact object for an Image Effect. It won't work for any other plug-in type at present (it would need to be broken into a hierarchy of classes).

Definition at line 176 of file ofxsInteract.h.


Constructor & Destructor Documentation

OFX::Interact::~Interact ( ) [pure virtual]

virtual destructor

Definition at line 200 of file ofxsInteract.cpp.


Member Function Documentation

void OFX::Interact::addParamToSlaveTo ( Param p)

Set a param that the interact should be redrawn on if its value changes.

Definition at line 242 of file ofxsInteract.cpp.

References _interactProperties, _slaveParams, OFX::Attribute::getName(), kOfxInteractPropSlaveToParam, OFX::PropertySet::propGetDimension(), and OFX::PropertySet::propSetString().

Here is the call graph for this function:

OfxRGBColourD OFX::Interact::getBackgroundColour ( void  ) const

the background colour

Definition at line 283 of file ofxsInteract.cpp.

References _interactProperties.

int OFX::Interact::getBitDepth ( void  ) const

The bitdepth of each component in the openGL frame buffer.

Definition at line 204 of file ofxsInteract.cpp.

References _interactProperties, kOfxInteractPropBitDepth, and OFX::PropertySet::propGetInt().

Here is the call graph for this function:

OfxPointD OFX::Interact::getPixelScale ( void  ) const

Returns the size of a real screen pixel under the interact's cannonical projection.

Definition at line 216 of file ofxsInteract.cpp.

References _interactProperties, kOfxInteractPropPixelScale, OFX::PropertySet::propGetDouble(), OfxPointD::x, and OfxPointD::y.

Here is the call graph for this function:

PropertySet& OFX::Interact::getProperties ( ) [inline]

Definition at line 197 of file ofxsInteract.h.

References _interactProperties.

bool OFX::Interact::hasAlpha ( void  ) const

Does the openGL frame buffer have an alpha.

Definition at line 210 of file ofxsInteract.cpp.

References _interactProperties, kOfxInteractPropHasAlpha, and OFX::PropertySet::propGetInt().

Here is the call graph for this function:

void OFX::Interact::removeParamToSlaveTo ( Param p)

Remova a param that the interact should be redrawn on if its value changes.

Definition at line 260 of file ofxsInteract.cpp.

References _interactProperties, _slaveParams, kOfxInteractPropSlaveToParam, OFX::PropertySet::propReset(), and OFX::PropertySet::propSetString().

Here is the call graph for this function:

void OFX::Interact::requestRedraw ( void  ) const

Request a redraw.

Definition at line 226 of file ofxsInteract.cpp.

References _interactHandle, OFX::Private::gInteractSuite, OfxInteractSuiteV1::interactRedraw, and OFX::throwSuiteStatusException().

Here is the call graph for this function:

void OFX::Interact::swapBuffers ( void  ) const

Swap a buffer in the case of a double bufferred interact, this is possibly a silly one.

Definition at line 234 of file ofxsInteract.cpp.

References _interactHandle, OFX::Private::gInteractSuite, OfxInteractSuiteV1::interactSwapBuffers, and OFX::throwSuiteStatusException().

Here is the call graph for this function:

bool OFX::Interact::verifyMagic ( ) const [inline]

Definition at line 195 of file ofxsInteract.h.

References _magic, and kMagic.

Referenced by OFX::Private::interactMainEntry().


Field Documentation

The handle for this interact.

Definition at line 179 of file ofxsInteract.h.

Referenced by requestRedraw(), and swapBuffers().

const int OFX::Interact::_magic [private]

to check for handles being nice

Definition at line 186 of file ofxsInteract.h.

Referenced by verifyMagic().

std::list<Param*> OFX::Interact::_slaveParams [protected]

List of params we are currently slaved to.

Definition at line 181 of file ofxsInteract.h.

Referenced by addParamToSlaveTo(), and removeParamToSlaveTo().

const int OFX::Interact::kMagic = 0x06012013 [static, private]

magic number for Interact, and current day :-)

Definition at line 185 of file ofxsInteract.h.

Referenced by verifyMagic().


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