diff options
author | Paul Gilbert | 2019-11-21 20:09:29 -0800 |
---|---|---|
committer | Paul Gilbert | 2019-11-22 18:49:07 -0800 |
commit | 53d9b6e1c67898f309fbb538c0edf937fd435e56 (patch) | |
tree | e159cb0b8952b7fba78a35d914bb05b02b22bc92 /engines/glk/magnetic/glk.cpp | |
parent | 69f186c66591e6cff41d1444e6da40e45e4d5103 (diff) | |
download | scummvm-rg350-53d9b6e1c67898f309fbb538c0edf937fd435e56.tar.gz scummvm-rg350-53d9b6e1c67898f309fbb538c0edf937fd435e56.tar.bz2 scummvm-rg350-53d9b6e1c67898f309fbb538c0edf937fd435e56.zip |
GLK: Fixing defines clashes between sub-engines
Diffstat (limited to 'engines/glk/magnetic/glk.cpp')
-rw-r--r-- | engines/glk/magnetic/glk.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/engines/glk/magnetic/glk.cpp b/engines/glk/magnetic/glk.cpp index ee4faebdd9..67fed7632b 100644 --- a/engines/glk/magnetic/glk.cpp +++ b/engines/glk/magnetic/glk.cpp @@ -289,7 +289,7 @@ glui32 Magnetic::gms_get_buffer_crc(const void *void_buffer, size_t length) { */ crc = 0xffffffff; for (index = 0; index < length; index++) - crc = crc_table[(crc ^ buf[index]) & BYTE_MAX] ^ (crc >> CHAR_BIT); + crc = crc_table[(crc ^ buf[index]) & BYTE_MAX] ^ (crc >> BITS_PER_BYTE); return crc ^ 0xffffffff; } @@ -767,8 +767,8 @@ void Magnetic::gms_graphics_apply_animation_frame(type8 bitmap[], * even. Here we'll calculate the real width of a mask, and also set a high * bit for later on. */ - mask_width = (((frame_width - 1) / CHAR_BIT) + 2) & (~1); - mask_hibit = 1 << (CHAR_BIT - 1); + mask_width = (((frame_width - 1) / BITS_PER_BYTE) + 2) & (~1); + mask_hibit = 1 << (BITS_PER_BYTE - 1); /* * Initialize row index components; these are optimizations to avoid the @@ -808,8 +808,8 @@ void Magnetic::gms_graphics_apply_animation_frame(type8 bitmap[], type8 mask_byte; /* Isolate the mask byte, and test the transparency bit. */ - mask_byte = mask[mask_row + (x / CHAR_BIT)]; - if ((mask_byte & (mask_hibit >> (x % CHAR_BIT))) != 0) + mask_byte = mask[mask_row + (x / BITS_PER_BYTE)]; + if ((mask_byte & (mask_hibit >> (x % BITS_PER_BYTE))) != 0) continue; } |