Previous 199869 Revisions Next

r33323 Monday 10th November, 2014 at 20:36:34 UTC by Alex W. Jackson
undrfire.c, groundfx.c: improve documentation (TC0620SCC is the 6bpp tilemap chip) (nw)
[src/mame/drivers]groundfx.c undrfire.c
[src/mame/video]groundfx.c undrfire.c

trunk/src/mame/drivers/groundfx.c
r241834r241835
4848
4949    Ground Effects combines the sprite system used in Taito Z games with
5050    the TC0480SCP tilemap chip plus some features from the Taito F3 system.
51    It has an extra tilemap chip which is a dead ringer for the TC0100SCN
52    (check the inits), like Under Fire.
51    It has an extra TC0620SCC tilemap chip which is a 6bpp version of the
52    TC0100SCN (check the inits), like Under Fire.
5353
5454    Ground Effects is effectively a 30Hz game - though the vblank interrupts
5555    still come in at 60Hz, the game uses a hardware frame counter to limit
r241834r241835
190190   AM_RANGE(0x700000, 0x7007ff) AM_RAM AM_SHARE("snd_shared")
191191   AM_RANGE(0x800000, 0x80ffff) AM_DEVREADWRITE("tc0480scp", tc0480scp_device, long_r, long_w)      /* tilemaps */
192192   AM_RANGE(0x830000, 0x83002f) AM_DEVREADWRITE("tc0480scp", tc0480scp_device, ctrl_long_r, ctrl_long_w)  // debugging
193   AM_RANGE(0x900000, 0x90ffff) AM_DEVREADWRITE("tc0100scn", tc0100scn_device, long_r, long_w)    /* piv tilemaps */
193   AM_RANGE(0x900000, 0x90ffff) AM_DEVREADWRITE("tc0100scn", tc0100scn_device, long_r, long_w)    /* 6bpp tilemaps */
194194   AM_RANGE(0x920000, 0x92000f) AM_DEVREADWRITE("tc0100scn", tc0100scn_device, ctrl_long_r, ctrl_long_w)
195195   AM_RANGE(0xa00000, 0xa0ffff) AM_RAM_DEVWRITE("palette", palette_device, write) AM_SHARE("palette")
196196   AM_RANGE(0xb00000, 0xb003ff) AM_RAM                     // ?? single bytes, blending ??
r241834r241835
279279   128*8     /* every sprite takes 128 consecutive bytes */
280280};
281281
282static const gfx_layout pivlayout =
282static const gfx_layout scclayout =
283283{
284284   8,8,    /* 8*8 characters */
285285   RGN_FRAC(1,2),
r241834r241835
293293static GFXDECODE_START( groundfx )
294294   GFXDECODE_ENTRY( "gfx2", 0x0, tile16x16_layout,  4096, 512 )
295295   GFXDECODE_ENTRY( "gfx1", 0x0, charlayout,        0, 512 )
296   GFXDECODE_ENTRY( "gfx3", 0x0, pivlayout,         0, 512 )
296   GFXDECODE_ENTRY( "gfx3", 0x0, scclayout,         0, 512 )
297297GFXDECODE_END
298298
299299
r241834r241835
375375   ROM_LOAD32_BYTE( "d51-07.51", 0x000003, 0x200000, CRC(24b2f97d) SHA1(6980e67b435d189ce897c0301e0411763410ab47) )
376376
377377   ROM_REGION( 0x400000, "gfx3", 0 )
378   ROM_LOAD16_BYTE( "d51-10.95", 0x000000, 0x100000, CRC(d5910604) SHA1(8efe13884cfdef208394ddfe19f43eb1b9f78ff3) )    /* PIV 8x8 tiles, 6bpp */
378   ROM_LOAD16_BYTE( "d51-10.95", 0x000000, 0x100000, CRC(d5910604) SHA1(8efe13884cfdef208394ddfe19f43eb1b9f78ff3) )    /* SCC 8x8 tiles, 6bpp */
379379   ROM_LOAD16_BYTE( "d51-11.96", 0x000001, 0x100000, CRC(fee5f5c6) SHA1(1be88747f9c71c348dd61a8f0040007df3a3e6a6) )
380380   ROM_LOAD       ( "d51-12.97", 0x300000, 0x100000, CRC(d630287b) SHA1(2fa09e1821b7280d193ca9a2a270759c3c3189d1) )
381381   ROM_FILL       (              0x200000, 0x100000, 0 )
r241834r241835
418418   /* Speedup handlers */
419419   m_maincpu->space(AS_PROGRAM).install_read_handler(0x20b574, 0x20b577, read32_delegate(FUNC(groundfx_state::irq_speedup_r_groundfx),this));
420420
421   /* make piv tile GFX format suitable for gfxdecode */
421   /* make SCC tile GFX format suitable for gfxdecode */
422422   offset = size/2;
423423   for (i = size/2+size/4; i<size; i++)
424424   {
trunk/src/mame/drivers/undrfire.c
r241834r241835
77
88    Board Info (Underfire):
99
10        TC0470LIN : ?
10        TC0470LIN : object line buffer?
1111        TC0480SCP : known tilemap chip
1212        TC0510NIO : known input chip
1313        TC0570SPC : must be the object chip (next to spritemap and OBJ roms)
14        TC0590PIV : Piv tilemaps
15        TC0620SCC : lightgun ??? pivot port ???
14        TC0590PIV : object related???
15        TC0620SCC : tilemap chip (6bpp version of TC0100SCN)
1616        TC0650FDA : palette ? (Slapshot and F3 games also have one)
1717
1818    M43E0278A
r241834r241835
4646
4747    Under Fire combines the sprite system used in Taito Z games with
4848    the TC0480SCP tilemap chip plus some features from the Taito F3 system.
49    It has an extra tilemap chip which is a dead ringer for the TC0100SCN
50    (check the inits). Why did Taito give it a different name in this
51    incarnation?
49    It has an extra TC0620SCC tilemap chip which is a 6bpp version of the
50    TC0100SCN (check the inits).
5251
5352
5453    Game misbehaviours
r241834r241835
452451   AM_RANGE(0x700000, 0x7007ff) AM_RAM AM_SHARE("snd_shared")
453452   AM_RANGE(0x800000, 0x80ffff) AM_DEVREADWRITE("tc0480scp", tc0480scp_device, long_r, long_w)        /* tilemaps */
454453   AM_RANGE(0x830000, 0x83002f) AM_DEVREADWRITE("tc0480scp", tc0480scp_device, ctrl_long_r, ctrl_long_w)
455   AM_RANGE(0x900000, 0x90ffff) AM_DEVREADWRITE("tc0100scn", tc0100scn_device, long_r, long_w)        /* piv tilemaps */
454   AM_RANGE(0x900000, 0x90ffff) AM_DEVREADWRITE("tc0100scn", tc0100scn_device, long_r, long_w)        /* 6bpp tilemaps */
456455   AM_RANGE(0x920000, 0x92000f) AM_DEVREADWRITE("tc0100scn", tc0100scn_device, ctrl_long_r, ctrl_long_w)
457456   AM_RANGE(0xa00000, 0xa0ffff) AM_RAM_DEVWRITE("palette", palette_device, write) AM_SHARE("palette")
458457   AM_RANGE(0xb00000, 0xb003ff) AM_RAM                         /* single bytes, blending ??? */
r241834r241835
471470   AM_RANGE(0x700000, 0x7007ff) AM_RAM AM_SHARE("snd_shared")
472471   AM_RANGE(0x800000, 0x80ffff) AM_DEVREADWRITE("tc0480scp", tc0480scp_device, long_r, long_w)        /* tilemaps */
473472   AM_RANGE(0x830000, 0x83002f) AM_DEVREADWRITE("tc0480scp", tc0480scp_device, ctrl_long_r, ctrl_long_w)
474   AM_RANGE(0x900000, 0x90ffff) AM_DEVREADWRITE("tc0100scn", tc0100scn_device, long_r, long_w)        /* piv tilemaps */
473   AM_RANGE(0x900000, 0x90ffff) AM_DEVREADWRITE("tc0100scn", tc0100scn_device, long_r, long_w)        /* 6bpp tilemaps */
475474   AM_RANGE(0x920000, 0x92000f) AM_DEVREADWRITE("tc0100scn", tc0100scn_device, ctrl_long_r, ctrl_long_w)
476475   AM_RANGE(0xa00000, 0xa0ffff) AM_RAM_DEVWRITE("palette", palette_device, write) AM_SHARE("palette")
477476   AM_RANGE(0xb00000, 0xb0000f) AM_RAM /* ? */
r241834r241835
639638   128*8     /* every sprite takes 128 consecutive bytes */
640639};
641640
642static const gfx_layout pivlayout =
641static const gfx_layout scclayout =
643642{
644643   8,8,    /* 8*8 characters */
645644   RGN_FRAC(1,2),
r241834r241835
653652static GFXDECODE_START( undrfire )
654653   GFXDECODE_ENTRY( "gfx2", 0x0, tile16x16_layout,  0, 512 )
655654   GFXDECODE_ENTRY( "gfx1", 0x0, charlayout,        0, 512 )
656   GFXDECODE_ENTRY( "gfx3", 0x0, pivlayout,         0, 512 )
655   GFXDECODE_ENTRY( "gfx3", 0x0, scclayout,         0, 512 )
657656GFXDECODE_END
658657
659658static GFXDECODE_START( cbombers )
660659   GFXDECODE_ENTRY( "gfx2", 0x0, tile16x16_layout,  0, 512 )
661660   GFXDECODE_ENTRY( "gfx1", 0x0, charlayout,        0x1000, 512 )
662   GFXDECODE_ENTRY( "gfx3", 0x0, pivlayout,         0, 512 )
661   GFXDECODE_ENTRY( "gfx3", 0x0, scclayout,         0, 512 )
663662GFXDECODE_END
664663
665664/***********************************************************
r241834r241835
10991098   int size=memregion("gfx3")->bytes();
11001099   int data;
11011100
1102   /* make piv tile GFX format suitable for gfxdecode */
1101   /* make SCC tile GFX format suitable for gfxdecode */
11031102   offset = size/2;
11041103   for (i = size/2+size/4; i<size; i++)
11051104   {
r241834r241835
11291128   int data;
11301129
11311130
1132   /* make piv tile GFX format suitable for gfxdecode */
1131   /* make SCC tile GFX format suitable for gfxdecode */
11331132   offset = size/2;
11341133   for (i = size/2+size/4; i<size; i++)
11351134   {
trunk/src/mame/video/groundfx.c
r241834r241835
197197{
198198   address_space &space = machine().driver_data()->generic_space();
199199   UINT8 layer[5];
200   UINT8 pivlayer[3];
200   UINT8 scclayer[3];
201201   UINT16 priority;
202202
203203   m_tc0100scn->tilemap_update();
r241834r241835
211211   layer[3] = (priority & 0x000f) >>  0;   /* tells us which is top */
212212   layer[4] = 4;   /* text layer always over bg layers */
213213
214   pivlayer[0] = m_tc0100scn->bottomlayer();
215   pivlayer[1] = pivlayer[0]^1;
216   pivlayer[2] = 2;
214   scclayer[0] = m_tc0100scn->bottomlayer();
215   scclayer[1] = scclayer[0]^1;
216   scclayer[2] = 2;
217217
218218   screen.priority().fill(0, cliprect);
219219   bitmap.fill(0, cliprect);   /* wrong color? */
220220
221   m_tc0100scn->tilemap_draw(screen, bitmap, cliprect, pivlayer[0], TILEMAP_DRAW_OPAQUE, 0);
222   m_tc0100scn->tilemap_draw(screen, bitmap, cliprect, pivlayer[1], 0, 0);
221   m_tc0100scn->tilemap_draw(screen, bitmap, cliprect, scclayer[0], TILEMAP_DRAW_OPAQUE, 0);
222   m_tc0100scn->tilemap_draw(screen, bitmap, cliprect, scclayer[1], 0, 0);
223223
224224   /*  BIG HACK!
225225
r241834r241835
244244      m_tc0480scp->tilemap_draw(screen, bitmap, cliprect, layer[2], 0, 4);
245245      m_tc0480scp->tilemap_draw(screen, bitmap, cliprect, layer[3], 0, 8);
246246
247      //m_tc0100scn->tilemap_draw(screen, bitmap, cliprect, 0, pivlayer[2], 0, 0);
247      //m_tc0100scn->tilemap_draw(screen, bitmap, cliprect, 0, scclayer[2], 0, 0);
248248
249249      if (m_tc0480scp->long_r(space, 0x20 / 4, 0xffffffff) != 0x240866) /* Stupid hack for start of race */
250250         m_tc0480scp->tilemap_draw(screen, bitmap, m_hack_cliprect, layer[0], 0, 0);
r241834r241835
257257      m_tc0480scp->tilemap_draw(screen, bitmap, cliprect, layer[2], 0, 4);
258258      m_tc0480scp->tilemap_draw(screen, bitmap, cliprect, layer[3], 0, 8);
259259
260      m_tc0100scn->tilemap_draw(screen, bitmap, cliprect, pivlayer[2], 0, 0);
260      m_tc0100scn->tilemap_draw(screen, bitmap, cliprect, scclayer[2], 0, 0);
261261
262262      draw_sprites(screen, bitmap, cliprect, 0, 44, -574);
263263   }
trunk/src/mame/video/undrfire.c
r241834r241835
347347{
348348   address_space &space = machine().driver_data()->generic_space();
349349   UINT8 layer[5];
350   UINT8 pivlayer[3];
350   UINT8 scclayer[3];
351351   UINT16 priority;
352352
353353#ifdef MAME_DEBUG
354354   if (machine().input().code_pressed_once (KEYCODE_X))
355355   {
356356      m_dislayer[5] ^= 1;
357      popmessage("piv text: %01x",m_dislayer[5]);
357      popmessage("scc text: %01x",m_dislayer[5]);
358358   }
359359   if (machine().input().code_pressed_once (KEYCODE_C))
360360   {
r241834r241835
398398   layer[3] = (priority & 0x000f) >>  0;   /* tells us which is top */
399399   layer[4] = 4;   /* text layer always over bg layers */
400400
401   pivlayer[0] = m_tc0100scn->bottomlayer();
402   pivlayer[1] = pivlayer[0] ^ 1;
403   pivlayer[2] = 2;
401   scclayer[0] = m_tc0100scn->bottomlayer();
402   scclayer[1] = scclayer[0] ^ 1;
403   scclayer[2] = 2;
404404
405405   screen.priority().fill(0, cliprect);
406406   bitmap.fill(0, cliprect);   /* wrong color? */
407407
408408
409/* The "PIV" chip seems to be a renamed TC0100SCN. It has a
409/* The "SCC" chip seems to be a 6bpp TC0100SCN. It has a
410410   bottom layer usually full of bright garish colors that
411411   vaguely mimic the structure of the layers on top. Seems
412412   pointless - it's always hidden by other layers. Does it
413413   serve some blending pupose ? */
414414
415   m_tc0100scn->tilemap_draw(screen, bitmap, cliprect, pivlayer[0], TILEMAP_DRAW_OPAQUE, 0);
416   m_tc0100scn->tilemap_draw(screen, bitmap, cliprect, pivlayer[1], 0, 0);
415   m_tc0100scn->tilemap_draw(screen, bitmap, cliprect, scclayer[0], TILEMAP_DRAW_OPAQUE, 0);
416   m_tc0100scn->tilemap_draw(screen, bitmap, cliprect, scclayer[1], 0, 0);
417417
418418#ifdef MAME_DEBUG
419419   if (m_dislayer[layer[0]]==0)
r241834r241835
455455#ifdef MAME_DEBUG
456456   if (m_dislayer[5]==0)
457457#endif
458   m_tc0100scn->tilemap_draw(screen, bitmap, cliprect, pivlayer[2], 0, 0); /* piv text layer */
458   m_tc0100scn->tilemap_draw(screen, bitmap, cliprect, scclayer[2], 0, 0); /* TC0620SCC text layer */
459459
460460   m_tc0480scp->tilemap_draw(screen, bitmap, cliprect, layer[4], 0, 0);    /* TC0480SCP text layer */
461461
r241834r241835
488488{
489489   address_space &space = machine().driver_data()->generic_space();
490490   UINT8 layer[5];
491   UINT8 pivlayer[3];
491   UINT8 scclayer[3];
492492   UINT16 priority;
493493
494494#ifdef MAME_DEBUG
495495   if (machine().input().code_pressed_once (KEYCODE_X))
496496   {
497497      m_dislayer[5] ^= 1;
498      popmessage("piv text: %01x",m_dislayer[5]);
498      popmessage("scc text: %01x",m_dislayer[5]);
499499   }
500500   if (machine().input().code_pressed_once (KEYCODE_C))
501501   {
r241834r241835
539539   layer[3] = (priority & 0x000f) >>  0;   /* tells us which is top */
540540   layer[4] = 4;   /* text layer always over bg layers */
541541
542   pivlayer[0] = m_tc0100scn->bottomlayer();
543   pivlayer[1] = pivlayer[0] ^ 1;
544   pivlayer[2] = 2;
542   scclayer[0] = m_tc0100scn->bottomlayer();
543   scclayer[1] = scclayer[0] ^ 1;
544   scclayer[2] = 2;
545545
546546   screen.priority().fill(0, cliprect);
547547   bitmap.fill(0, cliprect);   /* wrong color? */
548548
549549
550/* The "PIV" chip seems to be a renamed TC0100SCN. It has a
550/* The "SCC" chip seems to be a 6bpp TC0100SCN. It has a
551551   bottom layer usually full of bright garish colors that
552552   vaguely mimic the structure of the layers on top. Seems
553553   pointless - it's always hidden by other layers. Does it
554554   serve some blending pupose ? */
555555
556   m_tc0100scn->tilemap_draw(screen, bitmap, cliprect, pivlayer[0], TILEMAP_DRAW_OPAQUE, 0);
557   m_tc0100scn->tilemap_draw(screen, bitmap, cliprect, pivlayer[1], 0, 0);
556   m_tc0100scn->tilemap_draw(screen, bitmap, cliprect, scclayer[0], TILEMAP_DRAW_OPAQUE, 0);
557   m_tc0100scn->tilemap_draw(screen, bitmap, cliprect, scclayer[1], 0, 0);
558558
559559#ifdef MAME_DEBUG
560560   if (m_dislayer[layer[0]]==0)
r241834r241835
596596#ifdef MAME_DEBUG
597597   if (m_dislayer[5]==0)
598598#endif
599   m_tc0100scn->tilemap_draw(screen, bitmap, cliprect, pivlayer[2], 0, 0); /* piv text layer */
599   m_tc0100scn->tilemap_draw(screen, bitmap, cliprect, scclayer[2], 0, 0); /* TC0620SCC text layer */
600600
601601   m_tc0480scp->tilemap_draw(screen, bitmap, cliprect, layer[4], 0, 0);    /* TC0480SCP text layer */
602602


Previous 199869 Revisions Next


© 1997-2024 The MAME Team