#include "dshow.h"
#include "wine/debug.h"
#include "wine/unicode.h"
#include "wine/list.h"
#include "wine/strmbase.h"
#include "uuids.h"
#include "vfwmsgs.h"
#include <assert.h>
Go to the source code of this file.
|
| WINE_DEFAULT_DEBUG_CHANNEL (strmbase) |
|
static DWORD WINAPI | OutputQueue_InitialThreadProc (LPVOID data) |
|
static void | OutputQueue_FreeSamples (OutputQueue *pOutputQueue) |
|
HRESULT WINAPI | OutputQueue_Construct (BaseOutputPin *pInputPin, BOOL bAuto, BOOL bQueue, LONG lBatchSize, BOOL bBatchExact, DWORD dwPriority, const OutputQueueFuncTable *pFuncsTable, OutputQueue **ppOutputQueue) |
|
HRESULT WINAPI | OutputQueue_Destroy (OutputQueue *pOutputQueue) |
|
HRESULT WINAPI | OutputQueue_ReceiveMultiple (OutputQueue *pOutputQueue, IMediaSample **ppSamples, LONG nSamples, LONG *nSamplesProcessed) |
|
HRESULT WINAPI | OutputQueue_Receive (OutputQueue *pOutputQueue, IMediaSample *pSample) |
|
VOID WINAPI | OutputQueue_SendAnyway (OutputQueue *pOutputQueue) |
|
VOID WINAPI | OutputQueue_EOS (OutputQueue *pOutputQueue) |
|
DWORD WINAPI | OutputQueueImpl_ThreadProc (OutputQueue *pOutputQueue) |
|
◆ COBJMACROS
◆ QueuedEvent
◆ anonymous enum
Enumerator |
---|
SAMPLE_PACKET | |
EOS_PACKET | |
Definition at line 34 of file outputqueue.c.
◆ OutputQueue_Construct()
Definition at line 60 of file outputqueue.c.
70{
73
75
76 if (!pInputPin || !pFuncsTable || !ppOutputQueue)
78
80 if (!*ppOutputQueue)
82
83 This = *ppOutputQueue;
84 This->pFuncsTable = pFuncsTable;
85 This->lBatchSize = lBatchSize;
86 This->bBatchExact = bBatchExact;
88 This->csQueue.DebugInfo->Spare[0] = (
DWORD_PTR)(__FILE__
": OutputQueue.csQueue");
90
91 This->pInputPin = pInputPin;
93
97 else
98 threaded = bQueue;
99
100 if (threaded)
101 {
104 {
107 }
108 }
110
112}
static void list_init(struct list_entry *head)
BOOL WINAPI SetThreadPriority(IN HANDLE hThread, IN int nPriority)
HANDLE WINAPI DECLSPEC_HOTPATCH CreateThread(IN LPSECURITY_ATTRIBUTES lpThreadAttributes, IN DWORD dwStackSize, IN LPTHREAD_START_ROUTINE lpStartAddress, IN LPVOID lpParameter, IN DWORD dwCreationFlags, OUT LPDWORD lpThreadId)
static DWORD WINAPI OutputQueue_InitialThreadProc(LPVOID data)
IMemInputPin * pMemInputPin
VOID WINAPI InitializeCriticalSection(OUT LPCRITICAL_SECTION lpCriticalSection)
HANDLE WINAPI DECLSPEC_HOTPATCH CreateEventW(IN LPSECURITY_ATTRIBUTES lpEventAttributes OPTIONAL, IN BOOL bManualReset, IN BOOL bInitialState, IN LPCWSTR lpName OPTIONAL)
void WINAPI LeaveCriticalSection(LPCRITICAL_SECTION)
void WINAPI EnterCriticalSection(LPCRITICAL_SECTION)
◆ OutputQueue_Destroy()
Definition at line 114 of file outputqueue.c.
115{
121
125
129}
#define HeapFree(x, y, z)
static void OutputQueue_FreeSamples(OutputQueue *pOutputQueue)
DWORD_PTR Spare[8/sizeof(DWORD_PTR)]
PCRITICAL_SECTION_DEBUG DebugInfo
BaseOutputPin * pInputPin
BOOL WINAPI DECLSPEC_HOTPATCH SetEvent(IN HANDLE hEvent)
void WINAPI DeleteCriticalSection(PCRITICAL_SECTION)
◆ OutputQueue_EOS()
Definition at line 193 of file outputqueue.c.
194{
197 {
199 if (!qev)
200 {
201 ERR(
"Out of Memory\n");
203 return;
204 }
208 }
209 else
210 {
213 if (ppin)
214 {
215 IPin_EndOfStream(ppin);
216 IPin_Release(ppin);
217 }
218 }
220
222}
static void list_add_tail(struct list_entry *head, struct list_entry *entry)
VOID WINAPI OutputQueue_SendAnyway(OutputQueue *pOutputQueue)
◆ OutputQueue_FreeSamples()
Definition at line 49 of file outputqueue.c.
50{
53 {
57 }
58}
static void list_remove(struct list_entry *entry)
#define LIST_FOR_EACH_SAFE(cursor, cursor2, list)
Referenced by OutputQueue_Destroy().
◆ OutputQueue_InitialThreadProc()
◆ OutputQueue_Receive()
Definition at line 173 of file outputqueue.c.
174{
177}
HRESULT WINAPI OutputQueue_ReceiveMultiple(OutputQueue *pOutputQueue, IMediaSample **ppSamples, LONG nSamples, LONG *nSamplesProcessed)
static int processed(const type_t *type)
◆ OutputQueue_ReceiveMultiple()
Definition at line 131 of file outputqueue.c.
132{
135
138
140 {
142 hr = IMemInputPin_ReceiveMultiple(pOutputQueue->
pInputPin->
pMemInputPin,ppSamples, nSamples, nSamplesProcessed);
144 }
145 else
146 {
148 *nSamplesProcessed = 0;
149
150 for (
i = 0;
i < nSamples;
i++)
151 {
153 if (!qev)
154 {
155 ERR(
"Out of Memory\n");
157 break;
158 }
161 IMediaSample_AddRef(ppSamples[
i]);
163 (*nSamplesProcessed)++;
164 }
165
169 }
171}
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
__WINE_SERVER_LIST_INLINE unsigned int list_count(const struct list *list)
#define VFW_E_NOT_CONNECTED
Referenced by OutputQueue_Receive().
◆ OutputQueue_SendAnyway()
◆ OutputQueueImpl_ThreadProc()
Definition at line 224 of file outputqueue.c.
225{
226 do
227 {
233 )
234 )
235 {
237 {
240 LONG nSamplesProcessed;
243
244
247 nSamples = 0;
249 {
252 ppSamples[nSamples++] = qev->
pSample;
253 else
254 break;
257 }
258
260 {
263 IMemInputPin_ReceiveMultiple(pOutputQueue->
pInputPin->
pMemInputPin, ppSamples, nSamples, &nSamplesProcessed);
266 }
267 for (
i = 0;
i < nSamples;
i++)
268 IMediaSample_Release(ppSamples[
i]);
270
271
273 {
276 {
279 if (ppin)
280 {
281 IPin_EndOfStream(ppin);
282 IPin_Release(ppin);
283 }
284 }
286 break;
287 else
288 FIXME(
"Unhandled Event type %i\n",qev->
type);
291 }
292 }
294 }
297 }
300}
DWORD WINAPI WaitForSingleObject(IN HANDLE hHandle, IN DWORD dwMilliseconds)
◆ WINE_DEFAULT_DEBUG_CHANNEL()
WINE_DEFAULT_DEBUG_CHANNEL |
( |
strmbase |
| ) |
|