Nikolay Sivov : mfplay: Implement GetDuration() for media items.
Alexandre Julliard
julliard at winehq.org
Wed Apr 7 15:48:30 CDT 2021
Module: wine
Branch: master
Commit: 4c77a97037b35d8fed52a9aebe7b86c32412f086
URL: https://source.winehq.org/git/wine.git/?a=commit;h=4c77a97037b35d8fed52a9aebe7b86c32412f086
Author: Nikolay Sivov <nsivov at codeweavers.com>
Date: Wed Apr 7 11:07:03 2021 +0300
mfplay: Implement GetDuration() for media items.
Signed-off-by: Nikolay Sivov <nsivov at codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>
---
dlls/mfplay/player.c | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/dlls/mfplay/player.c b/dlls/mfplay/player.c
index 9ef926f00f6..ddc83e9f441 100644
--- a/dlls/mfplay/player.c
+++ b/dlls/mfplay/player.c
@@ -407,9 +407,11 @@ static HRESULT WINAPI media_item_IsProtected(IMFPMediaItem *iface, BOOL *protect
static HRESULT WINAPI media_item_GetDuration(IMFPMediaItem *iface, REFGUID format, PROPVARIANT *value)
{
- FIXME("%p, %s, %p.\n", iface, debugstr_guid(format), value);
+ struct media_item *item = impl_from_IMFPMediaItem(iface);
- return E_NOTIMPL;
+ TRACE("%p, %s, %p.\n", iface, debugstr_guid(format), value);
+
+ return IMFPresentationDescriptor_GetItem(item->pd, &MF_PD_DURATION, value);
}
static HRESULT WINAPI media_item_GetNumberOfStreams(IMFPMediaItem *iface, DWORD *count)
More information about the wine-cvs
mailing list