aboutsummaryrefslogtreecommitdiff
path: root/engines/sci/resource_audio.cpp
AgeCommit message (Collapse)Author
2016-08-19SCI32: Enable multi-disc audio resourcesColin Snover
Phant1, PQ:SWAT, GK2, and Phant2 all have different audio maps and audio volumes on each CD. In order to make this work within ScummVM, where CDs are never swapped, each RESOURCE.AUD for these games must be renamed to RESAUD.00x and each RESOURCE.SFX renamed to RESSFX.00x.
2016-06-22SCI: Assert on seeks past the end of audio resource bundlesColin Snover
This should never be allowed to happen, but currently does on multi-CD games with different resource bundles on difference CDs (Phant1, PQ:SWAT, GK2) because the resource manager does not yet have the ability to handle this situation.
2016-06-20SCI32: Rewrite digital audio engineColin Snover
This provides a complete implementation of kDoAudio through SCI2.1mid, plus partial implementation of SCI3 features. Digital audio calls shunted through kDoSound have also been updated to go through the SCI32 audio mixer, though these shunts are a bit hacky because the ScummVM implementation of kDoSound does not currently match how SSCI kDoSound is designed. It is probably possible in the future to just replace the SCI1.1 audio code (audio.cpp) with the new SCI32 code, since the major differences seem to be that (1) SCI1.1 only supported one digital audio playback channel (this is configurable already), (2) it had extra commands for CD audio playback and queued sample playback.
2016-03-08SCI: Truncate channel data in case it goes beyond resource sizeMartin Kiewitz
Fixes invalid memory access during kq5 floppy ending
2016-03-01SCI: Use uint32 instead of unsigned intFilippos Karapetis
2015-12-29SCI32: split up SCI2.1 into EARLY/MIDDLE/LATEMartin Kiewitz
- Detection works via signatures (couldn't find a better way) - new kString subcalls were introduced SCI2.1 LATE - kString now has signatures and is split via subcall table - kString fix, so that KQ7 doesn't crash, when starting a chapter - Sci2StringFunctionType removed, because no longer needed
2015-02-15SCI: Use sound resource priority by default for songsWillem Jan Palenstijn
SCI1 sound resources can have an embedded priority. We now use that by default, unless an explicit DoSound/SetPriority call overrides it. Thanks waltervn. This fixes relative priority of songs in at least PQ3 room 29. Also increase savegame version to 33.
2014-10-28SCI: Remove trailing whitespaceFilippos Karapetis
2014-10-03SCI: Fix reading SCI1 midi channel flagsWillem Jan Palenstijn
Thanks waltervn
2014-02-18SCI: Make GPL headers consistent in themselves.Johannes Schickel
2013-12-31SCI: Rewrite MIDI channel remappingWillem Jan Palenstijn
This adds MIDI state tracking to allow channels to be temporarily unmapped and later re-mapped when there are free device channels available again.
2013-12-31SCI: Reduce indentation depthWillem Jan Palenstijn
2013-12-11SCI: rave support (KQ6 hires portrait lip sync)Martin Kiewitz
Thanks to wjp and [md5] for helping
2013-12-10SCI: Add handling for the RAVE resource type, found in KQ6CDFilippos Karapetis
This contains the sync data in the Windows version of KQ6CD. Note that currently the sync36 resource is 2 bytes bigger (it contains 2 bytes from the RAVE resource). Some test code has also been added to dump the RAVE sync resources
2013-04-20SCI: Fix memory leakWillem Jan Palenstijn
2012-02-20COMMON: Move isFoo functions to namespace Common, add doxygen commentsMax Horn
2012-02-15ALL: Avoid using is* macros from ctype.hMax Horn
On some systems, passing signed chars to macros like isspace() etc. lead to a runtime error. Hence, mark these macros as forbidden by default, and introduce otherwise equivalent alternatives for them.
2012-01-15SCI: Clean up some memory management and loopsWillem Jan Palenstijn
2012-01-15SCI: Plug a leak in ResourceManager::processWavePatch()Filippos Karapetis
Many thanks to digitall for finding this one
2011-11-02SCI: Fixed bug in commit 1a17bba.Filippos Karapetis
Thanks to wjp for pointing it out.
2011-11-02SCI: Fix Common::List::erase usage.Filippos Karapetis
Thanks to Tron for pointing that out.
2011-06-23ANALYSIS: Add static casts to is* functionsLittleboy
This fixes a potential problem with passing char values that would be sign-extended and yield unexpected results. See http://msdn.microsoft.com/en-us/library/ms245348.aspx
2011-06-20ALL: Remove trailing whitespacesMax Horn
This tries to make our code a bit more compliant with our code formatting conventions. For future use, this is the command I used: git ls-files "*.cpp" "*.h" | xargs sed -i -e 's/[ \t]*$//'
2011-05-12GIT: Clean up: Suppress SVN tags, now uselessstrangerke
2011-04-28JANITORIAL: Reduce header dependencies in shared codeOri Avtalion
Some backends may break as I only compiled SDL
2011-04-12COMMON: Replace MKID_BE by MKTAGMax Horn
MKID_BE relied on unspecified behavior of the C++ compiler, and as such was always a bit unsafe. The new MKTAG macro is slightly less elegant, but does no longer depend on the behavior of the compiler. Inspired by FFmpeg, which has an almost identical macro.
2011-02-10SCI: Added resource manager support for changing the audio directory ↵Filippos Karapetis
dynamically. Also, moved some audio-specific resource code inside resource_audio.cpp This functionality is used by kSetLanguage(), called when switching the language in MUMG Deluxe from the game's main menu. svn-id: r55872
2011-02-10SCI: Moved some audio resource code to resource_audio.cppFilippos Karapetis
svn-id: r55865
2010-11-25SCI: Added support for the alternate Windows MIDI soundtracks of the CD ↵Filippos Karapetis
versions of EcoQuest, Jones, KQ5 and SQ4 svn-id: r54476
2010-11-25SCI: Fixed digital audio at the beginning of KQ5CD and removed a hack for ↵Filippos Karapetis
the Windows version svn-id: r54466
2010-11-25SCI: Added support for the alternative GM tracks of the Windows version of ↵Filippos Karapetis
KQ5CD (bug #3041239) Note that the empty GM track for the Sierra logo makes the game hang, so the MT-32 track is used, which sounds awful svn-id: r54464
2010-11-09SCI: Fix compile when SCI32 is not enabledMatthew Hoops
svn-id: r54160
2010-09-18JANITORIAL: Removed most punctuation at end of warning() and error()Torbjörn Andersson
Our warning() and error() functions always add an exclamation mark to the end of the message anyway. svn-id: r52791
2010-09-18SCI: Some changes to the fallback detector (sync with branch 1.2.0)Filippos Karapetis
Added more graceful handling of the case where SCI32 isn't built in and the user tries to detect or start a SCI32 game svn-id: r52789
2010-09-09SCI: Fix digital track regression from r52662.Walter van Niftrik
svn-id: r52666
2010-09-09SCI: Fix last MIDI channel number for adlib driverWalter van Niftrik
svn-id: r52662
2010-08-20SCI: Fixed the GM detection introduced in rev #52211 to check the first ↵Filippos Karapetis
available track, instead of track 1 (which doesn't always exist, e.g. in Pharkas). Also, added a comment inside applyPatch() svn-id: r52222
2010-08-19SCI: Added checking for the existence of a GM track, to determine if device ↵Filippos Karapetis
ID 7 or 12 should be used. Fixes the GM music in the demo of QFG3, which is using an in-between version of SCI1 and SCI1.1 svn-id: r52211
2010-08-04SCI: Fix size of wave files inside audio volumes (thanks to LordHoto for ↵Matthew Hoops
pointing out) svn-id: r51745
2010-08-03SCI: Add support for SCI2.1 chunk resourcesMatthew Hoops
And if no scripts are present, but chunk 0 is present, load resources from there. This fixes the Lighthouse SCI2.1 demo. svn-id: r51696
2010-08-02SCI: Fix bug #3037401 - LB2Floppy: No SFXMatthew Hoops
Laura Bow 2 floppy and Mixed-Up Mother Goose SCI1.1 use an 8-byte entry 0.map format to store their entries. svn-id: r51646
2010-07-14SCI: changing signature of kDoSound(play) in SCI2.1 to "o(i)" now, because ↵Martin Kiewitz
qfg4 still uses "oi" calling svn-id: r50879
2010-06-26SCI: do boundary checking when loading sci1 sounds and mixing them together. ↵Martin Kiewitz
The final end credits song (resource 699) in kq5 has some channels with invalid offsets, crashing ScummVM before svn-id: r50339
2010-06-25SCI: Introduce SciGameId enumMax Horn
svn-id: r50273
2010-06-22Add support for the QFG3 demo audio map and audio resources. Based on a ↵Matthew Hoops
patch by Walter. svn-id: r50144
2010-06-16SCI: implement channel remapping for SCI1Martin Kiewitz
svn-id: r49905
2010-06-16SCI: Avoid using g_sci in resman (as it might not yet be inited)Max Horn
svn-id: r49897
2010-06-15Fix wave patches.Matthew Hoops
svn-id: r49855
2010-06-15SCI: OOpify class ResourceIdMax Horn
svn-id: r49841
2010-06-15Reduce header dependenciesMax Horn
svn-id: r49836