ObjectAnimation Class Reference

Collaboration diagram for ObjectAnimation:
Collaboration graph
[legend]

List of all members.

Classes

struct  FrameState
 A structure to hold all necessary information about frame. More...

Signals

void animationChanged ()

Public Member Functions

 ObjectAnimation (int frameNum, FrameRange masterFrameRange, QPointF initialPos)
 Construct a new object animation with a specified framerange and initial position.
FrameState getFrameState (int frameNum)
 Perform position interpolation on the fly.
bool moveKeyframe (int from_fnum, int to_fnum)
 Move a keyframe from one frame to another (likely because of a drag-and-drop operation).
void setPosition (int frameNum, QPointF pos, bool visible=true)
 Insert a new keyframe at frameNumber indicating the object is at position pos.
void constructContextMenu (QPoint pos, int column)
 Draw a dropdown context menu to allow users to modify the animation.
FrameRange getFrameRange () const
 Get the animation framerange.
std::pair< QMap< int,
FrameState >::const_iterator,
QMap< int, FrameState >
::const_iterator > 
getBoundingKeyframes (int fnum)
 Find the bounding keyframes for a given framenumber.
AnimationDelegate::FrameType getFrameType (int fnum)
QMap< int, FrameState > & getKeyFrames ()
void clear ()
 Clear all keyframes from the keyframe storage.

Detailed Description

Definition at line 11 of file ObjectAnimation.qt.H.


Constructor & Destructor Documentation

ObjectAnimation::ObjectAnimation ( int  frameNum,
FrameRange  masterFrameRange,
QPointF  initialPos 
)

Construct a new object animation with a specified framerange and initial position.

The masterFrameRange parameter must be the FrameRange for the entire move so that frames can be properly mapped into the animation.

Definition at line 8 of file ObjectAnimation.qt.C.


Member Function Documentation

void ObjectAnimation::clear (  ) 

Clear all keyframes from the keyframe storage.

Definition at line 271 of file ObjectAnimation.qt.C.

Referenced by AnnotationObject::clearAnimation(), and AnnotationObjectVertex::clearAnimation().

void ObjectAnimation::constructContextMenu ( QPoint  pos,
int  column 
)

Draw a dropdown context menu to allow users to modify the animation.

Definition at line 187 of file ObjectAnimation.qt.C.

References getFrameState().

Referenced by AnnotationObject::constructAnimationContextMenu().

std::pair< QMap< int, ObjectAnimation::FrameState >::const_iterator, QMap< int, ObjectAnimation::FrameState >::const_iterator > ObjectAnimation::getBoundingKeyframes ( int  fnum  ) 

Find the bounding keyframes for a given framenumber.

If the requested frame is either before the first keyframe, or after the last, then both iterators in the pair will just be set to itsKeyframes.end()

Definition at line 24 of file ObjectAnimation.qt.C.

Referenced by getFrameState().

FrameRange ObjectAnimation::getFrameRange (  )  const [inline]
ObjectAnimation::FrameState ObjectAnimation::getFrameState ( int  frameNum  ) 
bool ObjectAnimation::moveKeyframe ( int  from_fnum,
int  to_fnum 
)

Move a keyframe from one frame to another (likely because of a drag-and-drop operation).

Definition at line 156 of file ObjectAnimation.qt.C.

Referenced by AnimationModel::dropMimeData().

void ObjectAnimation::setPosition ( int  frameNum,
QPointF  pos,
bool  visible = true 
)

Insert a new keyframe at frameNumber indicating the object is at position pos.

Definition at line 173 of file ObjectAnimation.qt.C.

Referenced by AnnotationObject::mouseReleaseEvent(), AnnotationObjectVertex::mouseReleaseEvent(), AnnotationObject::setKeyframe(), and AnnotationObjectVertex::setKeyframe().


The documentation for this class was generated from the following files:
Generated on Sun May 8 08:43:38 2011 for iLab Neuromorphic Vision Toolkit by  doxygen 1.6.3