[Scummvm-cvs-logs] SF.net SVN: scummvm: [31366] scummvm/trunk/engines/agi/sound.cpp

buddha_ at users.sourceforge.net buddha_ at users.sourceforge.net
Thu Apr 3 20:12:10 CEST 2008


Revision: 31366
          http://scummvm.svn.sourceforge.net/scummvm/?rev=31366&view=rev
Author:   buddha_
Date:     2008-04-03 11:12:09 -0700 (Thu, 03 Apr 2008)

Log Message:
-----------
Fix naming of the Apple IIGS midi speed variable and its value (Was erronously named bpm although was really ticks per second rather than ticks per minute).

Modified Paths:
--------------
    scummvm/trunk/engines/agi/sound.cpp

Modified: scummvm/trunk/engines/agi/sound.cpp
===================================================================
--- scummvm/trunk/engines/agi/sound.cpp	2008-04-03 14:33:53 UTC (rev 31365)
+++ scummvm/trunk/engines/agi/sound.cpp	2008-04-03 18:12:09 UTC (rev 31366)
@@ -554,8 +554,8 @@
 		}
 
 		uint8 deltaTime = readByte;
-		double bpm = 58.25; // Approximation based on tests with Apple IIGS KQ1 and SQ1 under MESS 0.124a
-		g_midiMillis += (uint32) ((deltaTime * 1000) / bpm);
+		uint32 ticksPerMinute = 3495; // Approximation based on tests with Apple IIGS KQ1 and SQ1 under MESS 0.124a
+		g_midiMillis += (deltaTime * 1000 * 60) / ticksPerMinute;
 
 		// Check for end of MIDI sequence marker (This time it after reading delta-time)
 		if (*p == MIDI_BYTE_STOP_SEQUENCE) {


This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.




More information about the Scummvm-git-logs mailing list