diff options
author | 2016-02-24 07:46:57 +0100 | |
---|---|---|
committer | 2016-02-24 07:46:57 +0100 | |
commit | 3abcaee63ff285514e8b51a60949c97a7dfa5304 (patch) | |
tree | 63e6be46c1932606689f9bfacc920d69cfc4b51f /src/devices/video | |
parent | 0cbd8782119b140920097a2bee76f36aef014be9 (diff) |
Cleanups and version bump
Diffstat (limited to 'src/devices/video')
-rw-r--r-- | src/devices/video/ef9364.cpp | 394 | ||||
-rw-r--r-- | src/devices/video/ef9364.h | 88 | ||||
-rw-r--r-- | src/devices/video/jangou_blitter.cpp | 30 | ||||
-rw-r--r-- | src/devices/video/jangou_blitter.h | 4 | ||||
-rw-r--r-- | src/devices/video/upd7220.cpp | 2 | ||||
-rw-r--r-- | src/devices/video/voodoo.cpp | 10 | ||||
-rw-r--r-- | src/devices/video/voodoo.h | 8 |
7 files changed, 265 insertions, 271 deletions
diff --git a/src/devices/video/ef9364.cpp b/src/devices/video/ef9364.cpp index b850f05d531..5b683b15e09 100644 --- a/src/devices/video/ef9364.cpp +++ b/src/devices/video/ef9364.cpp @@ -31,7 +31,7 @@ const device_type EF9364 = &device_creator<ef9364_device>; // default address map //------------------------------------------------- static ADDRESS_MAP_START( ef9364, AS_0, 8, ef9364_device ) - AM_RANGE(0x00000, ( ( EF9364_TXTPLANE_MAX_SIZE * EF9364_MAX_TXTPLANES ) - 1 ) ) AM_RAM + AM_RANGE(0x00000, ( ( EF9364_TXTPLANE_MAX_SIZE * EF9364_MAX_TXTPLANES ) - 1 ) ) AM_RAM ADDRESS_MAP_END //------------------------------------------------- @@ -41,7 +41,7 @@ ADDRESS_MAP_END const address_space_config *ef9364_device::memory_space_config(address_spacenum spacenum) const { - return (spacenum == AS_0) ? &m_space_config : NULL; + return (spacenum == AS_0) ? &m_space_config : NULL; } //************************************************************************** @@ -57,13 +57,13 @@ const address_space_config *ef9364_device::memory_space_config(address_spacenum //------------------------------------------------- ef9364_device::ef9364_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock) : - device_t(mconfig, EF9364, "EF9364", tag, owner, clock, "ef9364", __FILE__), - device_memory_interface(mconfig, *this), - device_video_interface(mconfig, *this), - m_space_config("textram", ENDIANNESS_LITTLE, 8, 12, 0, nullptr, *ADDRESS_MAP_NAME(ef9364)), - m_palette(*this) + device_t(mconfig, EF9364, "EF9364", tag, owner, clock, "ef9364", __FILE__), + device_memory_interface(mconfig, *this), + device_video_interface(mconfig, *this), + m_space_config("textram", ENDIANNESS_LITTLE, 8, 12, 0, nullptr, *ADDRESS_MAP_NAME(ef9364)), + m_palette(*this) { - clock_freq = clock; + clock_freq = clock; } //------------------------------------------------- @@ -73,7 +73,7 @@ ef9364_device::ef9364_device(const machine_config &mconfig, const char *tag, dev void ef9364_device::static_set_palette_tag(device_t &device, const char *tag) { - downcast<ef9364_device &>(device).m_palette.set_tag(tag); + downcast<ef9364_device &>(device).m_palette.set_tag(tag); } //------------------------------------------------- @@ -82,10 +82,10 @@ void ef9364_device::static_set_palette_tag(device_t &device, const char *tag) void ef9364_device::static_set_nb_of_pages(device_t &device, int nb_of_pages ) { - if( nb_of_pages > 0 && nb_of_pages <= 8 ) - { - downcast<ef9364_device &>(device).nb_of_pages = nb_of_pages; - } + if( nb_of_pages > 0 && nb_of_pages <= 8 ) + { + downcast<ef9364_device &>(device).nb_of_pages = nb_of_pages; + } } //------------------------------------------------- @@ -95,14 +95,14 @@ void ef9364_device::static_set_nb_of_pages(device_t &device, int nb_of_pages ) void ef9364_device::set_color_entry( int index, UINT8 r, UINT8 g, UINT8 b ) { - if( index < 2 ) - { - palette[index] = rgb_t(r, g, b); - } - else - { - logerror("Invalid EF9364 Palette entry : %02x\n", index); - } + if( index < 2 ) + { + palette[index] = rgb_t(r, g, b); + } + else + { + logerror("Invalid EF9364 Palette entry : %02x\n", index); + } } //------------------------------------------------- @@ -111,26 +111,26 @@ void ef9364_device::set_color_entry( int index, UINT8 r, UINT8 g, UINT8 b ) void ef9364_device::device_start() { - m_textram = &space(0); - m_charset = region(); + m_textram = &space(0); + m_charset = region(); - bitplane_xres = EF9364_NB_OF_COLUMNS*8; - bitplane_yres = EF9364_NB_OF_ROWS*(8+4); + bitplane_xres = EF9364_NB_OF_COLUMNS*8; + bitplane_yres = EF9364_NB_OF_ROWS*(8+4); - vsync_scanline_pos = 250; + vsync_scanline_pos = 250; - // Default palette : Black and white - palette[0] = rgb_t(0, 0, 0); - palette[1] = rgb_t(255, 255, 255); + // Default palette : Black and white + palette[0] = rgb_t(0, 0, 0); + palette[1] = rgb_t(255, 255, 255); - m_screen_out.allocate( bitplane_xres, m_screen->height() ); + m_screen_out.allocate( bitplane_xres, m_screen->height() ); - cursor_cnt = 0; - cursor_state = 0; + cursor_cnt = 0; + cursor_state = 0; - save_item(NAME(m_border)); + save_item(NAME(m_border)); - save_item(NAME(m_screen_out)); + save_item(NAME(m_screen_out)); } //------------------------------------------------- @@ -139,23 +139,23 @@ void ef9364_device::device_start() void ef9364_device::device_reset() { - int i; + int i; - x_curs_pos = 0; - y_curs_pos = 0; + x_curs_pos = 0; + y_curs_pos = 0; - char_latch = 0x00; + char_latch = 0x00; - for(i=0;i<EF9364_NB_OF_COLUMNS * EF9364_NB_OF_ROWS * nb_of_pages;i++) - { - m_textram->write_byte ( i , 0x7F ); - } + for(i=0;i<EF9364_NB_OF_COLUMNS * EF9364_NB_OF_ROWS * nb_of_pages;i++) + { + m_textram->write_byte ( i , 0x7F ); + } - memset(m_border, 0, sizeof(m_border)); + memset(m_border, 0, sizeof(m_border)); - m_screen_out.fill(0); + m_screen_out.fill(0); - set_video_mode(); + set_video_mode(); } //------------------------------------------------- @@ -164,18 +164,18 @@ void ef9364_device::device_reset() void ef9364_device::set_video_mode(void) { - UINT16 new_width = bitplane_xres; + UINT16 new_width = bitplane_xres; - if (m_screen->width() != new_width) - { - rectangle visarea = m_screen->visible_area(); - visarea.max_x = new_width - 1; + if (m_screen->width() != new_width) + { + rectangle visarea = m_screen->visible_area(); + visarea.max_x = new_width - 1; - m_screen->configure(new_width, m_screen->height(), visarea, m_screen->frame_period().attoseconds()); - } + m_screen->configure(new_width, m_screen->height(), visarea, m_screen->frame_period().attoseconds()); + } - //border color - memset(m_border, 0, sizeof(m_border)); + //border color + memset(m_border, 0, sizeof(m_border)); } //------------------------------------------------- @@ -193,41 +193,41 @@ void ef9364_device::draw_border(UINT16 line) UINT32 ef9364_device::screen_update(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect) { - int x,y,r; - unsigned char c; - - for( r = 0 ; r < EF9364_NB_OF_ROWS ; r++ ) - { - for( y = 0 ; y < 8 ; y++ ) - { - for( x = 0 ; x < EF9364_NB_OF_COLUMNS * 8 ; x++ ) - { - if( ( ( x >> 3 ) != x_curs_pos ) || ( r != y_curs_pos ) || !cursor_state) - { - c = m_textram->read_byte( ( r * EF9364_NB_OF_COLUMNS ) + ( x>>3 ) ); - - if( m_charset->u8(((c&0x7F)<<3) + y ) & (0x80>>(x&7)) ) - m_screen_out.pix32((r*12)+y, x) = palette[1]; - else - m_screen_out.pix32((r*12)+y, x) = palette[0]; - } - else - { - if(y != 7) - m_screen_out.pix32((r*12)+y, x) = palette[0]; - else - m_screen_out.pix32((r*12)+y, x) = palette[1]; - } - } - } - } - - cursor_cnt = (cursor_cnt + 1) % 13; - if(!cursor_cnt) - cursor_state ^= 1; - - copybitmap(bitmap, m_screen_out, 0, 0, 0, 0, cliprect); - return 0; + int x,y,r; + unsigned char c; + + for( r = 0 ; r < EF9364_NB_OF_ROWS ; r++ ) + { + for( y = 0 ; y < 8 ; y++ ) + { + for( x = 0 ; x < EF9364_NB_OF_COLUMNS * 8 ; x++ ) + { + if( ( ( x >> 3 ) != x_curs_pos ) || ( r != y_curs_pos ) || !cursor_state) + { + c = m_textram->read_byte( ( r * EF9364_NB_OF_COLUMNS ) + ( x>>3 ) ); + + if( m_charset->u8(((c&0x7F)<<3) + y ) & (0x80>>(x&7)) ) + m_screen_out.pix32((r*12)+y, x) = palette[1]; + else + m_screen_out.pix32((r*12)+y, x) = palette[0]; + } + else + { + if(y != 7) + m_screen_out.pix32((r*12)+y, x) = palette[0]; + else + m_screen_out.pix32((r*12)+y, x) = palette[1]; + } + } + } + } + + cursor_cnt = (cursor_cnt + 1) % 13; + if(!cursor_cnt) + cursor_state ^= 1; + + copybitmap(bitmap, m_screen_out, 0, 0, 0, 0, cliprect); + return 0; } //------------------------------------------------- @@ -236,15 +236,15 @@ UINT32 ef9364_device::screen_update(screen_device &screen, bitmap_rgb32 &bitmap, void ef9364_device::update_scanline(UINT16 scanline) { - if (scanline == vsync_scanline_pos) - { - // vsync - } - - if (scanline == 0) - { - draw_border(0); - } + if (scanline == vsync_scanline_pos) + { + // vsync + } + + if (scanline == 0) + { + draw_border(0); + } } //------------------------------------------------- @@ -253,107 +253,107 @@ void ef9364_device::update_scanline(UINT16 scanline) void ef9364_device::command_w(UINT8 cmd) { - int x,y,i,j; - - switch( cmd&7 ) - { - case 0x0: // Page Erase & Cursor home - for( y=0 ; y < EF9364_NB_OF_ROWS ; y++ ) - { - for( x=0 ; x < EF9364_NB_OF_COLUMNS ; x++ ) - { - m_textram->write_byte ( y * EF9364_NB_OF_COLUMNS + x , 0x7F ); - } - } - x_curs_pos = 0; - y_curs_pos = 0; - break; - - case 0x1: // Erase to end of the line and return cursor - for( ; x_curs_pos < EF9364_NB_OF_COLUMNS ; x_curs_pos++ ) - { - m_textram->write_byte ( y_curs_pos * EF9364_NB_OF_COLUMNS + x_curs_pos , 0x7F ); - } - x_curs_pos = 0; - break; - - case 0x2: // Line feed - y_curs_pos++; - if( y_curs_pos >= EF9364_NB_OF_ROWS ) - { - // Scroll - for( j = 1 ; j < EF9364_NB_OF_ROWS ; j++ ) - { - for( i = 0 ; i < EF9364_NB_OF_COLUMNS ; i++ ) - { - m_textram->write_byte ( (j-1) * EF9364_NB_OF_COLUMNS + i , m_textram->read_byte ( j * EF9364_NB_OF_COLUMNS + i ) ); - } - } - // Erase last line - for( i = 0 ; i < EF9364_NB_OF_COLUMNS ; i++ ) - { - m_textram->write_byte ( ( EF9364_NB_OF_ROWS - 1 ) * EF9364_NB_OF_COLUMNS + i , 0x7F ); - } - - y_curs_pos = EF9364_NB_OF_ROWS - 1; - } - break; - - case 0x3: // Nop - - break; - - case 0x4: // Cursor left - if(x_curs_pos) - x_curs_pos--; - break; - - case 0x5: // Erasure of cursor Line. - for( x = 0 ; x < EF9364_NB_OF_COLUMNS ; x++ ) - { - m_textram->write_byte ( y_curs_pos * EF9364_NB_OF_COLUMNS + x , 0x7F ); - } - break; - - case 0x6: // Cursor up - if(y_curs_pos) - y_curs_pos--; - break; - - case 0x7: // Write char - if(cmd&0x8) - m_textram->write_byte ( y_curs_pos * EF9364_NB_OF_COLUMNS + x_curs_pos , char_latch ); - - x_curs_pos++; - if( x_curs_pos >= EF9364_NB_OF_COLUMNS ) - { - x_curs_pos=0; - y_curs_pos++; - if( y_curs_pos >= EF9364_NB_OF_ROWS ) - { - // Scroll - for( j = 1 ; j < EF9364_NB_OF_ROWS ; j++ ) - { - for( i = 0 ; i < EF9364_NB_OF_COLUMNS ; i++ ) - { - m_textram->write_byte ( (j-1) * EF9364_NB_OF_COLUMNS + i , m_textram->read_byte ( j * EF9364_NB_OF_COLUMNS + i ) ); - } - } - // Erase last line - for( i = 0 ; i < EF9364_NB_OF_COLUMNS ; i++ ) - { - m_textram->write_byte ( ( EF9364_NB_OF_ROWS - 1 ) * EF9364_NB_OF_COLUMNS + i , 0x7F ); - } - - y_curs_pos = EF9364_NB_OF_ROWS - 1; - } - } - break; - - } + int x,y,i,j; + + switch( cmd&7 ) + { + case 0x0: // Page Erase & Cursor home + for( y=0 ; y < EF9364_NB_OF_ROWS ; y++ ) + { + for( x=0 ; x < EF9364_NB_OF_COLUMNS ; x++ ) + { + m_textram->write_byte ( y * EF9364_NB_OF_COLUMNS + x , 0x7F ); + } + } + x_curs_pos = 0; + y_curs_pos = 0; + break; + + case 0x1: // Erase to end of the line and return cursor + for( ; x_curs_pos < EF9364_NB_OF_COLUMNS ; x_curs_pos++ ) + { + m_textram->write_byte ( y_curs_pos * EF9364_NB_OF_COLUMNS + x_curs_pos , 0x7F ); + } + x_curs_pos = 0; + break; + + case 0x2: // Line feed + y_curs_pos++; + if( y_curs_pos >= EF9364_NB_OF_ROWS ) + { + // Scroll + for( j = 1 ; j < EF9364_NB_OF_ROWS ; j++ ) + { + for( i = 0 ; i < EF9364_NB_OF_COLUMNS ; i++ ) + { + m_textram->write_byte ( (j-1) * EF9364_NB_OF_COLUMNS + i , m_textram->read_byte ( j * EF9364_NB_OF_COLUMNS + i ) ); + } + } + // Erase last line + for( i = 0 ; i < EF9364_NB_OF_COLUMNS ; i++ ) + { + m_textram->write_byte ( ( EF9364_NB_OF_ROWS - 1 ) * EF9364_NB_OF_COLUMNS + i , 0x7F ); + } + + y_curs_pos = EF9364_NB_OF_ROWS - 1; + } + break; + + case 0x3: // Nop + + break; + + case 0x4: // Cursor left + if(x_curs_pos) + x_curs_pos--; + break; + + case 0x5: // Erasure of cursor Line. + for( x = 0 ; x < EF9364_NB_OF_COLUMNS ; x++ ) + { + m_textram->write_byte ( y_curs_pos * EF9364_NB_OF_COLUMNS + x , 0x7F ); + } + break; + + case 0x6: // Cursor up + if(y_curs_pos) + y_curs_pos--; + break; + + case 0x7: // Write char + if(cmd&0x8) + m_textram->write_byte ( y_curs_pos * EF9364_NB_OF_COLUMNS + x_curs_pos , char_latch ); + + x_curs_pos++; + if( x_curs_pos >= EF9364_NB_OF_COLUMNS ) + { + x_curs_pos=0; + y_curs_pos++; + if( y_curs_pos >= EF9364_NB_OF_ROWS ) + { + // Scroll + for( j = 1 ; j < EF9364_NB_OF_ROWS ; j++ ) + { + for( i = 0 ; i < EF9364_NB_OF_COLUMNS ; i++ ) + { + m_textram->write_byte ( (j-1) * EF9364_NB_OF_COLUMNS + i , m_textram->read_byte ( j * EF9364_NB_OF_COLUMNS + i ) ); + } + } + // Erase last line + for( i = 0 ; i < EF9364_NB_OF_COLUMNS ; i++ ) + { + m_textram->write_byte ( ( EF9364_NB_OF_ROWS - 1 ) * EF9364_NB_OF_COLUMNS + i , 0x7F ); + } + + y_curs_pos = EF9364_NB_OF_ROWS - 1; + } + } + break; + + } } void ef9364_device::char_latch_w(UINT8 data) { - char_latch = data; + char_latch = data; } diff --git a/src/devices/video/ef9364.h b/src/devices/video/ef9364.h index 1519d817196..4c5f57bb211 100644 --- a/src/devices/video/ef9364.h +++ b/src/devices/video/ef9364.h @@ -20,13 +20,13 @@ #define EF9364_MAX_TXTPLANES 2 #define MCFG_EF9364_PALETTE(_palette_tag) \ - ef9364_device::static_set_palette_tag(*device, "^" _palette_tag); + ef9364_device::static_set_palette_tag(*device, "^" _palette_tag); #define MCFG_EF9364_PAGES_CNT(_pages_number) \ - ef9364_device::static_set_nb_of_pages(*device,_pages_number); + ef9364_device::static_set_nb_of_pages(*device,_pages_number); #define MCFG_EF9364_IRQ_HANDLER(_devcb) \ - devcb = &ef9364_device::set_irq_handler(*device, DEVCB_##_devcb); + devcb = &ef9364_device::set_irq_handler(*device, DEVCB_##_devcb); //************************************************************************** // TYPE DEFINITIONS @@ -35,67 +35,67 @@ // ======================> ef9364_device class ef9364_device : public device_t, - public device_memory_interface, - public device_video_interface + public device_memory_interface, + public device_video_interface { public: - // construction/destruction - ef9364_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock); + // construction/destruction + ef9364_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock); - // static configuration - static void static_set_palette_tag(device_t &device, const char *tag); - static void static_set_nb_of_pages(device_t &device, int nb_bitplanes ); + // static configuration + static void static_set_palette_tag(device_t &device, const char *tag); + static void static_set_nb_of_pages(device_t &device, int nb_bitplanes ); - // device interface + // device interface - void update_scanline(UINT16 scanline); - void set_color_entry( int index, UINT8 r, UINT8 g, UINT8 b ); + void update_scanline(UINT16 scanline); + void set_color_entry( int index, UINT8 r, UINT8 g, UINT8 b ); - UINT32 screen_update(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect); - void char_latch_w(UINT8 data); - void command_w(UINT8 cmd); + UINT32 screen_update(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect); + void char_latch_w(UINT8 data); + void command_w(UINT8 cmd); protected: - // device-level overrides - virtual void device_start() override; - virtual void device_reset() override; + // device-level overrides + virtual void device_start() override; + virtual void device_reset() override; - // device_config_memory_interface overrides - virtual const address_space_config *memory_space_config(address_spacenum spacenum = AS_0) const override; + // device_config_memory_interface overrides + virtual const address_space_config *memory_space_config(address_spacenum spacenum = AS_0) const override; - // address space configurations - const address_space_config m_space_config; + // address space configurations + const address_space_config m_space_config; - // inline helper + // inline helper private: - void screen_scanning( int force_clear ); - void set_video_mode(void); - void draw_border(UINT16 line); + void screen_scanning( int force_clear ); + void set_video_mode(void); + void draw_border(UINT16 line); - // internal state + // internal state - memory_region *m_charset; - address_space *m_textram; + memory_region *m_charset; + address_space *m_textram; - UINT8 x_curs_pos; - UINT8 y_curs_pos; - UINT8 char_latch; + UINT8 x_curs_pos; + UINT8 y_curs_pos; + UINT8 char_latch; - UINT8 m_border[80]; //border color + UINT8 m_border[80]; //border color - rgb_t palette[2]; - int nb_of_pages; - int bitplane_xres; - int bitplane_yres; - int vsync_scanline_pos; - int cursor_cnt; - int cursor_state; + rgb_t palette[2]; + int nb_of_pages; + int bitplane_xres; + int bitplane_yres; + int vsync_scanline_pos; + int cursor_cnt; + int cursor_state; - UINT32 clock_freq; - bitmap_rgb32 m_screen_out; + UINT32 clock_freq; + bitmap_rgb32 m_screen_out; - required_device<palette_device> m_palette; + required_device<palette_device> m_palette; }; // device type definition diff --git a/src/devices/video/jangou_blitter.cpp b/src/devices/video/jangou_blitter.cpp index e2acdb37ca1..032ed96a4ed 100644 --- a/src/devices/video/jangou_blitter.cpp +++ b/src/devices/video/jangou_blitter.cpp @@ -2,15 +2,15 @@ // copyright-holders:Angelo Salese /*************************************************************************** - Jangou Custom Blitter Chip, codename "???" (name scratched afaik) + Jangou Custom Blitter Chip, codename "???" (name scratched afaik) - device emulation by Angelo Salese, from original jangou.cpp implementation - by Angelo Salese, David Haywood and Phil Bennett. + device emulation by Angelo Salese, from original jangou.cpp implementation + by Angelo Salese, David Haywood and Phil Bennett. + + TODO: + - BLTFLIP mechanism; + - clean-ups; - TODO: - - BLTFLIP mechanism; - - clean-ups; - ***************************************************************************/ #include "emu.h" @@ -51,7 +51,7 @@ void jangou_blitter_device::device_start() if (m_gfxrom == nullptr) fatalerror("JANGOU_BLITTER: \"gfx\" memory base not found"); m_gfxrommask = devregion->bytes()-1; - + save_item(NAME(m_pen_data)); save_item(NAME(m_blit_data)); save_item(NAME(m_blit_buffer)); @@ -84,12 +84,12 @@ UINT8 jangou_blitter_device::gfx_nibble( UINT32 niboffset ) } void jangou_blitter_device::plot_gfx_pixel( UINT8 pix, int x, int y ) -{ +{ if (y < 0 || y >= 256) return; if (x < 0 || x >= 256) return; - + if (x & 1) m_blit_buffer[(y * 256) + (x >> 1)] = (m_blit_buffer[(y * 256) + (x >> 1)] & 0x0f) | ((pix << 4) & 0xf0); else @@ -112,11 +112,11 @@ WRITE8_MEMBER( jangou_blitter_device::process_w ) src |= (m_blit_data[6] & 3) << 16; x = (m_blit_data[2] & 0xff); y = (m_blit_data[3] & 0xff); - + #if 0 if(m_bltflip == true) { - printf("%02x %02x %02x %02x %02x %02x %02x\n", m_blit_data[0], m_blit_data[1], m_blit_data[2],m_blit_data[3], m_blit_data[4], m_blit_data[5],m_blit_data[6]); + printf("%02x %02x %02x %02x %02x %02x %02x\n", m_blit_data[0], m_blit_data[1], m_blit_data[2],m_blit_data[3], m_blit_data[4], m_blit_data[5],m_blit_data[6]); printf("=>"); for(int i=0;i<0x10;i++) printf("%02x ",m_pen_data[i]); @@ -131,7 +131,7 @@ WRITE8_MEMBER( jangou_blitter_device::process_w ) else src -= (w * h) - 1; - + for (ycount = 0; ycount < h; ycount++) { for(xcount = 0; xcount < w; xcount++) @@ -152,9 +152,9 @@ WRITE8_MEMBER( jangou_blitter_device::process_w ) count++; } } - + //UINT32 new_src = src + count; - + // update source and height after blitter operation // TODO: Jangou doesn't agree with this, later HW? #if 0 diff --git a/src/devices/video/jangou_blitter.h b/src/devices/video/jangou_blitter.h index 7a39172e7ca..d5d6e92a55f 100644 --- a/src/devices/video/jangou_blitter.h +++ b/src/devices/video/jangou_blitter.h @@ -43,9 +43,9 @@ public: protected: // device-level overrides - virtual void device_start() override; + virtual void device_start() override; virtual void device_reset() override; - + private: void plot_gfx_pixel( UINT8 pix, int x, int y ); UINT8 gfx_nibble( UINT32 niboffset ); diff --git a/src/devices/video/upd7220.cpp b/src/devices/video/upd7220.cpp index 32d4d2c3c63..070c9e4fbec 100644 --- a/src/devices/video/upd7220.cpp +++ b/src/devices/video/upd7220.cpp @@ -94,7 +94,7 @@ enum #define UPD7220_COMMAND_CCHAR 0x4b #define UPD7220_COMMAND_START 0x6b #define UPD7220_COMMAND_BCTRL 0x0c // & 0xfe -#define UPD7220_COMMAND_05 0x05 +#define UPD7220_COMMAND_05 0x05 #define UPD7220_COMMAND_ZOOM 0x46 #define UPD7220_COMMAND_CURS 0x49 #define UPD7220_COMMAND_PRAM 0x70 // & 0xf0 diff --git a/src/devices/video/voodoo.cpp b/src/devices/video/voodoo.cpp index 7fe0b94a007..025c0fa140f 100644 --- a/src/devices/video/voodoo.cpp +++ b/src/devices/video/voodoo.cpp @@ -960,7 +960,7 @@ TIMER_CALLBACK_MEMBER( voodoo_device::vblank_callback ) /* set a timer for the next off state */ machine().scheduler().timer_set(screen->time_until_pos(0), timer_expired_delegate(FUNC(voodoo_device::vblank_off_callback),this), 0, this); - + /* set internal state and call the client */ fbi.vblank = TRUE; @@ -2877,7 +2877,7 @@ default_case: * *************************************/ INT32 voodoo_device::lfb_direct_w(voodoo_device *vd, offs_t offset, UINT32 data, UINT32 mem_mask) -{ +{ UINT16 *dest; UINT32 destmax; int x, y; @@ -2923,7 +2923,6 @@ INT32 voodoo_device::lfb_direct_w(voodoo_device *vd, offs_t offset, UINT32 data, INT32 voodoo_device::lfb_w(voodoo_device* vd, offs_t offset, UINT32 data, UINT32 mem_mask) { - UINT16 *dest, *depth; UINT32 destmax, depthmax; int sr[2], sg[2], sb[2], sa[2], sw[2]; @@ -3783,7 +3782,6 @@ WRITE32_MEMBER( voodoo_device::voodoo_w ) static UINT32 register_r(voodoo_device *vd, offs_t offset) { - int regnum = offset & 0xff; UINT32 result; @@ -4053,7 +4051,6 @@ static UINT32 lfb_r(voodoo_device *vd, offs_t offset, bool lfb_3d) READ32_MEMBER( voodoo_device::voodoo_r ) { - /* if we have something pending, flush the FIFOs up to the current time */ if (pci.op_pending) flush_fifos(this, machine().time()); @@ -4699,7 +4696,6 @@ WRITE32_MEMBER( voodoo_banshee_device::banshee_agp_w ) WRITE32_MEMBER( voodoo_banshee_device::banshee_w ) { - /* if we have something pending, flush the FIFOs up to the current time */ if (pci.op_pending) flush_fifos(this, machine().time()); @@ -5045,7 +5041,7 @@ void voodoo_device::common_start_voodoo(UINT8 type) pci.fifo.in = pci.fifo.out = 0; pci.stall_state = NOT_STALLED; pci.continue_timer = machine().scheduler().timer_alloc(timer_expired_delegate(FUNC(voodoo_device::stall_cpu_callback),this), nullptr); - + /* allocate memory */ tmumem0 = m_tmumem0; tmumem1 = m_tmumem1; diff --git a/src/devices/video/voodoo.h b/src/devices/video/voodoo.h index 1dc1a4a59ec..81951a17087 100644 --- a/src/devices/video/voodoo.h +++ b/src/devices/video/voodoo.h @@ -1777,7 +1777,7 @@ public: const char * m_cputag; devcb_write_line m_vblank; devcb_write_line m_stall; - + TIMER_CALLBACK_MEMBER( vblank_off_callback ); TIMER_CALLBACK_MEMBER( stall_cpu_callback ); TIMER_CALLBACK_MEMBER( vblank_callback ); @@ -1826,11 +1826,9 @@ public: static void raster_generic_2tmu(void *dest, INT32 scanline, const poly_extent *extent, const void *extradata, int threadid); #define RASTERIZER_HEADER(name) \ - static void raster_##name(void *destbase, INT32 y, const poly_extent *extent, const void *extradata, int threadid); \ - + static void raster_##name(void *destbase, INT32 y, const poly_extent *extent, const void *extradata, int threadid); #define RASTERIZER_ENTRY(fbzcp, alpha, fog, fbz, tex0, tex1) \ - RASTERIZER_HEADER(fbzcp##_##alpha##_##fog##_##fbz##_##tex0##_##tex1) \ - + RASTERIZER_HEADER(fbzcp##_##alpha##_##fog##_##fbz##_##tex0##_##tex1) #include "voodoo_rast.inc" #undef RASTERIZER_ENTRY |