|
MythTV
0.26-pre
|
Video synchronization classes employing only usleep(). More...
#include <vsync.h>
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. | |
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.
| USleepVideoSync::USleepVideoSync | ( | VideoOutput * | vo, |
| int | frame_interval, | ||
| int | refresh_interval, | ||
| bool | interlaced | ||
| ) |
| QString USleepVideoSync::getName | ( | void | ) | const [inline, virtual] |
| bool USleepVideoSync::TryInit | ( | void | ) | [virtual] |
| 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.
| sync_delay | time until the desired frame or field |
Implements VideoSync.
1.7.6.1