Commit Graph

57 Commits

Author SHA1 Message Date
Johannes Schickel
b36b7ee349 SCUMM: Fix GM initialization when "enable_gs" is set.
This is a regression from r25630, which caused the code to send some garbage
data to the GS device, which resulted in some devices to fail with an
"Address Error." (like the Roland SC-55).

This might also fix bug #1927501 "GS option is broken". Even though actually
the device there failed with another error it is likely to be caused by the
same code. At least it is the only iMuse MIDI code change between 0.9.0 and
0.12.0, which might result in such a problem.

svn-id: r54727
2010-12-01 23:55:10 +00:00
Max Horn
e27b05ef35 COMMON: Rename String::printf() to String::format()
This is a first step towards getting rid of all uses of regular printf,
fprintf, vprintf, vfprintf, puts, fputs, etc. in our codebase.

The name format() reflects the purpose of the function, and parallels
String.format() in Java, boost::format, and others.

svn-id: r54004
2010-11-01 16:02:28 +00:00
Florian Kagerer
a48e19eaef SCUMM: minor cleanup
svn-id: r52792
2010-09-18 11:26:10 +00:00
Florian Kagerer
29a5c6a45b SCUMM/FM-TOWNS: start rewriting audio code
- Start rewriting audio code for FM-TOWNS versions of Loom, Indy3 and Monkey Island 1 using the recently added code in towns_audio.cpp (Zak should work the same way, but I can't test, since I don't own that one).
- All sound types (pcm, euphony and cd audio) now support volume and balance control (e.g. try walking into/out of the kitchen and opening/closing the door in the Scumm Bar in Monkey Island 1 or walking into/out of the circus tent).
- Pcm sounds now support proper loop start/end and note offsets (e.g. try out the hammer sound in the forge in LOOM for example).
- some other minor improvements
- The FM-Towns versions of Indy 4 and Monkey Island 2 are not affected. I don't have Monkey Island 2, but I presume that it will work like Indy 4. Adding support for these will be a separate task, since they work quite differently.

svn-id: r52198
2010-08-18 21:38:43 +00:00
Jordi Vilalta Prat
9255d7c3cb Remove some extra spaces
svn-id: r49489
2010-06-07 17:18:25 +00:00
Johannes Schickel
0d995c5920 Rename all "Adlib" uses to "AdLib" to match the real name of the sound card / company.
Check this for reference:
http://en.wikipedia.org/wiki/Ad_Lib,_Inc.
http://www.crossfire-designs.de/images/articles/soundcards/adlib.jpg (note the upper left of the card)

This commit does not touch "adlib" and "ADLIB" uses!

Also it does not update all the SCUMM detection entries, which still use "Adlib".

svn-id: r47279
2010-01-12 21:07:56 +00:00
Torbjörn Andersson
72eb9ec9ea Fixed a bunch of cppcheck warnings. Mostly about checking if a pointer is null
before freeing it, which isn't necessary.

