Skip to content

Commit 66d102d

Browse files
committed
bandai/wswan_v.cpp: Use logmacro.h for logging
1 parent ef69445 commit 66d102d

File tree

1 file changed

+14
-2
lines changed

1 file changed

+14
-2
lines changed

src/mame/bandai/wswan_v.cpp

+14-2
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,18 @@
1616
#include "wswan_v.h"
1717
#include "screen.h"
1818

19+
#define LOG_UNKNOWN (1 << 1)
20+
#define LOG_SCANLINE (1 << 2)
21+
22+
#define LOG_ALL (LOG_UNKNOWN | LOG_SCANLINE)
23+
24+
#define VERBOSE (0)
25+
26+
#include "logmacro.h"
27+
28+
#define LOGUNKNOWN(...) LOGMASKED(LOG_UNKNOWN, __VA_ARGS__)
29+
#define LOGSCANLINE(...) LOGMASKED(LOG_SCANLINE, __VA_ARGS__)
30+
1931
DEFINE_DEVICE_TYPE(WSWAN_VIDEO, wswan_video_device, "wswan_video", "Bandai WonderSwan VDP")
2032
DEFINE_DEVICE_TYPE(WSWAN_COLOR_VIDEO, wswan_color_video_device, "wscolor_video", "Bandai WonderSwan Color VDP")
2133

@@ -512,7 +524,7 @@ void wswan_video_device::refresh_scanline()
512524
draw_foreground_0();
513525
break;
514526
case 1: // ???
515-
logerror("Unknown foreground mode 1 set\n");
527+
LOGUNKNOWN("Unknown foreground mode 1 set\n");
516528
break;
517529
case 2: // FG only inside window area
518530
if (m_current_line >= m_window_fg_top && m_current_line <= m_window_fg_bottom)
@@ -596,7 +608,7 @@ void wswan_video_device::reg_w(offs_t offset, u16 data, u16 mem_mask)
596608
case 0x02 / 2:
597609
// Current scanline (read-only)
598610
if (ACCESSING_BITS_0_7)
599-
logerror("Write to current scanline! Current value: %d Data to write: %d\n", m_current_line, data);
611+
LOGSCANLINE("Write to current scanline! Current value: %d Data to write: %d\n", m_current_line, data);
600612
// Line compare
601613
if (ACCESSING_BITS_8_15)
602614
m_line_compare = data >> 8;

0 commit comments

Comments
 (0)