Age | Commit message (Collapse) | Author |
|
This is used by Lighthouse.
|
|
Refs Trac#9976.
|
|
|
|
If a user fails to rename audio files in the required manner when
copying them, detecting multi-disc audio by looking for a renamed
audio file does not work very well. Looking at RESSCI.00n is a
better choice, though this is not completely valid since e.g.
Rama 1.0 US has only one RESOURCE.SFX volume which its installer
copies to the hard drive, so a little more work will need to be
done in the future to find and fix these kinds of edge cases.
Refs Trac#9976.
|
|
|
|
|
|
Type mismatch is triggered on THEGUIDE.DOS and THEGUIDE.WIN from
at least Phant1 French 1.100.000.
|
|
For the moment, only warn about bad resources when a game is
actually starting, since unknown but valid resources being
detected by the fallback detector currently also trigger the
warning.
|
|
The stream returned by a call to ResourceManager::getVolumeFile
either MUST (when returning an I/O stream from a Common::FSNode)
or must NOT (when returning a Common::File *) be deleted by the
caller, depending upon some internal implementation details of
ResourceSource that should never have been exposed to callers.
FSNode streams that should have been deleted were not being
deleted all the time, which leaked and eventually caused ScummVM
to run out of FDs.
This commit improves this situation by shielding callers from
these internal details by centralizing the destruction logic in
one place, so FSNode read streams stop being leaked and callers
no longer need to know stuff about the internals of the
ResourceSource they are trying to read in order to avoid leaking
or breaking the volume file cache.
Fixes Trac#9782.
|
|
Refs Trac#9764.
|
|
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.
|
|
|
|
While earlier commits had fixed handling of audio resources in
audio bundles to match SSCI, audio *patches* in SCI16 were still
being treated like standard resource patches. They are now
special-cased in the resource manager, just like SCI32.
Incidentally, while fixing the problem with audio patches, I also
noticed that the patch resource fixes for SQ5/German were very
similar to the special-case operations for resources in SCI32,
though using an odd heuristic. After investigating, it appears
that Sierra SCI1.1 works mostly like SCI32, and not like what
was there from SCI View. So, the old special-case code is deleted
and the special-case code for SCI32 has been expanded to cover
SCI1.1. (SSCI prior to 1.1 do not appear to do this
special-casing.)
Fixes Trac#9773.
|
|
The Lighthouse glider demo comes with a file named SDirectX.dll
which was failing to match the case-sensitive suffix search for
.DLL.
|
|
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).
|
|
Simple assertions in the resource manager are not sufficient to
track down resource corruption issues, and some error conditions
that were being checked already were either ignored or only raised
as warnings that casual users would be unlikely to see.
Ideally, error handling in ResourceManager would be improved to
the point where errors would correctly propagate out of it (so the
warning dialogue could be displayed from outside), but right now
error codes are dropped all over the place, and it would take more
effort to fix that without much benefit for the current situation.
If/until someone has the energy to fix that, the warning dialogue
is simply shown from ResourceManager::scanNewSources.
Refs Trac#9764.
|
|
Closes Trac#9745.
|
|
SCI3 resources appear to already be properly handled.
|
|
GK2 on Steam comes with an extra bogus resource map file which
would previously cause ScummVM to refuse to load the game due to
a mismatch in the number of map & volume files. This does not
cause any harm, but is a pain for users (since it requires them to
manually delete the file, and it will be recreated if a user runs
the Steam game file integrity check), so allow the game to load
with a warning instead.
|
|
Skipping a search for .CSC scripts when any .SCR files exist does
not work with at least Phant2, because it comes with an INSTALL.SCR
file. Searching unconditionally for .CSC files should not cause any
issues since the game scripts will either be in .SCR format or in
.CSC format, not both in the same game.
|
|
|
|
Map format is the same as SCI2/2.1 and volume format is detected
correctly as SCI3.
|
|
Specifically, audio patches are used in at least PQ:SWAT
(40103.AUD), Lighthouse (9103.AUD), and the GK2 demo (300.AUD).
|
|
|
|
|
|
|
|
|
|
KQ7 2.00b includes a SIERRINF.OLD file which should not be matched.
|
|
|
|
Unlike SCI16 games, the location of data within SCI32 patch files
is calculated on a per-resource-type basis by the game engine,
instead of by reading byte 1 of the patch file.
|
|
|
|
This fixes high CPU utilisation playing Stooge Fighter 3 in SQ6.
|
|
This type in SSCI corresponds to Wave resources, but since ScummVM
does not differentiate between Wave and Audio resources, just say
it's an Audio resource type, not an Invalid resource type.
|
|
A regression from c4250c05d0
|
|
Fixes some false warnings when games try to read in non-patch
files with names that start with A/B/S/T.
|
|
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.
|
|
|
|
|
|
Several times I have run into this code and had to take a minute
to remind myself that the call to remove from the LRU on find is
not wrong, so it seemed to deserve a comment.
|
|
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.
|
|
|
|
|
|
|
|
|
|
|
|
Removed the superfluous initForDetection() function, which was not
updated in commit 2f17ba2b0ab77ef939c21efa04f7aaafccbd0c37 and
caused the fallback detector to crash because of uninitialized
variables
|
|
A single picture in SCI32 is often larger than the 256KiB limit,
meaning that the cache is useless for these games -- which is bad,
because the renderer works directly off raw resource data so it
must be decompressed and in-cache for rendering performance to be
acceptable.
|
|
|
|
Regression from af3fec8c26d92005b507dca65d1d50f820feb0e7
Code resulted in a crash on BE platforms
|
|
don't remove const during cast
|