aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVladimir Menshakov2011-06-12 02:20:28 +0400
committerAlyssa Milburn2011-06-15 17:34:16 +0200
commit2bcc06f9eae89dcdc45a5430aa0e0395c2fa576e (patch)
tree2603d122162f417377c34b05e9c305d32049df77
parent4ccd7fd791e117117034925870dc4db2bfdad7b3 (diff)
downloadscummvm-rg350-2bcc06f9eae89dcdc45a5430aa0e0395c2fa576e.tar.gz
scummvm-rg350-2bcc06f9eae89dcdc45a5430aa0e0395c2fa576e.tar.bz2
scummvm-rg350-2bcc06f9eae89dcdc45a5430aa0e0395c2fa576e.zip
DREAMWEB: cleanup frameoutnm
-rw-r--r--engines/dreamweb/dreamweb.cpp11
1 files changed, 6 insertions, 5 deletions
diff --git a/engines/dreamweb/dreamweb.cpp b/engines/dreamweb/dreamweb.cpp
index 7a9619d1c6..b5e2a1328c 100644
--- a/engines/dreamweb/dreamweb.cpp
+++ b/engines/dreamweb/dreamweb.cpp
@@ -347,11 +347,12 @@ void frameoutnm(Context &context) {
unsigned w = (uint8)context.cl, h = (uint8)context.ch;
unsigned pitch = (uint16)context.dx;
unsigned src = (uint16)context.si;
- unsigned dst = (uint16)context.di + (uint16)context.bx * pitch;
- //debug(1, "framenm %ux%u[pitch: %u] -> segment: %04x->%04x", w, h, pitch, (uint16)context.ds, (uint16)context.es);
- for(unsigned y = 0; y < h; ++y) {
- uint8 *src_p = context.ds.ptr(src + w * y, w);
- uint8 *dst_p = context.es.ptr(dst + pitch * y, w);
+ int x = (uint16)context.di, y = (uint16)context.bx;
+ unsigned dst = x + y * pitch;
+ //debug(1, "framenm %ux%u[pitch: %u]-> %d,%d, segment: %04x->%04x", w, h, pitch, x, y, (uint16)context.ds, (uint16)context.es);
+ for(unsigned l = 0; l < h; ++l) {
+ uint8 *src_p = context.ds.ptr(src + w * l, w);
+ uint8 *dst_p = context.es.ptr(dst + pitch * l, w);
memcpy(dst_p, src_p, w);
}
}