aboutsummaryrefslogtreecommitdiff
path: root/engines/dreamweb/stubs.cpp
diff options
context:
space:
mode:
authorMax Horn2011-12-07 11:02:23 +0100
committerMax Horn2011-12-07 11:19:48 +0100
commitf37b7486768b57c3281c10409c4588d6188ef40c (patch)
tree6b6c5228415e1286507eaf893be4c95b17bc82a0 /engines/dreamweb/stubs.cpp
parentce8b1e06c72b75ea3a4b3a105a8f5493425dcad7 (diff)
downloadscummvm-rg350-f37b7486768b57c3281c10409c4588d6188ef40c.tar.gz
scummvm-rg350-f37b7486768b57c3281c10409c4588d6188ef40c.tar.bz2
scummvm-rg350-f37b7486768b57c3281c10409c4588d6188ef40c.zip
DREAMWEB: Merge DreamWeb::fadeDos into DreamGenContext::fadeDOS
Diffstat (limited to 'engines/dreamweb/stubs.cpp')
-rw-r--r--engines/dreamweb/stubs.cpp16
1 files changed, 15 insertions, 1 deletions
diff --git a/engines/dreamweb/stubs.cpp b/engines/dreamweb/stubs.cpp
index 5f8ff8c811..f6d3225edc 100644
--- a/engines/dreamweb/stubs.cpp
+++ b/engines/dreamweb/stubs.cpp
@@ -1118,7 +1118,21 @@ void DreamGenContext::showGroup() {
}
void DreamGenContext::fadeDOS() {
- engine->fadeDos();
+ ds = es = data.word(kBuffers);
+ return; //fixme later
+ engine->waitForVSync();
+ //processEvents will be called from vsync
+ uint8 *dst = es.ptr(kStartpal, 768);
+ engine->getPalette(dst, 0, 64);
+ for(int fade = 0; fade < 64; ++fade) {
+ for(int c = 0; c < 768; ++c) { //original sources decrement 768 values -> 256 colors
+ if (dst[c]) {
+ --dst[c];
+ }
+ }
+ engine->setPalette(dst, 0, 64);
+ engine->waitForVSync();
+ }
}
void DreamGenContext::eraseOldObs() {