diff options
author | 2019-03-25 23:13:40 +0100 | |
---|---|---|
committer | 2019-03-25 23:13:40 +0100 | |
commit | b380514764cf857469bae61c11143a19f79a74c5 (patch) | |
tree | 63c8012e262618f08a332da31dd714281aa2c5ed /src/devices/video/cesblit.h | |
parent | c24473ddff715ecec2e258a6eb38960cf8c8e98e (diff) |
Revert "conflict resolution (nw)"
This reverts commit c24473ddff715ecec2e258a6eb38960cf8c8e98e, reversing
changes made to 009cba4fb8102102168ef32870892438327f3705.
Diffstat (limited to 'src/devices/video/cesblit.h')
-rw-r--r-- | src/devices/video/cesblit.h | 24 |
1 files changed, 16 insertions, 8 deletions
diff --git a/src/devices/video/cesblit.h b/src/devices/video/cesblit.h index d535921ef6b..f22f16df260 100644 --- a/src/devices/video/cesblit.h +++ b/src/devices/video/cesblit.h @@ -11,6 +11,21 @@ #pragma once +/*************************************************************************** + INTERFACE CONFIGURATION MACROS +***************************************************************************/ + +#define MCFG_CESBLIT_ADD(_tag, _screen, _clock) \ + MCFG_DEVICE_ADD(_tag, CESBLIT, _clock) \ + MCFG_VIDEO_SET_SCREEN(_screen) + +#define MCFG_CESBLIT_MAP MCFG_DEVICE_PROGRAM_MAP + +#define MCFG_CESBLIT_COMPUTE_ADDR(_compute_addr) \ + downcast<cesblit_device &>(*device).set_compute_addr(_compute_addr); + +#define MCFG_CESBLIT_IRQ_CB(_devcb) \ + downcast<cesblit_device &>(*device).set_irq_callback(DEVCB_##_devcb); /*************************************************************************** TYPE DEFINITIONS @@ -26,18 +41,11 @@ public: typedef int (*compute_addr_t) (uint16_t reg_low, uint16_t reg_mid, uint16_t reg_high); // construction/destruction - template <typename T> - cesblit_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&screen_tag) - : cesblit_device(mconfig, tag, owner, clock) - { - set_screen(std::forward<T>(screen_tag)); - } - cesblit_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); // configuration void set_compute_addr(compute_addr_t compute_addr) { m_compute_addr = compute_addr; } - auto irq_callback() { return m_blit_irq_cb.bind(); } + template <class Object> devcb_base &set_irq_callback(Object &&cb) { return m_blit_irq_cb.set_callback(std::forward<Object>(cb)); } DECLARE_WRITE16_MEMBER(color_w); DECLARE_WRITE16_MEMBER(addr_hi_w); |