Qt
Internal/Contributor docs for the Qt SDK. <b>Note:</b> These are NOT official API docs; those are found <a href='https://doc.qt.io/'>here</a>.
Loading...
Searching...
No Matches
Scheduler Class Reference

#include <evrcustompresenter_p.h>

+ Collaboration diagram for Scheduler:

Public Types

enum  ScheduleEvent { Terminate = WM_USER , Schedule = WM_USER + 1 , Flush = WM_USER + 2 }
 

Public Member Functions

 Scheduler (EVRCustomPresenter *presenter)
 
 ~Scheduler ()
 
void setFrameRate (const MFRatio &fps)
 
void setClockRate (float rate)
 
HRESULT startScheduler (ComPtr< IMFClock > clock)
 
HRESULT stopScheduler ()
 
HRESULT scheduleSample (const ComPtr< IMFSample > &sample, bool presentNow)
 
HRESULT processSamplesInQueue (LONG *nextSleep)
 
HRESULT flush ()
 
bool areSamplesScheduled ()
 

Static Public Member Functions

static DWORD WINAPI schedulerThreadProc (LPVOID parameter)
 

Detailed Description

Definition at line 96 of file evrcustompresenter_p.h.

Member Enumeration Documentation

◆ ScheduleEvent

Enumerator
Terminate 
Schedule 
Flush 

Definition at line 100 of file evrcustompresenter_p.h.

Constructor & Destructor Documentation

◆ Scheduler()

Scheduler::Scheduler ( EVRCustomPresenter * presenter)

Definition at line 75 of file evrcustompresenter.cpp.

◆ ~Scheduler()

Scheduler::~Scheduler ( )

Definition at line 83 of file evrcustompresenter.cpp.

References QList< T >::clear().

+ Here is the call graph for this function:

Member Function Documentation

◆ areSamplesScheduled()

bool Scheduler::areSamplesScheduled ( )

Definition at line 198 of file evrcustompresenter.cpp.

References QList< T >::count().

+ Here is the call graph for this function:

◆ flush()

HRESULT Scheduler::flush ( )

Definition at line 182 of file evrcustompresenter.cpp.

References Flush, QUniqueHandle< HandleTraits >::get(), and SCHEDULER_TIMEOUT.

Referenced by EVRCustomPresenter::~EVRCustomPresenter().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ processSamplesInQueue()

HRESULT Scheduler::processSamplesInQueue ( LONG * nextSleep)

Definition at line 236 of file evrcustompresenter.cpp.

References QMutex::lock(), EVRCustomPresenter::presentSample(), QQueue< T >::swap(), and QMutex::unlock().

+ Here is the call graph for this function:

◆ schedulerThreadProc()

DWORD WINAPI Scheduler::schedulerThreadProc ( LPVOID parameter)
static

Definition at line 327 of file evrcustompresenter.cpp.

Referenced by startScheduler().

+ Here is the caller graph for this function:

◆ scheduleSample()

HRESULT Scheduler::scheduleSample ( const ComPtr< IMFSample > & sample,
bool presentNow )

Definition at line 204 of file evrcustompresenter.cpp.

References QQueue< T >::enqueue(), QUniqueHandle< HandleTraits >::get(), QMutex::lock(), EVRCustomPresenter::presentSample(), qCDebug, qt_evr_isSampleTimePassed(), Schedule, and QMutex::unlock().

+ Here is the call graph for this function:

◆ setClockRate()

void Scheduler::setClockRate ( float rate)
inline

Definition at line 111 of file evrcustompresenter_p.h.

Referenced by EVRCustomPresenter::OnClockSetRate().

+ Here is the caller graph for this function:

◆ setFrameRate()

void Scheduler::setFrameRate ( const MFRatio & fps)

Definition at line 88 of file evrcustompresenter.cpp.

◆ startScheduler()

HRESULT Scheduler::startScheduler ( ComPtr< IMFClock > clock)

Definition at line 99 of file evrcustompresenter.cpp.

References done, QUniqueHandle< HandleTraits >::get(), and schedulerThreadProc().

+ Here is the call graph for this function:

◆ stopScheduler()

HRESULT Scheduler::stopScheduler ( )

Definition at line 156 of file evrcustompresenter.cpp.

References QList< T >::clear(), QUniqueHandle< HandleTraits >::get(), QMutex::lock(), Terminate, and QMutex::unlock().

Referenced by EVRCustomPresenter::~EVRCustomPresenter().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

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