diff options
Diffstat (limited to 'src/mame/video/kaneko_spr.h')
-rw-r--r-- | src/mame/video/kaneko_spr.h | 58 |
1 files changed, 29 insertions, 29 deletions
diff --git a/src/mame/video/kaneko_spr.h b/src/mame/video/kaneko_spr.h index 98fbc3649a4..69540575e94 100644 --- a/src/mame/video/kaneko_spr.h +++ b/src/mame/video/kaneko_spr.h @@ -8,12 +8,12 @@ /* Kaneko Sprites */ -struct kaneko16_priority_t +struct priority_t { int sprite[4]; }; -struct kan_tempsprite +struct tempsprite_t { int code,color; int x,y; @@ -46,18 +46,18 @@ public: // (legacy) used in the bitmap clear functions virtual int get_sprite_type(void) =0; - void kaneko16_render_sprites(bitmap_ind16 &bitmap, const rectangle &cliprect, bitmap_ind8 &priority_bitmap, uint16_t* spriteram16, int spriteram16_bytes); - void kaneko16_render_sprites(bitmap_rgb32 &bitmap, const rectangle &cliprect, bitmap_ind8 &priority_bitmap, uint16_t* spriteram16, int spriteram16_bytes); + void render_sprites(bitmap_ind16 &bitmap, const rectangle &cliprect, bitmap_ind8 &priority_bitmap, u16* spriteram16, int spriteram16_bytes); + void render_sprites(bitmap_rgb32 &bitmap, const rectangle &cliprect, bitmap_ind8 &priority_bitmap, u16* spriteram16, int spriteram16_bytes); template<class _BitmapClass> - void kaneko16_render_sprites_common(_BitmapClass &bitmap, const rectangle &cliprect, bitmap_ind8 &priority_bitmap, uint16_t* spriteram16, int spriteram16_bytes); + void render_sprites_common(_BitmapClass &bitmap, const rectangle &cliprect, bitmap_ind8 &priority_bitmap, u16* spriteram16, int spriteram16_bytes); - void bootleg_draw_sprites(bitmap_ind16 &bitmap, const rectangle &cliprect, uint16_t* spriteram16, int spriteram16_bytes); + void bootleg_draw_sprites(bitmap_ind16 &bitmap, const rectangle &cliprect, u16* spriteram16, int spriteram16_bytes); - DECLARE_READ16_MEMBER(kaneko16_sprites_regs_r); - DECLARE_WRITE16_MEMBER(kaneko16_sprites_regs_w); + u16 regs_r(offs_t offset); + void regs_w(offs_t offset, u16 data, u16 mem_mask); protected: kaneko16_sprite_device( @@ -65,7 +65,7 @@ protected: device_type type, const char *tag, device_t *owner, - uint32_t clock); + u32 clock); virtual void device_start() override; virtual void device_reset() override; @@ -75,41 +75,41 @@ protected: int m_sprite_fliptype; // offsets (set when declaring device in MCFG ) - uint16_t m_sprite_xoffs; - uint16_t m_sprite_yoffs; + u16 m_sprite_xoffs; + u16 m_sprite_yoffs; // priority for mixing (set when declaring device in MCFG ) - kaneko16_priority_t m_priority; + priority_t m_priority; // pure virtual function for getting the attributes on sprites, the two different chip types have // them in a different order - virtual void get_sprite_attributes(struct kan_tempsprite *s, uint16_t attr) =0; + virtual void get_sprite_attributes(struct tempsprite_t *s, u16 attr) =0; private: // registers - uint16_t m_sprite_flipx; - uint16_t m_sprite_flipy; - std::unique_ptr<uint16_t[]> m_sprites_regs; + u16 m_sprite_flipx; + u16 m_sprite_flipy; + std::unique_ptr<u16[]> m_sprites_regs; - std::unique_ptr<struct kan_tempsprite[]> m_first_sprite; + std::unique_ptr<struct tempsprite_t[]> m_first_sprite; int m_keep_sprites; bitmap_ind16 m_sprites_bitmap; template<class _BitmapClass> - void kaneko16_draw_sprites(_BitmapClass &bitmap, const rectangle &cliprect, bitmap_ind8 &priority_bitmap, uint16_t* spriteram16, int spriteram16_bytes); + void draw_sprites(_BitmapClass &bitmap, const rectangle &cliprect, bitmap_ind8 &priority_bitmap, u16* spriteram16, int spriteram16_bytes); template<class _BitmapClass> - void kaneko16_draw_sprites_custom(_BitmapClass &dest_bmp,const rectangle &clip,gfx_element *gfx, - uint32_t code,uint32_t color,int flipx,int flipy,int sx,int sy, + void draw_sprites_custom(_BitmapClass &dest_bmp,const rectangle &clip,gfx_element *gfx, + u32 code,u32 color,int flipx,int flipy,int sx,int sy, bitmap_ind8 &priority_bitmap, int priority); - int kaneko16_parse_sprite_type012(int i, struct kan_tempsprite *s, uint16_t* spriteram16, int spriteram16_bytes); + int parse_sprite_type012(int i, struct tempsprite_t *s, u16* spriteram16, int spriteram16_bytes); - void kaneko16_copybitmap(bitmap_ind16 &bitmap, const rectangle &cliprect); - void kaneko16_copybitmap(bitmap_rgb32 &bitmap, const rectangle &cliprect); + void copybitmap(bitmap_ind16 &bitmap, const rectangle &cliprect); + void copybitmap(bitmap_rgb32 &bitmap, const rectangle &cliprect); required_device<gfxdecode_device> m_gfxdecode; @@ -123,12 +123,12 @@ class kaneko_vu002_sprite_device : public kaneko16_sprite_device { public: kaneko_vu002_sprite_device(const machine_config &mconfig, const char *tag, device_t *owner) - : kaneko_vu002_sprite_device(mconfig, tag, owner, (uint32_t)0) + : kaneko_vu002_sprite_device(mconfig, tag, owner, (u32)0) { } - kaneko_vu002_sprite_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); - void get_sprite_attributes(struct kan_tempsprite *s, uint16_t attr) override; + kaneko_vu002_sprite_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + void get_sprite_attributes(struct tempsprite_t *s, u16 attr) override; int get_sprite_type(void) override{ return 0; }; }; @@ -139,12 +139,12 @@ class kaneko_kc002_sprite_device : public kaneko16_sprite_device { public: kaneko_kc002_sprite_device(const machine_config &mconfig, const char *tag, device_t *owner) - : kaneko_kc002_sprite_device(mconfig, tag, owner, (uint32_t)0) + : kaneko_kc002_sprite_device(mconfig, tag, owner, (u32)0) { } - kaneko_kc002_sprite_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); - void get_sprite_attributes(struct kan_tempsprite *s, uint16_t attr) override; + kaneko_kc002_sprite_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + void get_sprite_attributes(struct tempsprite_t *s, u16 attr) override; int get_sprite_type(void) override{ return 1; }; }; |