mirror of
https://github.com/SFML/SFML.git
synced 2024-11-29 06:41:05 +08:00
Fixed bug in Music::SetPlayingOffset (didn't work above a given timestamp)
This commit is contained in:
parent
92f14fa853
commit
bc64da0469
@ -257,7 +257,7 @@ void SoundFile::Seek(Uint32 timeOffset)
|
|||||||
{
|
{
|
||||||
if (myFile)
|
if (myFile)
|
||||||
{
|
{
|
||||||
sf_count_t frameOffset = timeOffset * mySampleRate / 1000;
|
sf_count_t frameOffset = static_cast<sf_count_t>(timeOffset) * mySampleRate / 1000;
|
||||||
sf_seek(myFile, frameOffset, SEEK_SET);
|
sf_seek(myFile, frameOffset, SEEK_SET);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user