Previous 199869 Revisions Next

r17895 Friday 14th September, 2012 at 23:11:45 UTC by Barry Rodewald
(MESS) gfxultra: Very basic implementation of the linedraw register, enough to pass the BIOS' test. (no whatsnew)
[src/emu/video]pc_vga.c pc_vga.h
[src/mess/video]isa_vga_ati.c

trunk/src/emu/video/pc_vga.c
r17894r17895
52525252   logerror("Mach8: Bresenham count write %04x\n",data);
52535253}
52545254
5255WRITE16_HANDLER(mach8_linedraw_w)
5256{
5257   // TODO: actually draw the lines
5258   switch(ati.linedraw)
5259   {
5260   case 0:  // Set current X
5261      s3.curr_x = data;
5262      ati.linedraw++;
5263      break;
5264   case 1:  // Set current Y
5265      s3.curr_y = data;
5266      ati.linedraw++;
5267      break;
5268   case 2:  // Line end X
5269      s3.curr_x = data;
5270      ati.linedraw++;
5271      break;
5272   case 3:  // Line end Y
5273      s3.curr_y = data;
5274      ati.linedraw = 2;
5275      break;
5276   case 4:  // Set current X
5277      s3.curr_x = data;
5278      ati.linedraw++;
5279      break;
5280   case 5:  // Set current Y
5281      s3.curr_y = data;
5282      ati.linedraw = 4;
5283      break;
5284   }
5285   logerror("ATI: Linedraw register write %04x, mode %i\n",data,ati.linedraw);
5286}
5287
52555288READ16_HANDLER(mach8_scratch0_r)
52565289{
52575290   return ati.scratch0;
trunk/src/emu/video/pc_vga.h
r17894r17895
125125WRITE16_HANDLER(mach8_vdisp_w);
126126READ16_HANDLER(mach8_vsync_r);
127127WRITE16_HANDLER(mach8_vsync_w);
128WRITE16_HANDLER(mach8_linedraw_w);
128129READ16_HANDLER(mach8_ec0_r);
129130WRITE16_HANDLER(mach8_ec0_w);
130131READ16_HANDLER(mach8_ec1_r);
trunk/src/mess/video/isa_vga_ati.c
r17894r17895
113113   m_isa->install16_device(0xbae8, 0xbaeb, 0, 0, FUNC(s3_foremix_r), FUNC(s3_foremix_w));
114114   m_isa->install16_device(0xbee8, 0xbeeb, 0, 0, FUNC(s3_multifunc_r), FUNC(s3_multifunc_w));
115115   m_isa->install16_device(0xe2e8, 0xe2eb, 0, 0, FUNC(s3_pixel_xfer_r), FUNC(s3_pixel_xfer_w));
116   m_isa->install16_device(0xfeec, 0xfeef, 0, 0, NULL, NULL, FUNC(mach8_linedraw_w));
116117
117118   m_isa->install_memory(0xa0000, 0xbffff, 0, 0, FUNC(ati_mem_r), FUNC(ati_mem_w));
118119}

Previous 199869 Revisions Next


© 1997-2024 The MAME Team