[Commits] SDL_mixer: The seek position is an absolute one, not a skip from...

libsdl.org revision control commits-owner at libsdl.org
Sat Jan 14 19:03:33 PST 2012


details:   http://hg.libsdl.org/SDL_mixer/rev/64688955a7b2
changeset: 565:64688955a7b2
user:      Sam Lantinga <slouken at libsdl.org>
date:      Sat Jan 14 22:00:29 2012 -0500
description:
The seek position is an absolute one, not a skip from the current time.

diffstat:

 music.c |  5 ++---
 1 files changed, 2 insertions(+), 3 deletions(-)

diffs (17 lines):

diff -r 2aee47b6dc73 -r 64688955a7b2 music.c
--- a/music.c	Sat Jan 14 19:52:34 2012 -0500
+++ b/music.c	Sat Jan 14 22:00:29 2012 -0500
@@ -1064,11 +1064,10 @@
 #endif
 #ifdef MP3_MUSIC
 	    case MUS_MP3:
+		smpeg.SMPEG_rewind(music_playing->data.mp3);
+		smpeg.SMPEG_play(music_playing->data.mp3);
 		if ( position > 0.0 ) {
 			smpeg.SMPEG_skip(music_playing->data.mp3, (float)position);
-		} else {
-			smpeg.SMPEG_rewind(music_playing->data.mp3);
-			smpeg.SMPEG_play(music_playing->data.mp3);
 		}
 		break;
 #endif


More information about the commits mailing list