Nikolay Sivov : evr/presenter: Expose IMFVideoDisplayControl as a service.

Alexandre Julliard julliard at winehq.org
Fri Oct 2 14:54:09 CDT 2020


Module: wine
Branch: master
Commit: 69e777c804e9803bef3e151fc20a363f699692ab
URL:    https://source.winehq.org/git/wine.git/?a=commit;h=69e777c804e9803bef3e151fc20a363f699692ab

Author: Nikolay Sivov <nsivov at codeweavers.com>
Date:   Fri Oct  2 14:01:10 2020 +0300

evr/presenter: Expose IMFVideoDisplayControl as a service.

Signed-off-by: Nikolay Sivov <nsivov at codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>

---

 dlls/evr/presenter.c | 11 +++++++++++
 dlls/evr/tests/evr.c |  4 +---
 2 files changed, 12 insertions(+), 3 deletions(-)

diff --git a/dlls/evr/presenter.c b/dlls/evr/presenter.c
index 04653ff67a..8b5a7dd46a 100644
--- a/dlls/evr/presenter.c
+++ b/dlls/evr/presenter.c
@@ -618,6 +618,17 @@ static HRESULT WINAPI video_presenter_getservice_GetService(IMFGetService *iface
     if (IsEqualGUID(&MR_VIDEO_ACCELERATION_SERVICE, service))
         return IDirect3DDeviceManager9_QueryInterface(presenter->device_manager, riid, obj);
 
+    if (IsEqualGUID(&MR_VIDEO_RENDER_SERVICE, service))
+    {
+        if (IsEqualIID(riid, &IID_IMFVideoDisplayControl))
+            return IMFVideoPresenter_QueryInterface(&presenter->IMFVideoPresenter_iface, riid, obj);
+        else
+        {
+            FIXME("Unsupported interface %s.\n", debugstr_guid(riid));
+            return E_NOTIMPL;
+        }
+    }
+
     FIXME("Unimplemented service %s.\n", debugstr_guid(service));
 
     return E_NOTIMPL;
diff --git a/dlls/evr/tests/evr.c b/dlls/evr/tests/evr.c
index c2e1759555..9665e2683d 100644
--- a/dlls/evr/tests/evr.c
+++ b/dlls/evr/tests/evr.c
@@ -1015,10 +1015,8 @@ static void test_default_presenter(void)
     ok(hr == S_OK, "Unexpected hr %#x.\n", hr);
 
     hr = IMFGetService_GetService(gs, &MR_VIDEO_RENDER_SERVICE, &IID_IMFVideoDisplayControl, (void **)&display_control);
-todo_wine
     ok(hr == S_OK, "Unexpected hr %#x.\n", hr);
-    if (SUCCEEDED(hr))
-        IMFVideoDisplayControl_Release(display_control);
+    IMFVideoDisplayControl_Release(display_control);
 
     hr = IMFGetService_GetService(gs, &MR_VIDEO_ACCELERATION_SERVICE, &IID_IDirect3DDeviceManager9, (void **)&dm);
     ok(hr == S_OK, "Unexpected hr %#x.\n", hr);




More information about the wine-cvs mailing list