aboutsummaryrefslogtreecommitdiff
path: root/engines/sci/resource_intern.h
AgeCommit message (Collapse)Author
2017-05-10SCI: Fix support for ScummVM compressed audio volumesColin Snover
The runtime code for this had previously relied on hot patching volume file offsets at the moment that a resource was loaded, instead of correcting file offsets when reading audio maps. The code added for sanity checking audio volumes started to report warnings because the offsets being received were for the original uncompressed audio volume, which (naturally) is larger than the compressed audio volume. This commit also deduplicates code between addResource and updateResource, and tweaks a validation-related error message for improved clarity. Fixes Trac#9764.
2017-05-08SCI: Fix some issues with ChunkResourceSourceColin Snover
1. The chunk number was hard-coded to zero and inaccessible. 2. Running ResourceManager::getVolumeFile for a chunk resource would always return nullptr instead of a stream of the chunk, which made it impossible to generically validate that resources being added were within bounds of the container file (or, in this case, container chunk).
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.
2014-02-18SCI: Make GPL headers consistent in themselves.Johannes Schickel
2013-04-20SCI: Fix memory leakWillem Jan Palenstijn
2011-05-12GIT: Clean up: Suppress SVN tags, now uselessstrangerke
2011-04-28JANITORIAL: Format forward declarations to follow conventionOri Avtalion
2011-02-10SCI: Changed the comments of r55869 to Doxygen format (thanks, fingolfin)Filippos Karapetis
svn-id: r55874
2011-02-10SCI: Fixed typoFilippos Karapetis
svn-id: r55870
2011-02-10SCI: Added a short explanation about each of the different resource source typesFilippos Karapetis
svn-id: r55869
2011-01-31SCI: Add support for Mac SCI1.1+ resource compressionMatthew Hoops
Mac SCI1.1+ games should now start up. QFG1 and Hoyle4 are playable. GK1 starts its scripts, but errors out soon after. There are still some View bugs with each (somehow, view decompression seems to be adding a blank line after each line?). *Much* thanks to Walter for his help. svn-id: r55696
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-07-17Remove extra ";" in class declarations.Johannes Schickel
svn-id: r50955
2010-06-16SCI: Avoid using g_sci in resman (as it might not yet be inited)Max Horn
svn-id: r49897
2010-06-15SCI: Pass resman to scanSource() methodsMax Horn
svn-id: r49863
2010-06-15SCI: Add FIXME regarding audio specific code in Resource(Source)Max Horn
svn-id: r49849
2010-06-15SCI: Add ResourceManager::updateResource(); change some code to use ↵Max Horn
addResource() svn-id: r49832
2010-06-15SCI: Move _associatedMap to VolumeResourceSource and make it constMax Horn
svn-id: r49831
2010-06-15SCI: Move _audioCompression(Type|OffsetMapping) to AudioVolumeResourceSourceMax Horn
svn-id: r49830
2010-06-15SCI: Get rid of ugly resMan params to ResourceSource methodsMax Horn
We might want to add a ResourceSource::_resMan member, but for now I am not adding one on purpose; many more things might still move between ResourceSource and ResourceManager, so we should wait till the refactoring is complete. svn-id: r49828
2010-06-15SCI: Make ResourceSource::_resourceFile constMax Horn
svn-id: r49826
2010-06-15SCI: Rename ResourceSource members to follow _camelCase conventionMax Horn
svn-id: r49823
2010-06-15SCI: Pass volume number to ResourceSource subclass constructors; make ↵Max Horn
ResourceSource::volume_number const svn-id: r49822
2010-06-15SCI: Add loadResource impls for WaveResourceSource and AudioVolumeResourceSourceMax Horn
svn-id: r49821
2010-06-15SCI: Add loadResource impls to MacResourceForkResourceSource and ↵Max Horn
PatchResourceSource; move _macResMan to MacResourceForkResourceSource svn-id: r49820
2010-06-15SCI: Move code from ResourceManager::loadResource to ↵Max Horn
ResourceSource::loadResource svn-id: r49819
2010-06-15SCI: Rename ResourceSource::resourceFile to _resourceFileMax Horn
svn-id: r49818
2010-06-15SCI: Merge MacResourceForkResourceSource::scanSource and ↵Max Horn
ResourceManager::readMacResourceFork svn-id: r49817
2010-06-15SCI: Add virtual method ResourceSource::scanSourceMax Horn
svn-id: r49816
2010-06-15SCI: Change ResourceManager::getVolume() to use new classesMax Horn
* Add new ResourceSource::findVolume() virtual method * Rename ResourceManager::getVolume() to findVolume(), and change it to use the new ResourceSource method * Add some TODO comments pointing to further OOPification possibilities svn-id: r49815
2010-06-15SCI: Remove 'map' param from addSource, and let AudioVolumeResourceSource ↵Max Horn
subclass VolumeResourceSource svn-id: r49814
2010-06-15SCI: Convert code to use ResourceSource subclassesMax Horn
svn-id: r49813
2010-06-15SCI: Add ResourceSource subclasses, one for each typeMax Horn
svn-id: r49812
2010-06-15SCI: Changed some 'const char *' to Common::StringMax Horn
svn-id: r49811
2010-06-15SCI: Change ResourceSource to a class, further OOPify it.Max Horn
In particular, renamed location_name to _name and made it const and protected. Thus it cannot be changed after creation, and only read access is now possible, via a getter method. svn-id: r49810
2010-06-15SCI: Only use MacResManager if needed; start to OOPify ResourceSourceMax Horn
svn-id: r49809
2010-06-15SCI: Move ResourceSource to new header resource_intern.hMax Horn
svn-id: r49807