Filippos Karapetis
caf75e1bf5
SCI/new music code: Implemented cmdSetSoundPriority
...
svn-id: r46873
2010-01-02 01:41:39 +00:00
Filippos Karapetis
94fb4762e2
Changed wording from "handle" to "sound", as we're dealing with sound objects, not handles. Also, made the warnings thrown when a slot couldn't be found more verbose. Finally, changed the logic of when warnings should be thrown in cmdSetSoundLoop
...
svn-id: r46871
2010-01-02 01:09:49 +00:00
Martin Kiewitz
03376d06f1
SCI/newmusic: removed TODO
...
svn-id: r46858
2010-01-01 22:17:59 +00:00
Martin Kiewitz
0a965ced69
SCI/newmusic: changed setting volume from fade logic, implemented updating loop selector for sound fx
...
svn-id: r46856
2010-01-01 22:15:52 +00:00
Martin Kiewitz
d6d4a4f6e0
SCI: fix build
...
svn-id: r46854
2010-01-01 21:55:51 +00:00
Martin Kiewitz
37d56920ef
SCI/newmusic: changed fade volume setting for digital fx to onTimer() again, because setting it in updateCues() wont work right. We are processing fading effectively in there any way, added TODO for working approach
...
svn-id: r46853
2010-01-01 21:44:50 +00:00
Martin Kiewitz
379ae6df30
SCI/newmusic: now clips volume against MUSIC_VOLUME_MAX (127) instead of the mixer max volume (which would be wrong of course), adjusts volume when setting sample channel volume
...
svn-id: r46850
2010-01-01 21:04:20 +00:00
Martin Kiewitz
967853c03f
SCI: volume for sci0 now set to 127, now using constant instead of value
...
svn-id: r46849
2010-01-01 20:49:56 +00:00
Filippos Karapetis
98194bfe13
SCI/new music code: The MIDI driver is now reset whenever the game's VM respawns, like what the old music code does. Fixes the MIDI music in KQ5CD, Lonbgow and perhaps others
...
svn-id: r46843
2010-01-01 19:23:23 +00:00
Martin Kiewitz
74159e12eb
SCI/newmusic: set speech soundtype for audio resources played by kDoSound, cmdVolume is supposed to set music and sfx volume only - this whole fixes volume issues in lb2cd and others
...
svn-id: r46842
2010-01-01 18:57:14 +00:00
Martin Kiewitz
64d484bd99
SCI/newmusic: adding debug output to setVolume
...
svn-id: r46841
2010-01-01 17:53:37 +00:00
Martin Kiewitz
d1b844d3c3
SCI: syncing loop selector... again... fixes qfg1 ending... again... now sci0 only
...
svn-id: r46835
2010-01-01 16:15:20 +00:00
Filippos Karapetis
153cf54850
SCI/new music code: Moved processing of digital sound effects outside the MIDI worker thread. Some cleanup
...
svn-id: r46834
2010-01-01 16:05:26 +00:00
Martin Kiewitz
7bb18a018a
SCI/newmusic: doing version check before looking for audio resource
...
svn-id: r46831
2010-01-01 14:41:11 +00:00
Martin Kiewitz
7cf1d5bd5d
SCI/newmusic: added fade and loop capability to samples (looping doesnt work yet), fixes lsl1 doll inflation endless loop
...
svn-id: r46820
2010-01-01 13:21:30 +00:00
Filippos Karapetis
afc4bc1295
SCI/new music code:
...
- Resolved a deadlock with the mixer, and added appropriate mutexes (a result of the fact that SCI mixes MIDI and digital audio in the same list)
- Fixed sound playing when loading games, by properly resetting the MIDI driver
- Reverted savegame version to 14 - the changes in versions 15 and 16 don't have any effect on the currently enabled old music code, and the new music code is disabled by default, and is still prone to changes
- Now saving/loading signal, loop and hold for each sound, as well as reverb
- Added stub code for setting reverb and channel hold
- The signal, loop and hold values of each song are cached, like in SSCI and like what happens in Greg's SCI implementation. This allows a clear separation of the engine code from the rest of the engine. Reverted commits 46792 and 46797
- Removed duplicate song list accessing code
- Song cues are now updated in kAnimate for SCI0, like the old music code does, to compensate for the fact that SCI0 didn't poll for music changes via cmdUpdateCues, like what SCI01 and newer do
- Cleanup
svn-id: r46812
2010-01-01 06:41:52 +00:00
Filippos Karapetis
43f349f487
SCI/new music code: removed some hacks
...
svn-id: r46793
2009-12-31 08:55:13 +00:00
Filippos Karapetis
54245f712d
SCI/new music code: The loop selector for each music score is no longer cached, but read directly from the sound object
...
svn-id: r46792
2009-12-31 08:30:30 +00:00
Filippos Karapetis
762bdc7cad
SCI/new music code: Slight cleanup
...
svn-id: r46791
2009-12-31 08:10:51 +00:00
Martin Kiewitz
c27c9a84c2
SCI/newmusic: cmdSendMidi / removed weird midiCmd code - fixes lsl5 des revers records piano session
...
svn-id: r46783
2009-12-30 23:13:49 +00:00
Martin Kiewitz
c71fc9130d
SCI/newmusic: fix loop logic
...
svn-id: r46774
2009-12-30 21:22:00 +00:00
Filippos Karapetis
1e4a775241
SCI/new sound code:
...
- call cmdDisposeHandle() instead of soundKill when a track is being replaced
- Added information about cmdReverb
svn-id: r46766
2009-12-30 17:59:31 +00:00
Martin Kiewitz
2576f4b0bd
SCI/newmusic: fixed fading (fixes gk1 demo, park area)
...
svn-id: r46730
2009-12-29 23:25:24 +00:00
Martin Kiewitz
ef0f485847
SCI/newmusic: Removed playlist-feature from cmdResumeHandle cause that is sci0 only
...
svn-id: r46714
2009-12-29 18:28:26 +00:00
Martin Kiewitz
0fb1c8b106
SCI/newmusic: dont do pause/resume on the whole playlist prior sci1late (soundversion)
...
svn-id: r46713
2009-12-29 18:17:14 +00:00
Filippos Karapetis
dabfe53c66
Reverted rev #46647 - the title music in Codename: Iceman works correctly again
...
svn-id: r46701
2009-12-29 02:21:04 +00:00
Filippos Karapetis
a6aa3d6363
Better checking for the cmdMuteSound and cmdVolume special cases
...
svn-id: r46699
2009-12-29 01:27:15 +00:00
Filippos Karapetis
ac4551a39f
SCI/new music code: cmdPauseHandle/cmdResumeHandle now work for SCI0 games
...
svn-id: r46697
2009-12-29 00:22:39 +00:00
Martin Kiewitz
b65e4a8f74
SCI/newmusic: Added pausecounter cause sierra sci also does this
...
svn-id: r46693
2009-12-28 22:57:43 +00:00
Filippos Karapetis
dd1fc9c14b
SCI/new music code: Implemented cmdSendMidi, and removed access to _argc from sound commands
...
svn-id: r46692
2009-12-28 22:52:07 +00:00
Martin Kiewitz
f8abf06276
SCI/newmusic: Accept object 0:0 in cmdPauseHandle, pause the whole playlist then (fixes castle of dr. brain during intro)
...
svn-id: r46690
2009-12-28 22:35:53 +00:00
Max Horn
81a1d45821
SCI: Start objectifying MusicEntry
...
svn-id: r46687
2009-12-28 21:03:13 +00:00
Max Horn
3aded71f55
SCI: Make some code comply to our naming conventions
...
svn-id: r46685
2009-12-28 20:58:00 +00:00
Filippos Karapetis
5cb5fe22ea
SCI/new sound code:
...
- Made the SciMusic class private, and added wrapper functions for invoking specific methods of SciMusic from outside the SoundCommandParser class
- Many SCI games keep creating and destroying sound effects constantly (i.e. many times per second). Therefore, another scheme has been devised, which replaces the mutex that was in place. Whenever a sound command is run which operates on a specific object in the play list, we disallow onTimer() from kicking in. This isn't ideal, but it does stop random deadlocks because of locked mutexes without any noticeable side effects
svn-id: r46681
2009-12-28 20:10:15 +00:00
Filippos Karapetis
0a6e2127ac
SCI/new music code: Added a workaround for a music-related game bug in Castle of Dr. Brain
...
svn-id: r46678
2009-12-28 16:23:00 +00:00
Filippos Karapetis
5adb6277eb
SCI/new music code:
...
- Switched to Common::StackLock for mutexes
- Renamed Music::stopAll() -> Music::clearPlayList()
- Implemented a better Music::stopAll method, which stops all sounds with proper signals, instead of destroying them
- Renamed the SCI0 command cmdGetPlayNext -> cmdStopAllSounds and implemented it
svn-id: r46665
2009-12-27 23:46:11 +00:00
Martin Kiewitz
538806af19
SCI/newmusic: fixed warning
...
svn-id: r46663
2009-12-27 22:55:37 +00:00
Filippos Karapetis
95f90be7ef
Fixed priority bug
...
svn-id: r46652
2009-12-27 16:44:38 +00:00
Filippos Karapetis
ac224a7f8a
Removed _hasNodePtr
...
svn-id: r46650
2009-12-27 15:24:33 +00:00
Filippos Karapetis
fbf1bada24
cmdGetPolyphony always returns true in SCI0, according to specs
...
svn-id: r46647
2009-12-27 14:25:25 +00:00
Filippos Karapetis
9f37be314d
SCI/new music code:
...
- Implemented sound muting
- Now saving/loading the master music volume
svn-id: r46643
2009-12-27 14:11:26 +00:00
Filippos Karapetis
0a771e14c1
SCI/new music code:
...
- Removed a lot of accessors to the music list, and protected the 2 which are used now with mutexes
- Rewrote the music list save/load code to be methods of the SciMusic class
svn-id: r46623
2009-12-27 11:43:34 +00:00
Filippos Karapetis
c6a8d0e973
- Made the music playlist private
...
- Removed some leaks
- Fixed the destruction of the music playlist
- Made mutexes more sane
- Removed some dead code
- Cleanup
svn-id: r46578
2009-12-26 11:54:57 +00:00
Eugene Sandulenko
f9754ca68b
Remove extra debug output which sneaked in.
...
svn-id: r46562
2009-12-25 18:37:07 +00:00
Filippos Karapetis
113c0941ae
- Introduced a new version in the sound version detection routine, as SCI0 early games had different sound than SCI0 late ones
...
- Changed sound-related debug output from printf's into debugC calls
svn-id: r46560
2009-12-25 18:15:16 +00:00
Filippos Karapetis
586ec94df9
Adjusted volume clipping
...
svn-id: r46555
2009-12-25 15:24:35 +00:00
Filippos Karapetis
ec5c42e1f3
Limit volume range to 0 - 255
...
svn-id: r46554
2009-12-25 14:02:28 +00:00
Martin Kiewitz
c03e7c8586
SCI/newmusic: find slot again after destroying it fixes kq6cd, lb2cd, added debug output
...
svn-id: r46553
2009-12-25 13:52:40 +00:00
Filippos Karapetis
f5567d4605
Fixed variable capitalization
...
svn-id: r46552
2009-12-25 13:37:55 +00:00
Johannes Schickel
6223450781
Fix compilation.
...
svn-id: r46551
2009-12-25 13:26:13 +00:00