Commit e78ea286 authored by Alexandre Julliard's avatar Alexandre Julliard

quartz: Make some functions and variables static.

parent c42130f0
...@@ -81,7 +81,7 @@ struct IAMFilterData ...@@ -81,7 +81,7 @@ struct IAMFilterData
{ {
const IAMFilterDataVtbl *lpVtbl; const IAMFilterDataVtbl *lpVtbl;
}; };
const GUID IID_IAMFilterData = { static const GUID IID_IAMFilterData = {
0x97f7c4d4, 0x547b, 0x4a5f, { 0x83,0x32, 0x53,0x64,0x30,0xad,0x2e,0x4d } 0x97f7c4d4, 0x547b, 0x4a5f, { 0x83,0x32, 0x53,0x64,0x30,0xad,0x2e,0x4d }
}; };
......
...@@ -241,26 +241,6 @@ const char * qzdebugstr_guid( const GUID * id ) ...@@ -241,26 +241,6 @@ const char * qzdebugstr_guid( const GUID * id )
return debugstr_guid(id); return debugstr_guid(id);
} }
/***********************************************************************
* qzdebugstr_State (internal)
*
* Gives a text version of the FILTER_STATE enumeration
*/
const char * qzdebugstr_State(FILTER_STATE state)
{
switch (state)
{
case State_Stopped:
return "State_Stopped";
case State_Running:
return "State_Running";
case State_Paused:
return "State_Paused";
default:
return "State_Unknown";
}
}
LONG WINAPI AmpFactorToDB(LONG ampfactor) LONG WINAPI AmpFactorToDB(LONG ampfactor)
{ {
FIXME("(%d) Stub!\n", ampfactor); FIXME("(%d) Stub!\n", ampfactor);
......
...@@ -31,24 +31,26 @@ ...@@ -31,24 +31,26 @@
WINE_DEFAULT_DEBUG_CHANNEL(quartz); WINE_DEFAULT_DEBUG_CHANNEL(quartz);
void dump_AM_SAMPLE2_PROPERTIES(const AM_SAMPLE2_PROPERTIES * pProps) typedef struct BaseMemAllocator
{ {
if (!pProps) const IMemAllocatorVtbl * lpVtbl;
{
TRACE("AM_SAMPLE2_PROPERTIES: (null)\n"); LONG ref;
return; ALLOCATOR_PROPERTIES props;
} HRESULT (* fnAlloc) (IMemAllocator *);
TRACE("\tcbData: %d\n", pProps->cbData); HRESULT (* fnFree)(IMemAllocator *);
TRACE("\tdwTypeSpecificFlags: 0x%8x\n", pProps->dwTypeSpecificFlags); HRESULT (* fnVerify)(IMemAllocator *, ALLOCATOR_PROPERTIES *);
TRACE("\tdwSampleFlags: 0x%8x\n", pProps->dwSampleFlags); HRESULT (* fnBufferPrepare)(IMemAllocator *, StdMediaSample2 *, DWORD flags);
TRACE("\tlActual: %d\n", pProps->lActual); HRESULT (* fnBufferReleased)(IMemAllocator *, StdMediaSample2 *);
TRACE("\ttStart: %x%08x%s\n", (LONG)(pProps->tStart >> 32), (LONG)pProps->tStart, pProps->dwSampleFlags & AM_SAMPLE_TIMEVALID ? "" : " (not valid)"); void (* fnDestroyed)(IMemAllocator *);
TRACE("\ttStop: %x%08x%s\n", (LONG)(pProps->tStop >> 32), (LONG)pProps->tStop, pProps->dwSampleFlags & AM_SAMPLE_STOPVALID ? "" : " (not valid)"); HANDLE hSemWaiting;
TRACE("\tdwStreamId: 0x%x\n", pProps->dwStreamId); BOOL bDecommitQueued;
TRACE("\tpMediaType: %p\n", pProps->pMediaType); BOOL bCommitted;
TRACE("\tpbBuffer: %p\n", pProps->pbBuffer); LONG lWaiting;
TRACE("\tcbBuffer: %d\n", pProps->cbBuffer); struct list free_list;
} struct list used_list;
CRITICAL_SECTION *pCritSect;
} BaseMemAllocator;
static const IMemAllocatorVtbl BaseMemAllocator_VTable; static const IMemAllocatorVtbl BaseMemAllocator_VTable;
static const IMediaSample2Vtbl StdMediaSample2_VTable; static const IMediaSample2Vtbl StdMediaSample2_VTable;
...@@ -57,14 +59,14 @@ static const IMediaSample2Vtbl StdMediaSample2_VTable; ...@@ -57,14 +59,14 @@ static const IMediaSample2Vtbl StdMediaSample2_VTable;
#define INVALID_MEDIA_TIME (((ULONGLONG)0x7fffffff << 32) | 0xffffffff) #define INVALID_MEDIA_TIME (((ULONGLONG)0x7fffffff << 32) | 0xffffffff)
HRESULT BaseMemAllocator_Init(HRESULT (* fnAlloc)(IMemAllocator *), static HRESULT BaseMemAllocator_Init(HRESULT (* fnAlloc)(IMemAllocator *),
HRESULT (* fnFree)(IMemAllocator *), HRESULT (* fnFree)(IMemAllocator *),
HRESULT (* fnVerify)(IMemAllocator *, ALLOCATOR_PROPERTIES *), HRESULT (* fnVerify)(IMemAllocator *, ALLOCATOR_PROPERTIES *),
HRESULT (* fnBufferPrepare)(IMemAllocator *, StdMediaSample2 *, DWORD), HRESULT (* fnBufferPrepare)(IMemAllocator *, StdMediaSample2 *, DWORD),
HRESULT (* fnBufferReleased)(IMemAllocator *, StdMediaSample2 *), HRESULT (* fnBufferReleased)(IMemAllocator *, StdMediaSample2 *),
void (* fnDestroyed)(IMemAllocator *), void (* fnDestroyed)(IMemAllocator *),
CRITICAL_SECTION *pCritSect, CRITICAL_SECTION *pCritSect,
BaseMemAllocator * pMemAlloc) BaseMemAllocator * pMemAlloc)
{ {
assert(fnAlloc && fnFree && fnDestroyed); assert(fnAlloc && fnFree && fnDestroyed);
...@@ -399,7 +401,7 @@ static const IMemAllocatorVtbl BaseMemAllocator_VTable = ...@@ -399,7 +401,7 @@ static const IMemAllocatorVtbl BaseMemAllocator_VTable =
BaseMemAllocator_ReleaseBuffer BaseMemAllocator_ReleaseBuffer
}; };
HRESULT StdMediaSample2_Construct(BYTE * pbBuffer, LONG cbBuffer, IMemAllocator * pParent, StdMediaSample2 ** ppSample) static HRESULT StdMediaSample2_Construct(BYTE * pbBuffer, LONG cbBuffer, IMemAllocator * pParent, StdMediaSample2 ** ppSample)
{ {
assert(pbBuffer && pParent && (cbBuffer > 0)); assert(pbBuffer && pParent && (cbBuffer > 0));
...@@ -423,7 +425,7 @@ HRESULT StdMediaSample2_Construct(BYTE * pbBuffer, LONG cbBuffer, IMemAllocator ...@@ -423,7 +425,7 @@ HRESULT StdMediaSample2_Construct(BYTE * pbBuffer, LONG cbBuffer, IMemAllocator
return S_OK; return S_OK;
} }
void StdMediaSample2_Delete(StdMediaSample2 * This) static void StdMediaSample2_Delete(StdMediaSample2 * This)
{ {
/* NOTE: does not remove itself from the list it belongs to */ /* NOTE: does not remove itself from the list it belongs to */
CoTaskMemFree(This); CoTaskMemFree(This);
......
...@@ -747,7 +747,7 @@ static HRESULT WINAPI Parser_PullPin_Disconnect(IPin * iface) ...@@ -747,7 +747,7 @@ static HRESULT WINAPI Parser_PullPin_Disconnect(IPin * iface)
return hr; return hr;
} }
HRESULT WINAPI Parser_PullPin_ReceiveConnection(IPin * iface, IPin * pReceivePin, const AM_MEDIA_TYPE * pmt) static HRESULT WINAPI Parser_PullPin_ReceiveConnection(IPin * iface, IPin * pReceivePin, const AM_MEDIA_TYPE * pmt)
{ {
HRESULT hr; HRESULT hr;
......
...@@ -76,7 +76,6 @@ HRESULT IEnumRegFiltersImpl_Construct(REGFILTER * pInRegFilters, const ULONG siz ...@@ -76,7 +76,6 @@ HRESULT IEnumRegFiltersImpl_Construct(REGFILTER * pInRegFilters, const ULONG siz
HRESULT IEnumFiltersImpl_Construct(IBaseFilter ** ppFilters, ULONG nFilters, IEnumFilters ** ppEnum); HRESULT IEnumFiltersImpl_Construct(IBaseFilter ** ppFilters, ULONG nFilters, IEnumFilters ** ppEnum);
extern const char * qzdebugstr_guid(const GUID * id); extern const char * qzdebugstr_guid(const GUID * id);
extern const char * qzdebugstr_State(FILTER_STATE state);
HRESULT CopyMediaType(AM_MEDIA_TYPE * pDest, const AM_MEDIA_TYPE *pSrc); HRESULT CopyMediaType(AM_MEDIA_TYPE * pDest, const AM_MEDIA_TYPE *pSrc);
void FreeMediaType(AM_MEDIA_TYPE * pmt); void FreeMediaType(AM_MEDIA_TYPE * pmt);
...@@ -97,37 +96,4 @@ typedef struct StdMediaSample2 ...@@ -97,37 +96,4 @@ typedef struct StdMediaSample2
LONGLONG tMediaEnd; LONGLONG tMediaEnd;
} StdMediaSample2; } StdMediaSample2;
typedef struct BaseMemAllocator
{
const IMemAllocatorVtbl * lpVtbl;
LONG ref;
ALLOCATOR_PROPERTIES props;
HRESULT (* fnAlloc) (IMemAllocator *);
HRESULT (* fnFree)(IMemAllocator *);
HRESULT (* fnVerify)(IMemAllocator *, ALLOCATOR_PROPERTIES *);
HRESULT (* fnBufferPrepare)(IMemAllocator *, StdMediaSample2 *, DWORD flags);
HRESULT (* fnBufferReleased)(IMemAllocator *, StdMediaSample2 *);
void (* fnDestroyed)(IMemAllocator *);
HANDLE hSemWaiting;
BOOL bDecommitQueued;
BOOL bCommitted;
LONG lWaiting;
struct list free_list;
struct list used_list;
CRITICAL_SECTION *pCritSect;
} BaseMemAllocator;
HRESULT BaseMemAllocator_Init(HRESULT (* fnAlloc)(IMemAllocator *),
HRESULT (* fnFree)(IMemAllocator *),
HRESULT (* fnVerify)(IMemAllocator *, ALLOCATOR_PROPERTIES *),
HRESULT (* fnBufferPrepare)(IMemAllocator *, StdMediaSample2 *, DWORD),
HRESULT (* fnBufferReleased)(IMemAllocator *, StdMediaSample2 *),
void (* fnDestroyed)(IMemAllocator *),
CRITICAL_SECTION *pCritSect,
BaseMemAllocator * pMemAlloc);
HRESULT StdMediaSample2_Construct(BYTE * pbBuffer, LONG cbBuffer, IMemAllocator * pParent, StdMediaSample2 ** ppSample);
void StdMediaSample2_Delete(StdMediaSample2 * This);
#endif /* __QUARTZ_PRIVATE_INCLUDED__ */ #endif /* __QUARTZ_PRIVATE_INCLUDED__ */
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment