mirror of
https://github.com/holub/mame
synced 2025-04-21 07:52:35 +03:00
fix tilemap viewer to draw the whole tilemap when categories are used
This commit is contained in:
parent
d91c34cf31
commit
a284b2fd9e
@ -943,7 +943,7 @@ void tilemap_draw_by_index(bitmap_t *dest, int number, UINT32 scrollx, UINT32 sc
|
||||
int xpos,ypos;
|
||||
|
||||
/* set up for the blit, using hard-coded parameters (no priority, etc) */
|
||||
configure_blit_parameters(&blit, tmap, dest, NULL, TILEMAP_DRAW_OPAQUE, 0, 0xff);
|
||||
configure_blit_parameters(&blit, tmap, dest, NULL, TILEMAP_DRAW_OPAQUE | TILEMAP_DRAW_ALL_CATEGORIES, 0, 0xff);
|
||||
|
||||
/* compute the effective scroll positions */
|
||||
scrollx = tmap->width - scrollx % tmap->width;
|
||||
@ -1498,6 +1498,13 @@ static void configure_blit_parameters(blit_parameters *blit, tilemap *tmap, bitm
|
||||
blit->mask &= ~(TILEMAP_PIXEL_LAYER0 | TILEMAP_PIXEL_LAYER1 | TILEMAP_PIXEL_LAYER2);
|
||||
blit->value &= ~(TILEMAP_PIXEL_LAYER0 | TILEMAP_PIXEL_LAYER1 | TILEMAP_PIXEL_LAYER2);
|
||||
}
|
||||
|
||||
/* don't check category if requested */
|
||||
if (flags & TILEMAP_DRAW_ALL_CATEGORIES)
|
||||
{
|
||||
blit->mask &= ~TILEMAP_PIXEL_CATEGORY_MASK;
|
||||
blit->value &= ~TILEMAP_PIXEL_CATEGORY_MASK;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
@ -321,6 +321,7 @@
|
||||
#define TILEMAP_DRAW_LAYER2 0x40 /* draw layer 2 */
|
||||
#define TILEMAP_DRAW_OPAQUE 0x80 /* draw everything, even transparent stuff */
|
||||
#define TILEMAP_DRAW_ALPHA 0x100 /* draw with alpha blending */
|
||||
#define TILEMAP_DRAW_ALL_CATEGORIES 0x200 /* draw all categories */
|
||||
|
||||
|
||||
/* per-pixel flags in the transparency_bitmap */
|
||||
|
Loading…
Reference in New Issue
Block a user