summaryrefslogtreecommitdiffstatshomepage
path: root/src/mame/video/armedf.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/mame/video/armedf.cpp')
-rw-r--r--src/mame/video/armedf.cpp30
1 files changed, 13 insertions, 17 deletions
diff --git a/src/mame/video/armedf.cpp b/src/mame/video/armedf.cpp
index 45a9b36f1f8..11995cb029e 100644
--- a/src/mame/video/armedf.cpp
+++ b/src/mame/video/armedf.cpp
@@ -281,28 +281,24 @@ void armedf_state::armedf_drawgfx(bitmap_ind16 &dest_bmp,const rectangle &clip,g
if (ex > sx)
{ /* skip if inner loop doesn't draw anything */
- int x, y;
-
+ for (int y = sy; y < ey; y++)
{
- for (y = sy; y < ey; y++)
+ u8 const *const source = source_base + y_index*gfx->rowbytes();
+ u16 *const dest = &dest_bmp.pix(y);
+ u8 *const destpri = &primap.pix(y);
+ int x_index = x_index_base;
+ for (int x = sx; x < ex; x++)
{
- const u8 *source = source_base + y_index*gfx->rowbytes();
- u16 *dest = &dest_bmp.pix16(y);
- u8 *destpri = &primap.pix8(y);
- int x_index = x_index_base;
- for (x = sx; x < ex; x++)
+ int c = (source[x_index] & ~0xf) | ((m_spr_pal_clut[clut*0x10+(source[x_index] & 0xf)]) & 0xf);
+ if (c != transparent_color)
{
- int c = (source[x_index] & ~0xf) | ((m_spr_pal_clut[clut*0x10+(source[x_index] & 0xf)]) & 0xf);
- if (c != transparent_color)
- {
- if (((1 << (destpri[x] & 0x1f)) & pmask) == 0)
- dest[x] = pal[c];
- destpri[x] = 0x1f;
- }
- x_index += xinc;
+ if (((1 << (destpri[x] & 0x1f)) & pmask) == 0)
+ dest[x] = pal[c];
+ destpri[x] = 0x1f;
}
- y_index += yinc;
+ x_index += xinc;
}
+ y_index += yinc;
}
}
}