mirror of
https://git.rip/DMCA_FUCKER/re3.git
synced 2024-11-05 08:35:54 +00:00
MP3 player fixes
This commit is contained in:
parent
ca65c76419
commit
ca48ebcb6e
|
@ -1908,6 +1908,9 @@ cSampleManager::StopStreamedFile(uint8 nStream)
|
||||||
{
|
{
|
||||||
delete stream;
|
delete stream;
|
||||||
aStream[nStream] = NULL;
|
aStream[nStream] = NULL;
|
||||||
|
|
||||||
|
if ( nStream == 0 )
|
||||||
|
_bIsMp3Active = false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1919,9 +1922,23 @@ cSampleManager::GetStreamedFilePosition(uint8 nStream)
|
||||||
CStream *stream = aStream[nStream];
|
CStream *stream = aStream[nStream];
|
||||||
|
|
||||||
if ( stream )
|
if ( stream )
|
||||||
|
{
|
||||||
|
if ( _bIsMp3Active )
|
||||||
|
{
|
||||||
|
tMP3Entry *mp3 = _GetMP3EntryByIndex(_CurMP3Index);
|
||||||
|
|
||||||
|
if ( mp3 != NULL )
|
||||||
|
{
|
||||||
|
return stream->GetPosMS() + mp3->nTrackStreamPos;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
else
|
||||||
{
|
{
|
||||||
return stream->GetPosMS();
|
return stream->GetPosMS();
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue