wine-staging/patches/amstream-GetMultiMediaStream/0001-amstream-Implement-IAMMediaStream-GetMultiMediaStrea.patch

89 lines
3.0 KiB
Diff
Raw Normal View History

From 4d0e6bbc00bd49b8dcfce494bd7380c49f58f92b Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Michael=20M=C3=BCller?= <michael@fds-team.de>
Date: Tue, 28 Jul 2015 18:21:20 +0200
Subject: amstream: Implement IAMMediaStream::GetMultiMediaStream.
---
dlls/amstream/mediastream.c | 40 ++++++++++++++++++++++++++++++++--------
1 file changed, 32 insertions(+), 8 deletions(-)
diff --git a/dlls/amstream/mediastream.c b/dlls/amstream/mediastream.c
index 947be1e..e4e15d7 100644
--- a/dlls/amstream/mediastream.c
+++ b/dlls/amstream/mediastream.c
@@ -110,9 +110,15 @@ static HRESULT WINAPI DirectDrawMediaStreamImpl_IAMMediaStream_GetMultiMediaStre
{
DirectDrawMediaStreamImpl *This = impl_from_DirectDrawMediaStream_IAMMediaStream(iface);
- FIXME("(%p/%p)->(%p) stub!\n", This, iface, multi_media_stream);
+ TRACE("(%p/%p)->(%p) stub!\n", This, iface, multi_media_stream);
- return S_FALSE;
+ if (!multi_media_stream)
+ return E_POINTER;
+
+ IMultiMediaStream_AddRef(This->parent);
+ *multi_media_stream = This->parent;
+
+ return S_OK;
}
static HRESULT WINAPI DirectDrawMediaStreamImpl_IAMMediaStream_GetInformation(IAMMediaStream *iface,
@@ -271,9 +277,15 @@ static HRESULT WINAPI DirectDrawMediaStreamImpl_IDirectDrawMediaStream_GetMultiM
{
DirectDrawMediaStreamImpl *This = impl_from_IDirectDrawMediaStream(iface);
- FIXME("(%p/%p)->(%p) stub!\n", This, iface, ppMultiMediaStream);
+ TRACE("(%p/%p)->(%p) stub!\n", This, iface, ppMultiMediaStream);
- return S_FALSE;
+ if (!ppMultiMediaStream)
+ return E_POINTER;
+
+ IMultiMediaStream_AddRef(This->parent);
+ *ppMultiMediaStream = This->parent;
+
+ return S_OK;
}
static HRESULT WINAPI DirectDrawMediaStreamImpl_IDirectDrawMediaStream_GetInformation(IDirectDrawMediaStream *iface,
@@ -511,9 +523,15 @@ static HRESULT WINAPI AudioMediaStreamImpl_IAMMediaStream_GetMultiMediaStream(IA
{
AudioMediaStreamImpl *This = impl_from_AudioMediaStream_IAMMediaStream(iface);
- FIXME("(%p/%p)->(%p) stub!\n", This, iface, multi_media_stream);
+ TRACE("(%p/%p)->(%p)\n", This, iface, multi_media_stream);
- return S_FALSE;
+ if (!multi_media_stream)
+ return E_POINTER;
+
+ IMultiMediaStream_AddRef(This->parent);
+ *multi_media_stream = This->parent;
+
+ return S_OK;
}
static HRESULT WINAPI AudioMediaStreamImpl_IAMMediaStream_GetInformation(IAMMediaStream *iface,
@@ -672,9 +690,15 @@ static HRESULT WINAPI AudioMediaStreamImpl_IAudioMediaStream_GetMultiMediaStream
{
AudioMediaStreamImpl *This = impl_from_IAudioMediaStream(iface);
- FIXME("(%p/%p)->(%p) stub!\n", iface, This, multimedia_stream);
+ TRACE("(%p/%p)->(%p)\n", iface, This, multimedia_stream);
- return S_FALSE;
+ if (!multimedia_stream)
+ return E_POINTER;
+
+ IMultiMediaStream_AddRef(This->parent);
+ *multimedia_stream = This->parent;
+
+ return S_OK;
}
static HRESULT WINAPI AudioMediaStreamImpl_IAudioMediaStream_GetInformation(IAudioMediaStream *iface,
--
2.4.5