Commit graph

132 commits

Author SHA1 Message Date
Willem Jan Palenstijn
65861bb914 SCI: Change workaround for PalVary / Animate race condition
The new approach is to delay kAnimate briefly (with an 68ms timeout)
while there is a zero-tick PalVary running, so that it has time to
trigger.

The previous workaround would immediately process a zero-tick
PalVaryInit/PalVaryReverse. This caused problems in QfG3 (bug #10304)
where it interfered with PalVaryPause.

The previous workaround could also be modified to handle pause/resume,
but this new approach should be closer to SSCI's behaviour, which used a
timer for a zero-tick PalVary too.

This fixes bug #10304, and keeps #5298 fixed too.
2018-04-22 22:54:18 +02:00
Colin Snover
a233696212 SCI: Update formatting strings to match updated Span API 2017-03-30 14:23:41 -05:00
Colin Snover
31daa956d6 SCI: Implement bounds-checked reads of game resources 2017-03-27 19:42:31 -05:00
Willem Jan Palenstijn
95ab3bece9 SCI: Add FIXME for (very unlikely) race condition in _palVarySignal 2017-01-06 19:03:50 +01:00
Colin Snover
2071196f42 SCI32: Add bitmap segment and remove GC option from hunk segment 2016-08-01 10:37:14 -05:00
Colin Snover
4a637d65c3 SCI32: Enable optional explicit memory management of hunk entries
Bitmaps in ScrollWindow and Robot code are managed by the kernel
and not by game scripts, although they must be able to be
referenced through a reg_t. To prevent incorrect GC of bitmaps
that are in use but not referenced by any game script, explicit
memory management of hunk entries can be enabled.
2016-08-01 10:37:14 -05:00
Filippos Karapetis
f450ca0ebf SCI: Split color remapping functionality into a separate class
Currently, only the SCI16 remapping functionality is implemented
(used in the QFG4 demo)
2016-03-08 20:36:03 +02:00
Alexandre Detiste
6c298e964f JANITORIAL: Typos detected with lintian & grep 2016-02-15 18:27:02 +01:00
Colin Snover
76bd2eeb2e SCI: Use tick-based timing more consistently
This means tick-based times are saved to save games, as in SCI32
engine, instead of seconds, which are not accurate enough. It
also means places in SCI engine that need to access game ticks
should do so through g_sci instead of g_system or g_engine.
2016-01-14 16:13:22 -06:00
Colin Snover
fb891e4c08 SCI: Implement SCI32 kPalVary and kPalette setFade
This also fixes kPalCycle signatures to be more accurate.
2016-01-14 16:13:22 -06:00
Filippos Karapetis
a119108835 SCI: Fix compilation 2016-01-08 11:09:29 +02:00
Colin Snover
aeee621e44 SCI32: Add initial support for palette cycling (kPalCycle) and fading (kPalFade)
Graphics palette code was rewritten between SCI1 and SCI2, so
SCI32 palette engine code has been moved to a separate GfxPalette32
class.
2016-01-07 16:35:09 -06:00
Martin Kiewitz
5c91173337 SCI: color matching bug fix 2014-10-29 00:12:12 +01:00
Martin Kiewitz
bb29cdc899 SCI: color matching - remove debug code 2014-10-28 22:41:14 +01:00
Martin Kiewitz
28967b617f SCI: properly reversed color matching thanks wjp 2014-10-28 22:37:57 +01:00
Martin Kiewitz
f317e8c877 SCI: implement 8-bit color matching SCI1.1 bug
effectively fixes bug #6455
thanks to wjp and [md5]
2014-10-28 01:40:40 +01:00
Willem Jan Palenstijn
da9ffe9dbc SCI: Add note on SSCI 11 FindColor bug 2014-10-27 23:04:25 +01:00
Johannes Schickel
8fc7d60feb SCI: Make GPL headers consistent in themselves. 2014-02-18 02:39:37 +01:00
Filippos Karapetis
46ebf37ec9 SCI: Change wording for bug/further info references 2013-04-27 14:04:27 +03:00
Filippos Karapetis
cf3890b79a SCI: Remove obsolete comment and code 2013-01-11 02:24:18 +02:00
D G Turner
77a9f01454 SCI: Amended fix for palette related compiler warnings. 2012-11-26 21:08:39 +00:00
Filippos Karapetis
9c510c1b52 SCI: Fix warnings 2012-11-26 11:27:02 +02:00
Filippos Karapetis
7d436622a8 SCI: More work on kRemapColors
This implements some more color remap-based palette effects, found in QFG4
2012-08-21 03:32:23 +03:00
Filippos Karapetis
797dbfe506 SCI: Set the RemapByPercent palette initially
This needs to be performed because the screen palette might not change
after the call. Fixes the display of the bat in the character selection
screen in the full version of QFG4
2012-07-25 01:16:13 +03:00
Filippos Karapetis
537b1969bf SCI: Rewrite the color remapping code to support simultaneous effects
Fixes the torch in the full version of QFG4
2012-07-25 00:58:16 +03:00
Filippos Karapetis
37b209dac1 SCI: Refresh remapping by percent whenever the screen palette changes 2012-07-24 22:55:34 +03:00
Filippos Karapetis
fe3fb1873c SCI: Cleanup of the palette remapping code 2012-07-24 22:54:37 +03:00
Filippos Karapetis
6f35130204 SCI: More work on color remapping
More transparency/color mapping effects are now working (e.g. the
flashlight at the Gedde tomb in GK1, the rays of light at Schloss Ritter
in GK1, the torch in the QFG4 demo and the shadows in QFG4, PQ4 and KQ7)
2012-07-24 22:34:46 +03:00
Filippos Karapetis
bd281928cb SCI: Initial implementation of kRemapColors(kRemapByPercent)
Fixes some graphics glitches in the QFG4 demo and the menus of QFG4, by
implementing one of the transparency effects used mainly in SCI32.
Many thanks to fuzzie for her debugging info on QFG4 demo and to wjp for
his great help on the dissassembly
2012-07-24 03:53:44 +03:00
Filippos Karapetis
a643981a38 SCI: Handle resource ID -1 when setting the palVary resource
Fixes several wrong colors in SQ6
2012-06-08 11:57:43 +03:00
Filippos Karapetis
ae54885379 SCI: Updated information regarding bug #3439240 2011-11-17 11:16:10 +02:00
Filippos Karapetis
5fc9831577 SCI: Fixed bug #3439240 - "QFG1VGA: Game Crashes While Sleeping at Erana's Peace" 2011-11-17 11:00:09 +02:00
Filippos Karapetis
747bc75bc7 SCI: Fixed typo in colorIsFromMacClut() 2011-11-03 22:40:28 +02:00
Filippos Karapetis
935eaa175b SCI: Move the palette merging checking code inside the GfxPalette class 2011-10-19 23:52:51 +03:00
Filippos Karapetis
722ce77675 SCI: Wrapped some very long lines 2011-10-19 20:29:01 +03:00
Filippos Karapetis
4717d11862 SCI: Added support for the halfbrite palette used in Longbow Amiga
This fixes the remaining palette problems in the game (bug #3309036)
2011-09-27 16:54:14 +03:00
Filippos Karapetis
300cec119c SCI: Bugfix for the palette of Longbow Amiga (still not right) 2011-09-25 04:10:20 +03:00
Eugene Sandulenko
78f1ea7690 OSYSTEM: extended installTimerProc() with timer ID parameter 2011-08-06 11:28:35 +01:00
Max Horn
88913c0139 ALL: Remove trailing whitespaces
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-06-20 00:59:48 +02:00
strangerke
69b1485a22 GIT: Clean up: Suppress SVN tags, now useless 2011-05-12 01:16:22 +02:00
Ori Avtalion
9414d7a6e2 JANITORIAL: Reduce header dependencies in shared code
Some backends may break as I only compiled SDL
2011-04-28 15:08:58 +03:00
Max Horn
0ce2ca4e00 COMMON: Replace MKID_BE by MKTAG
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-04-12 16:53:15 +02:00
md5
4ddc66d68e SCI: Initial handling of the views in Longbow Amiga. Still not right 2011-03-07 13:23:52 +02:00
md5
dbd3f440d2 SCI: Added some support code for Longbow Amiga 2011-03-05 18:47:13 +02:00
Matthew Hoops
dbaad1a896 SCI: Fix Mac icon bar palette match order 2011-03-04 19:48:14 -05:00
md5
d95b5331fb SCI: Some palette related changes
- Moved palette color count inside the GfxPalette class
- Enabled all of the kPalette subops for 16 color SCI1 games, apart from
the ones for intensity palette animation, and palette resource loading
- Removed isVGA() and isAmiga32color() methods from the resource manager -
they ended up in having inconsistent code
2011-03-04 22:04:13 +02:00
md5
e286b1b5f1 SCI: Removed a hack for SCI1 Amiga games in setOnScreen() 2011-03-04 00:25:21 +02:00
Matthew Hoops
6db22dde64 SCI: Fixed freddy's Mac icon bar palettes
(hopefully for good now)
2011-02-21 20:32:30 -05:00
Johannes Schickel
e21d6e0d11 Merge branch 'osystem-palette' of https://github.com/lordhoto/scummvm into master
Conflicts:
	backends/platform/android/android.cpp
	engines/sci/graphics/screen.cpp
	engines/sci/graphics/transitions.cpp
2011-02-19 21:46:45 +01:00
strangerke
1055c8a8d0 SCI: Fix compilation using MSVC 9 2011-02-18 22:56:34 +01:00