forked from Mirrors/wine-wine
mfreadwrite: Return sample timestamp from ReadSample().
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>stable
parent
4837234e84
commit
2be769d648
|
@ -850,6 +850,15 @@ static HRESULT WINAPI src_reader_ReadSample(IMFSourceReader *iface, DWORD index,
|
|||
LeaveCriticalSection(&stream->cs);
|
||||
|
||||
TRACE("Got sample %p.\n", *sample);
|
||||
|
||||
if (timestamp)
|
||||
{
|
||||
/* TODO: it's possible timestamp has to be set for some events.
|
||||
For MEEndOfStream it's correct to return 0. */
|
||||
*timestamp = 0;
|
||||
if (*sample)
|
||||
IMFSample_GetSampleTime(*sample, timestamp);
|
||||
}
|
||||
}
|
||||
|
||||
return S_OK;
|
||||
|
|
Loading…
Reference in New Issue