diff options
author | Johannes Schickel | 2010-03-22 15:54:56 +0000 |
---|---|---|
committer | Johannes Schickel | 2010-03-22 15:54:56 +0000 |
commit | 86653687d7369a46ac25ef4a3cd513b401807c67 (patch) | |
tree | 72b8042a9325fbf89e0271d37e484d86d5973c9f /sound/audiostream.h | |
parent | a725b490e8a190e276fc689d4a147b7c49e98d7c (diff) | |
download | scummvm-rg350-86653687d7369a46ac25ef4a3cd513b401807c67.tar.gz scummvm-rg350-86653687d7369a46ac25ef4a3cd513b401807c67.tar.bz2 scummvm-rg350-86653687d7369a46ac25ef4a3cd513b401807c67.zip |
Fix for bug #2969211 "NIPPON: Crash in Intro".
It is not a good idea to supply an SubLoopingAudioStream with the start
and end time to be exactly the same time. Clarify that in the
SubLoopingAudioStream documentation, add an assert in the
SubLoopingAudioStream constructor for that case and also prevent
make8SVXStream from doing so.
svn-id: r48356
Diffstat (limited to 'sound/audiostream.h')
-rw-r--r-- | sound/audiostream.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/sound/audiostream.h b/sound/audiostream.h index 1cb6a422c2..37a1953bb9 100644 --- a/sound/audiostream.h +++ b/sound/audiostream.h @@ -229,6 +229,16 @@ AudioStream *makeLoopingAudioStream(SeekableAudioStream *stream, Timestamp start */ class SubLoopingAudioStream : public AudioStream { public: + /** + * Constructor for a SubLoopingAudioStream. + * + * @param stream Stream to loop + * @param loops How often the stream should be looped (0 means infinite) + * @param loopStart Start of the loop (this must be smaller than loopEnd) + * @param loopEnd End of the loop (thus must be greater than loopStart) + * @param disposeAfterUse Whether the stream should be disposed, when the + * SubLoopingAudioStream is destroyed. + */ SubLoopingAudioStream(SeekableAudioStream *stream, uint loops, const Timestamp loopStart, const Timestamp loopEnd, |