Fix FFMpeg plugin

This commit is contained in:
SirLynix 2023-02-02 21:00:51 +01:00
parent 5a57aca66a
commit 0fe25187e5
1 changed files with 2 additions and 2 deletions

View File

@ -131,7 +131,7 @@ namespace
return Nz::Ok();
}
bool DecodeNextFrame(void* frameBuffer, Nz::UInt64* frameTime) override
bool DecodeNextFrame(void* frameBuffer, Nz::Time* frameTime) override
{
AVPacket packet;
@ -144,7 +144,7 @@ namespace
if (frameTime)
{
AVRational timebase = m_formatContext->streams[m_videoStream]->time_base;
*frameTime = 1000 * m_formatContext->streams[m_videoStream]->duration * timebase.num / timebase.den;
*frameTime = Nz::Time::Milliseconds(1000 * m_formatContext->streams[m_videoStream]->duration * timebase.num / timebase.den);
}
return false;