summaryrefslogtreecommitdiffstats
path: root/src/emu/screen.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/emu/screen.h')
-rw-r--r--src/emu/screen.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/emu/screen.h b/src/emu/screen.h
index f1126b4cb69..0f20848d45f 100644
--- a/src/emu/screen.h
+++ b/src/emu/screen.h
@@ -252,6 +252,7 @@ public:
}
template<class Object> devcb_base &set_screen_vblank(Object &&object) { return m_screen_vblank.set_callback(std::forward<Object>(object)); }
+ auto screen_vblank() { return m_screen_vblank.bind(); }
template<typename T> void set_palette(T &&tag) { m_palette.set_tag(std::forward<T>(tag)); }
void set_video_attributes(u32 flags) { m_video_attributes = flags; }
void set_color(rgb_t color) { m_color = color; }
@@ -272,9 +273,8 @@ public:
// beam positioning and state
int vpos() const;
int hpos() const;
- bool vblank() const { return (machine().time() < m_vblank_end_time); }
- DECLARE_READ_LINE_MEMBER(vblank) { return (machine().time() < m_vblank_end_time) ? ASSERT_LINE : CLEAR_LINE; }
- DECLARE_READ_LINE_MEMBER(hblank) { int curpos = hpos(); return (curpos < m_visarea.min_x || curpos > m_visarea.max_x) ? ASSERT_LINE : CLEAR_LINE; }
+ DECLARE_READ_LINE_MEMBER(vblank) const { return (machine().time() < m_vblank_end_time) ? 1 : 0; }
+ DECLARE_READ_LINE_MEMBER(hblank) const { int const curpos = hpos(); return (curpos < m_visarea.min_x || curpos > m_visarea.max_x) ? 1 : 0; }
// timing
attotime time_until_pos(int vpos, int hpos = 0) const;
@@ -542,7 +542,7 @@ typedef device_type_iterator<screen_device> screen_device_iterator;
#define MCFG_SCREEN_UPDATE_DEVICE(_device, _class, _method) \
downcast<screen_device &>(*device).set_screen_update(_device, &_class::_method, #_class "::" #_method);
#define MCFG_SCREEN_VBLANK_CALLBACK(_devcb) \
- devcb = &downcast<screen_device &>(*device).set_screen_vblank(DEVCB_##_devcb);
+ downcast<screen_device &>(*device).set_screen_vblank(DEVCB_##_devcb);
#define MCFG_SCREEN_PALETTE(_palette_tag) \
downcast<screen_device &>(*device).set_palette(_palette_tag);
#define MCFG_SCREEN_NO_PALETTE \