Aric Stewart : quartz: If the MediaSeeking is not implemented all the way up the passthru chain fall back to the filtergraph 's clock to find position.

Alexandre Julliard julliard at winehq.org
Wed Feb 1 11:23:26 CST 2012


Module: wine
Branch: master
Commit: 53bd62737c3f1ad1237a8c47d1319c64abc7a7b0
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=53bd62737c3f1ad1237a8c47d1319c64abc7a7b0

Author: Aric Stewart <aric at codeweavers.com>
Date:   Tue Jan 31 13:52:27 2012 -0600

quartz: If the MediaSeeking is not implemented all the way up the passthru chain fall back to the filtergraph's clock to find position.

---

 dlls/quartz/filtergraph.c |    9 ++++++++-
 1 files changed, 8 insertions(+), 1 deletions(-)

diff --git a/dlls/quartz/filtergraph.c b/dlls/quartz/filtergraph.c
index 32aa569..911e68c 100644
--- a/dlls/quartz/filtergraph.c
+++ b/dlls/quartz/filtergraph.c
@@ -2456,7 +2456,14 @@ static HRESULT WINAPI MediaSeeking_GetCurrentPosition(IMediaSeeking *iface, LONG
     *pCurrent = -1;
     hr = all_renderers_seek(This, FoundCurrentPosition, (DWORD_PTR)pCurrent);
     if (hr == E_NOTIMPL) {
-        *pCurrent = 0;
+        LONGLONG time = 0;
+        if (This->refClock)
+        {
+            IReferenceClock_GetTime(This->refClock, &time);
+            if (time)
+                time -= This->start_time;
+        }
+        *pCurrent = time;
         hr = S_OK;
     }
     LeaveCriticalSection(&This->cs);




More information about the wine-cvs mailing list