BusyWaitVideoSync Class Reference

#include <vsync.h>

Inheritance diagram for BusyWaitVideoSync:

VideoSync

List of all members.


Detailed Description

Video synchronization classes employing usleep() and busy-waits.

Non-phase-maintaining. There may occasionally be short periods of jitter that eventually go away.

This method does not maintain phase and uses the most CPU of any of the VSync methods. But it is the catch-all fallback algorithm, TryInit(void) always succeeds.

Definition at line 265 of file vsync.h.


Public Member Functions

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

Private Attributes

int m_cheat
int m_fudge

Constructor & Destructor Documentation

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

Definition at line 772 of file vsync.cpp.

BusyWaitVideoSync::~BusyWaitVideoSync (  ) 

Definition at line 780 of file vsync.cpp.


Member Function Documentation

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

Returns name of instanciated VSync method.

Implements VideoSync.

Definition at line 273 of file vsync.h.

bool BusyWaitVideoSync::TryInit ( void   )  [virtual]

Tries to initialize VSync method.

Implements VideoSync.

Definition at line 784 of file vsync.cpp.

void BusyWaitVideoSync::WaitForFrame ( int  sync_delay  )  [virtual]

Waits for next a frame or field.

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

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

Implements VideoSync.

Definition at line 789 of file vsync.cpp.

void BusyWaitVideoSync::AdvanceTrigger ( void   )  [virtual]

Use the next frame or field for CalcDelay(void) and WaitForFrame(int).

Implements VideoSync.

Definition at line 819 of file vsync.cpp.


Member Data Documentation

Definition at line 279 of file vsync.h.

Referenced by BusyWaitVideoSync(), and WaitForFrame().

Definition at line 280 of file vsync.h.

Referenced by BusyWaitVideoSync(), and WaitForFrame().


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

Generated on Sat Dec 18 05:16:00 2010 for MythTV by  doxygen 1.5.5