svn-id: r46941
2010-01-03 19:37:43 +00:00
Travis Howell
8783b0f2f7 Add patch #2839048 - MM C64 sound/music player, with minor changes.
svn-id: r46143
2009-11-26 00:31:19 +00:00
Travis Howell
40504d7810 Add patch #2876221 - FBEAR: Fix for MIDI piano notes (DOS version), with minor change.
svn-id: r46081
2009-11-22 11:58:14 +00:00
Johannes Schickel
d1acdaeb59 Slightly changed unsupported effect level handling in native MT-32 mode.
svn-id: r44214
2009-09-20 15:24:08 +00:00
Johannes Schickel
066d748c95 Cleanup.
svn-id: r44186
2009-09-18 15:54:39 +00:00
Johannes Schickel
0864394748 Implement proper reverb setting in native MT-32 mode (as desribed in bug report #1088045 "MI2: Minor problems in native MT-32 mode").
svn-id: r44185
2009-09-18 15:54:12 +00:00
Johannes Schickel
c20bc5ea99 Implement proper pan reversal for Roland MT-32 in iMuse (as desribed in bug report #1088045 "MI2: Minor problems in native MT-32 mode").
svn-id: r44184
2009-09-18 15:12:27 +00:00
Andre Heider
e98c791106 Fixed iMuse regression: IMuseInternal::terminate() was never called, because the base class does not have that virtual function anymore. Code moved to the destructor.
svn-id: r43714
2009-08-24 22:41:56 +00:00
Johannes Schickel
ecb6423055 Fix warning caused by -Wformat-security, also fixed a possible buffer overflow along with it.
svn-id: r43445
2009-08-16 17:36:16 +00:00
Torbjörn Andersson
0999534749 The error() and warning() functions add ! and newline automatically. (I didn't
look at debug() and debugC(), since I'm really bored with this now. :-)

svn-id: r41061
2009-05-31 10:02:16 +00:00
Torbjörn Andersson
b97c9ef136 Work around bug #1324106 again. Apparently, I was mistaken the other day when I
said the timer changes fixed it. This time, I've made the workaround a bit
simpler to understand, though.

svn-id: r30429
2008-01-11 22:59:13 +00:00
Max Horn
6bc4a9a35e The SCUMM timer fix makes the workaround for bug #1324106 obsolete
svn-id: r30419
2008-01-11 22:13:34 +00:00
Nicola Mettifogo
258901bab9 Merged common/stdafx.h into common/scummsys.h. All referencing files have been updated.
svn-id: r28966
2007-09-19 08:40:12 +00:00
Max Horn
e1bcd70436 Re-added __attribute__(packed)
svn-id: r27830
2007-07-01 18:18:43 +00:00
Max Horn
218e132e37 Updated legal headers in source files, based on what Pidgin (the IM client formerly knowns as Gaim) does; added new (incomplete) COPYRIGHT file; updated copyright dates in a few spots
svn-id: r27024
2007-05-30 21:56:52 +00:00
Torbjörn Andersson
a1a16d1579 Use consistent naming for the preprocessor constants used to guarantee that
header files are only included once. Many of them didn't have a SCUMM prefix
which could have lead to clashes with common header files.

svn-id: r25727
2007-02-19 17:48:19 +00:00
Torbjörn Andersson
1a6361038e Committed my fix for bug #1662549 ("SCUMM: MIDI music is broken"). Apparently,
'len' is now one less than it used to in sysexHandler_Scumm(). Let's hope I
changed all the cases that needed changing, and nothing else...

svn-id: r25671
2007-02-18 09:10:50 +00:00
Max Horn
4db72c8762 Unified how we deal with (and how we generate) MIDI sysex messages -- in particular, we now always do so w/o framing the message (documented this with a Doxygen comment in the MidiDriver class)
svn-id: r25630
2007-02-16 13:30:41 +00:00
Max Horn
96162c14ea Ugh -- these internal iMuse structs were supposed to be packed, but never were explicitly markes as such. Doing that now (might break old savegames on some ports :/)
svn-id: r25629
2007-02-16 12:34:30 +00:00
Torbjörn Andersson
dfe8d777c1 Applied my own patch #1594924 to work around bug #1324106 ("MI2 VGA: Music as
Rapp is instantiating isn't synchronized"). I don't know if our timing is off,
or if it's just a case of overly optimistic scripting, but the pause / unpause
music instructions are issued in the wrong order.

svn-id: r24726
2006-11-16 17:08:31 +00:00
Torbjörn Andersson
e61526555c More whitespace.
svn-id: r24682
2006-11-12 02:34:09 +00:00
Torbjörn Andersson
7e0d08f52a Replaced cryptic error() with an assertion.
svn-id: r24681
2006-11-12 02:27:20 +00:00
Torbjörn Andersson
c5fca7b9ce Whitespace
svn-id: r24680
2006-11-12 02:24:25 +00:00
Eugene Sandulenko
efd5e8bfb6 Fix bug #1592006: "IMUSE: Typo in sysex_scumm.cpp ?"
svn-id: r24655
2006-11-08 10:05:21 +00:00
Max Horn
548cb2fbad Added FIXME comment about 'static' abuse in imuse_part.cpp
svn-id: r24327
2006-10-15 01:51:02 +00:00
Max Horn
4c14cf6d1a Moved base/engine.cpp and .h to engines/ (main motivation: helps untangle the linker dependency graph). Porters will have to update project files
svn-id: r23974
2006-09-23 00:42:35 +00:00
Torbjörn Andersson
e723f7d1eb Ignore unknown SysEx manufacturer IDs, rather than erroring on them. This does
NOT fix bug #1481383, even if that's where I heard about this problem.

svn-id: r22479
2006-05-15 13:19:30 +00:00
Eugene Sandulenko
d292c0ec55 Since our debug() adds an exclamation mark at the message end, remove
it in several calls to avoid duplication!!11!

svn-id: r21607
2006-04-04 22:04:51 +00:00
Lars Persson
595a48a87e Small updates to intiate variable and member visibility.
svn-id: r21604
2006-04-04 21:32:19 +00:00
Max Horn
8cdee5a931 Do not #include endian.h in scummsys.h (cuts down deps on endian.h from ~400 to ~250). Many greetings to eriktorbjorn, and have fun recompiling.
svn-id: r21500
2006-03-29 15:59:37 +00:00
Andrew Kurushin
62d2bcf735 Fix MSVC warnings #2
svn-id: r21441
2006-03-24 18:32:10 +00:00
Travis Howell
4b1e03f37a Remove unused var, to prevent compiler warning
svn-id: r21281
2006-03-14 12:19:17 +00:00
Travis Howell
c822f49676 Remove unused vars, to prevent compiler warnings
svn-id: r21279
2006-03-14 12:13:27 +00:00
Jamieson Christian
4d5a3e4c45 IMuse SysEx processing now handled by client-specified callbacks. This removes all game-specific references from the Player class. Bloodshed Dev-C++ project file updated.
svn-id: r21241
2006-03-12 18:06:22 +00:00
Torbjörn Andersson
985ab14c79 Removed inclusion of non-existing imuse_sysex.h to make ScummVM compile again.
svn-id: r21214
2006-03-11 07:37:09 +00:00
Jamieson Christian
2708fe34f3 Another ScummEngine reference in IMuse bites the dust.
svn-id: r21213
2006-03-11 01:06:30 +00:00
Jamieson Christian
effed85448 Implemented SysEx command 1 for non-S&M SCUMM games, per the latest comment on Bug 1088045.
svn-id: r21156
2006-03-09 03:29:12 +00:00
Jamieson Christian
06398d1a84 Removed tag2str usage, which eliminates scumm/util.h dependency.
svn-id: r21107
2006-03-05 22:35:26 +00:00
Torbjörn Andersson
ac33309a4d I guess this is really a WORKAROUND, rather than a HACK. Updated comment.
svn-id: r21106
2006-03-05 22:31:49 +00:00
Jamieson Christian
5e25b3b679 Restructured IMuse and IMuseInternal.
* IMuse is no longer a concurrency front-end.
* IMuseInternal now derives from IMuse.
* Common::StackLock used to protect thread-sensitive interface methods (same as IMuseDigital).
* clear_queue() included in stopAllSounds() so it can be removed from the public interface.
* Game ID now specified at init using property().
* Timer callbacks receive a struct containing IMuseInternal and MidiDriver refs, instead of just the latter.
* OSystem pointer from init is now cached and used instead of global.

All references to the g_system and g_scumm globals are now gone. BOOYAH!

Tested with MI2, DOTT and S&M, under Windows, in Native MIDI, Adlib, and Mixed modes. No regressions or concurrency issues observed. Manifestations of the latter are the biggest concern at this point.

svn-id: r21104
2006-03-05 21:30:44 +00:00
Travis Howell
429f7d43d6 Fix compiler warnings
svn-id: r21086
2006-03-05 05:43:46 +00:00
Jamieson Christian
b1f7f32ed1 Separated the IMuse Part methods into their own file. Updated the Bloodshed Dev-C++ project file at the same time.
svn-id: r21085
2006-03-05 05:14:20 +00:00
Jamieson Christian
857abe4c8b Removed the default ignoreFadeouts parameter value for ImuseInternal's getSoundStatus method. The disposition of this method is going to be changing soon, and I'm getting confused by the assumptions being made by many of the calls to it.
svn-id: r21080
2006-03-04 19:35:38 +00:00
Jamieson Christian
01af975df4 Rearranged methods in the IMuse class declaration to denote those derived from the MusicEngine base class.
svn-id: r21079
2006-03-04 18:38:27 +00:00