/*****************************************************************************
- * filter.c : DirectShow access module for vlc
+ * filter.cpp : DirectShow access module for vlc
*****************************************************************************
* Copyright (C) 2002-2010 the VideoLAN team
* $Id$
#include "filter.h"
#include "vlc_dshow.h"
+#include <initguid.h>
+DEFINE_GUID(MEDIASUBTYPE_HDYC ,0x43594448 /* CYDH */ , 0x0000, 0x0010, 0x80, 0x00, 0x00, 0xaa, 0x00, 0x38, 0x9b, 0x71);
+DEFINE_GUID(MEDIASUBTYPE_DIVX ,0x58564944 /* XVID */ , 0x0000, 0x0010, 0x80, 0x00, 0x00, 0xaa, 0x00, 0x38, 0x9b, 0x71);
+
+
#define DEBUG_DSHOW 1
#define FILTER_NAME L"VideoLAN Capture Filter"
};
/* IPin methods */
-STDMETHODIMP CapturePin::Connect( IPin * pReceivePin,
+STDMETHODIMP CapturePin::Connect( IPin *,
const AM_MEDIA_TYPE *pmt )
{
if( State_Running == p_filter->state )
return NOERROR;
}
-STDMETHODIMP CapturePin::QueryInternalConnections( IPin* *apPin, ULONG *nPin )
+STDMETHODIMP CapturePin::QueryInternalConnections( IPin**, ULONG * )
{
#ifdef DEBUG_DSHOW_L1
msg_Dbg( p_input, "CapturePin::QueryInternalConnections" );
return S_OK;
}
-STDMETHODIMP CapturePin::NewSegment( REFERENCE_TIME tStart,
- REFERENCE_TIME tStop,
- double dRate )
+STDMETHODIMP CapturePin::NewSegment( REFERENCE_TIME, REFERENCE_TIME, double )
{
#ifdef DEBUG_DSHOW
msg_Dbg( p_input, "CapturePin::NewSegment" );
}
/* IMemInputPin methods */
-STDMETHODIMP CapturePin::GetAllocator( IMemAllocator **ppAllocator )
+STDMETHODIMP CapturePin::GetAllocator( IMemAllocator ** )
{
#ifdef DEBUG_DSHOW
msg_Dbg( p_input, "CapturePin::GetAllocator" );
return VFW_E_NO_ALLOCATOR;
}
-STDMETHODIMP CapturePin::NotifyAllocator( IMemAllocator *pAllocator,
- BOOL bReadOnly )
+STDMETHODIMP CapturePin::NotifyAllocator( IMemAllocator *, BOOL )
{
#ifdef DEBUG_DSHOW
msg_Dbg( p_input, "CapturePin::NotifyAllocator" );
return S_OK;
}
-STDMETHODIMP CapturePin::GetAllocatorRequirements( ALLOCATOR_PROPERTIES *pProps )
+STDMETHODIMP CapturePin::GetAllocatorRequirements( ALLOCATOR_PROPERTIES * )
{
#ifdef DEBUG_DSHOW
msg_Dbg( p_input, "CapturePin::GetAllocatorRequirements" );
};
/* IPersist method */
-STDMETHODIMP CaptureFilter::GetClassID(CLSID *pClsID)
+STDMETHODIMP CaptureFilter::GetClassID(CLSID *)
{
#ifdef DEBUG_DSHOW
msg_Dbg( p_input, "CaptureFilter::GetClassID" );
};
/* IMediaFilter methods */
-STDMETHODIMP CaptureFilter::GetState(DWORD dwMSecs, FILTER_STATE *State)
+STDMETHODIMP CaptureFilter::GetState(DWORD, FILTER_STATE *State)
{
#ifdef DEBUG_DSHOW
msg_Dbg( p_input, "CaptureFilter::GetState %i", state );
*State = state;
return S_OK;
};
-STDMETHODIMP CaptureFilter::SetSyncSource(IReferenceClock *pClock)
+STDMETHODIMP CaptureFilter::SetSyncSource(IReferenceClock *)
{
#ifdef DEBUG_DSHOW
msg_Dbg( p_input, "CaptureFilter::SetSyncSource" );
state = State_Paused;
return S_OK;
};
-STDMETHODIMP CaptureFilter::Run(REFERENCE_TIME tStart)
+STDMETHODIMP CaptureFilter::Run(REFERENCE_TIME)
{
#ifdef DEBUG_DSHOW
msg_Dbg( p_input, "CaptureFilter::Run" );
*ppEnum = new CaptureEnumPins( p_input, this, NULL );
return *ppEnum == NULL ? E_OUTOFMEMORY : NOERROR;
};
-STDMETHODIMP CaptureFilter::FindPin( LPCWSTR Id, IPin ** ppPin )
+STDMETHODIMP CaptureFilter::FindPin( LPCWSTR, IPin ** )
{
#ifdef DEBUG_DSHOW
msg_Dbg( p_input, "CaptureFilter::FindPin" );
return NOERROR;
};
STDMETHODIMP CaptureFilter::JoinFilterGraph( IFilterGraph * pGraph,
- LPCWSTR pName )
+ LPCWSTR )
{
#ifdef DEBUG_DSHOW
msg_Dbg( p_input, "CaptureFilter::JoinFilterGraph" );
return NOERROR;
};
-STDMETHODIMP CaptureFilter::QueryVendorInfo( LPWSTR* pVendorInfo )
+STDMETHODIMP CaptureFilter::QueryVendorInfo( LPWSTR* )
{
#ifdef DEBUG_DSHOW
msg_Dbg( p_input, "CaptureFilter::QueryVendorInfo" );