OWLNext 6.32
Public Member Functions | Protected Member Functions
owl::TAnimateCtrl Class Reference

TAnimateCtrl encapsulates a class that plays an .AVI file. More...

#include <animctrl.h>

Inheritance diagram for owl::TAnimateCtrl:
owl::TControl owl::TWindow owl::TEventHandler owl::TStreamableBase

List of all members.

Public Member Functions

 TAnimateCtrl (TWindow *parent, int id, int x, int y, int w, int h, TModule *module=0)
 TAnimateCtrl (TWindow *parent, int resourceId, TModule *module=0)
 ~TAnimateCtrl ()
bool Open (LPCTSTR fileOrRes, TModule *module=0)
bool Open (const tstring &fileOrRes, TModule *module=0)
bool Play (uint16 start=0, uint16 end=-1, uint repeat=1)
bool Seek (uint16 frame)
void Stop ()

Protected Member Functions

virtual TGetClassNameReturnType GetClassName ()

Detailed Description

TAnimateCtrl encapsulates a class that plays an .AVI file.

Encapsulates the Animation Control (a window that silently displays an Audio Video Interleaved, AVI clip).

Note:
This control can only display uncompressed or RLE-compressed AVI files.

Constructor & Destructor Documentation

owl::TAnimateCtrl::TAnimateCtrl ( TWindow parent,
int  id,
int  x,
int  y,
int  w,
int  h,
TModule module = 0 
)

Constructor for a TAnimateCtrl to be associated with a new underlying control.

References owl::TXCommCtrl::Raise().

owl::TAnimateCtrl::TAnimateCtrl ( TWindow parent,
int  resourceId,
TModule module = 0 
)

Constructor to alias a control defined in a dialog resource.

References owl::TXCommCtrl::Raise().

owl::TAnimateCtrl::~TAnimateCtrl ( )

Destructor.


Member Function Documentation

TWindow::TGetClassNameReturnType owl::TAnimateCtrl::GetClassName ( ) [protected, virtual]

Returns the predefined class registered by the Common Control library for the Animation control.

Reimplemented from owl::TWindow.

bool owl::TAnimateCtrl::Open ( LPCTSTR  res,
TModule module = 0 
)

Opens an .AVI file and displays the first frame. The 'res' parameter may be a resourceId if the .AVI is from a resource. It may also be a full path of an .AVI file. Use NULL (0) as 'res' to close any previously opened .AVI file. if module != 0 and version of commctrl.dll >= 4.7 will open resource from this module

References owl::TModule::GetHandle(), and owl::TWindow::SendMessage().

bool owl::TAnimateCtrl::Play ( uint16  start = 0,
uint16  end = -1,
uint  repeat = 1 
)

Plays the .AVI file from frame index 'start' to frame index 'end'. The 'repeat' parameter is the number of times to play the frames. Use -1 for repeat to play indefinitely.

Note:
The control plays the clip in the backgroud while the current thread continues executing.

References owl::TWindow::SendMessage().

bool owl::TAnimateCtrl::Seek ( uint16  frame)

Seek to frame index 'frame'. The value is zero-based and must not exceed 65,536.

References Play().

void owl::TAnimateCtrl::Stop ( )

Stops playing the current AVI file.

References owl::TWindow::SendMessage().


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