USleepVideoSync Class Reference

Video synchronization classes employing only usleep(). More...

#include <vsync.h>

Inheritance diagram for USleepVideoSync:
VideoSync

List of all members.

Public Member Functions

 USleepVideoSync (VideoOutput *, int frame_interval, int refresh_interval, bool interlaced)
 ~USleepVideoSync ()
QString getName (void) const
 Returns name of instanciated VSync method.
bool TryInit (void)
 Tries to initialize VSync method.
int WaitForFrame (int sync_delay)
 Waits for next a frame or field.

Detailed Description

Video synchronization classes employing only usleep().

Calls usleep() for the entire remaining frame interval. Horribly inaccurate on < Linux 2.6 kernels; not very accurate there either. Not phase-maintaining. Not tried automatically.

This is only used when MythPlayer's 'disablevideo' is true (i.e. for commercial flagging and for transcoding), since it doesn't waste CPU cycles busy-waiting like BusyWaitVideoSync.

Definition at line 201 of file vsync.h.


Constructor & Destructor Documentation

USleepVideoSync::USleepVideoSync ( VideoOutput vo,
int  frame_interval,
int  refresh_interval,
bool  interlaced 
)

Definition at line 446 of file vsync.cpp.

USleepVideoSync::~USleepVideoSync (  ) 

Definition at line 452 of file vsync.cpp.


Member Function Documentation

QString USleepVideoSync::getName ( void   )  const [inline, virtual]

Returns name of instanciated VSync method.

Implements VideoSync.

Definition at line 209 of file vsync.h.

bool USleepVideoSync::TryInit ( void   )  [virtual]

Tries to initialize VSync method.

Implements VideoSync.

Definition at line 456 of file vsync.cpp.

int USleepVideoSync::WaitForFrame ( int  sync_delay  )  [virtual]

Waits for next a frame or field.

Returns delay to real frame timing in usec

Start(void), WaitForFrame(void), and Stop(void) should always be called from same thread, to prevent bad interactions with threads.

Parameters:
sync_delay time until the desired frame or field
See also:
CalcDelay(void), KeepPhase(void)

Implements VideoSync.

Definition at line 461 of file vsync.cpp.


The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends
Generated on Fri May 25 06:42:29 2012 for MythTV by  doxygen 1.6.3