{
#ifdef KSPROXY_TRACE
OutputDebugStringW(L"CKsProxy::IsDirty Notimplemented\n");
- DebugBreak();
#endif
return E_NOTIMPL;
}
}while(Length > 0);
- DebugBreak();
return S_OK;
}
{
#ifdef KSPROXY_TRACE
OutputDebugStringW(L"CKsProxy::GetSizeMax Notimplemented\n");
- DebugBreak();
#endif
return E_NOTIMPL;
// query current instance count
hr = GetPinInstanceCount(Index, &Instances);
if (FAILED(hr))
+ {
+#ifdef KSPROXY_TRACE
+ WCHAR Buffer[100];
+ swprintf(Buffer, L"CKsProxy::CreatePins GetPinInstanceCount failed with %lx\n", hr);
+ OutputDebugStringW(Buffer);
+#endif
continue;
+ }
+
// query pin communication;
hr = GetPinCommunication(Index, &Communication);
if (FAILED(hr))
+ {
+#ifdef KSPROXY_TRACE
+ WCHAR Buffer[100];
+ swprintf(Buffer, L"CKsProxy::CreatePins GetPinCommunication failed with %lx\n", hr);
+ OutputDebugStringW(Buffer);
+#endif
continue;
+ }
if (Instances.CurrentCount == Instances.PossibleCount)
{
// already maximum reached for this pin
+#ifdef KSPROXY_TRACE
+ WCHAR Buffer[100];
+ swprintf(Buffer, L"CKsProxy::CreatePins Instances.CurrentCount == Instances.PossibleCount\n");
+ OutputDebugStringW(Buffer);
+#endif
continue;
}
// get direction of pin
hr = GetPinDataflow(Index, &DataFlow);
if (FAILED(hr))
+ {
+#ifdef KSPROXY_TRACE
+ WCHAR Buffer[100];
+ swprintf(Buffer, L"CKsProxy::CreatePins GetPinDataflow failed with %lx\n", hr);
+ OutputDebugStringW(Buffer);
+#endif
continue;
+ }
if (DataFlow == KSPIN_DATAFLOW_IN)
hr = GetPinName(Index, DataFlow, InputPin, &PinName);
hr = GetPinName(Index, DataFlow, OutputPin, &PinName);
if (FAILED(hr))
+ {
+#ifdef KSPROXY_TRACE
+ WCHAR Buffer[100];
+ swprintf(Buffer, L"CKsProxy::CreatePins GetPinName failed with %lx\n", hr);
+ OutputDebugStringW(Buffer);
+#endif
continue;
+ }
// construct the pins
if (DataFlow == KSPIN_DATAFLOW_IN)
hr = CInputPin_Constructor((IBaseFilter*)this, PinName, m_hDevice, Index, Communication, IID_IPin, (void**)&pPin);
if (FAILED(hr))
{
+#ifdef KSPROXY_TRACE
+ WCHAR Buffer[100];
+ swprintf(Buffer, L"CKsProxy::CreatePins CInputPin_Constructor failed with %lx\n", hr);
+ OutputDebugStringW(Buffer);
+#endif
CoTaskMemFree(PinName);
continue;
}
hr = COutputPin_Constructor((IBaseFilter*)this, PinName, Index, Communication, IID_IPin, (void**)&pPin);
if (FAILED(hr))
{
+#ifdef KSPROXY_TRACE
+ WCHAR Buffer[100];
+ swprintf(Buffer, L"CKsProxy::CreatePins COutputPin_Constructor failed with %lx\n", hr);
+ OutputDebugStringW(Buffer);
+#endif
CoTaskMemFree(PinName);
continue;
}
hr = LoadProxyPlugins(pGuid, NumGuids);
if (FAILED(hr))
{
+#if 0 //HACK
CloseHandle(m_hDevice);
m_hDevice = NULL;
return hr;
+#endif
+ OutputDebugStringW(L"CKsProxy::LoadProxyPlugins failed!\n");
}
// free sets
// now create the input / output pins
hr = CreatePins();
+#ifdef KSPROXY_TRACE
+ swprintf(Buffer, L"CKsProxy::Load CreatePins %lx\n", hr);
+ OutputDebugStringW(Buffer);
+#endif
+
+ //HACK
+ hr = S_OK;
+
return hr;
}
CKsProxy::EnumPins(
IEnumPins **ppEnum)
{
-#ifdef KSPROXY_TRACE
- OutputDebugStringW(L"CKsProxy::EnumPins\n");
-#endif
-
return CEnumPins_fnConstructor(m_Pins, IID_IEnumPins, (void**)ppEnum);
}