trunk/src/mame/drivers/coolridr.c
| r21441 | r21442 | |
| 402 | 402 | m_work_queue[0] = osd_work_queue_alloc(WORK_QUEUE_FLAG_HIGH_FREQ); |
| 403 | 403 | m_work_queue[1] = osd_work_queue_alloc(WORK_QUEUE_FLAG_HIGH_FREQ); |
| 404 | 404 | } |
| 405 | | |
| 405 | |
| 406 | 406 | // Blitter state |
| 407 | 407 | UINT16 m_textBytesToWrite; |
| 408 | 408 | INT16 m_blitterSerialCount; |
| r21441 | r21442 | |
| 1029 | 1029 | interestingly there is a bit to determine the screen number this applies to, even if that should already be implied from m_blitterMode |
| 1030 | 1030 | |
| 1031 | 1031 | screen 1 clipping(?) |
| 1032 | | |
| 1032 | |
| 1033 | 1033 | unknown sprite list type 1 - 00000001 003f00f0 027801f7 00000007 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 |
| 1034 | 1034 | unknown sprite list type 1 - 00000001 003f00f0 03e001f7 00000007 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 |
| 1035 | 1035 | unknown sprite list type 1 - 00000001 003f00f0 000700e3 00000007 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 |
| r21441 | r21442 | |
| 1066 | 1066 | unknown sprite list type 1 - 00000001 003f00f0 04f803f7 00000207 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 |
| 1067 | 1067 | unknown sprite list type 1 - 00000001 003f00f0 020701fb 00000207 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 |
| 1068 | 1068 | unknown sprite list type 1 - 00000001 003f00f0 02240363 00000207 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 |
| 1069 | | |
| 1069 | |
| 1070 | 1070 | NOTE, we only copy across [1] [2] and [3] as [0] [1] and [2] |
| 1071 | 1071 | the 3rd dword seems to be some kind of offset, it's 0x207 on the 2nd screen, and the actual x-clip rects are also higher on that screen? |
| 1072 | 1072 | |
| 1073 | 1073 | note this is practically the same format as the sysh1_fb_data_w commands.. |
| 1074 | | |
| 1075 | | |
| 1076 | | |
| 1074 | |
| 1075 | |
| 1076 | |
| 1077 | 1077 | between stages (screen 1) |
| 1078 | 1078 | unknown sprite list type 1 - 00000001 000000a4 000701f7 00000007 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 |
| 1079 | 1079 | unknown sprite list type 1 - 00000001 0000017f 000701f7 00000007 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 |
| r21441 | r21442 | |
| 1301 | 1301 | unknown sprite list type 1 - 00000001 0000017f 000701f7 00000007 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 |
| 1302 | 1302 | unknown sprite list type 1 - 00000001 0000017f 000701f7 00000007 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 |
| 1303 | 1303 | unknown sprite list type 1 - 00000001 0000017f 000701f7 00000007 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 |
| 1304 | | |
| 1304 | |
| 1305 | 1305 | romania |
| 1306 | 1306 | unknown sprite list type 1 - 00000001 00000001 00000001 00000007 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 |
| 1307 | | */ |
| 1307 | */ |
| 1308 | 1308 | |
| 1309 | 1309 | // how does this really work? there's more to it |
| 1310 | 1310 | // used in film strip attract mode, and between stages |
| r21441 | r21442 | |
| 1324 | 1324 | if (clipmaxX<CLIPMINX_FULL) clipmaxX = CLIPMINX_FULL; |
| 1325 | 1325 | if (clipmaxX>CLIPMAXX_FULL) clipmaxX = CLIPMAXX_FULL; |
| 1326 | 1326 | if (clipminX>clipmaxX) clipminX = clipmaxX; |
| 1327 | | |
| 1327 | |
| 1328 | 1328 | clipminY = miny -1; |
| 1329 | 1329 | if (clipminY<CLIPMINY_FULL) clipminY = CLIPMINY_FULL; |
| 1330 | 1330 | if (clipminY>CLIPMAXY_FULL) clipminY = CLIPMAXY_FULL; |
| r21441 | r21442 | |
| 1332 | 1332 | if (clipmaxY<CLIPMINY_FULL) clipmaxY = CLIPMINY_FULL; |
| 1333 | 1333 | if (clipmaxY>CLIPMAXY_FULL) clipmaxY = CLIPMAXY_FULL; |
| 1334 | 1334 | if (clipminY>clipmaxY) clipminY = clipmaxY; |
| 1335 | | |
| 1336 | 1335 | |
| 1336 | |
| 1337 | 1337 | //b1colorNumber = object->state->machine().rand()&0xfff; |
| 1338 | 1338 | } |
| 1339 | 1339 | |
| r21441 | r21442 | |
| 1780 | 1780 | else if (blit0==1) |
| 1781 | 1781 | { |
| 1782 | 1782 | |
| 1783 | | |
| 1784 | 1783 | |
| 1784 | |
| 1785 | 1785 | if (m_blitterMode&0x80) |
| 1786 | 1786 | { |
| 1787 | 1787 | // HACK... |
| r21441 | r21442 | |
| 2226 | 2226 | } |
| 2227 | 2227 | else if(m_rgb_ctrl[screen_num].setting == 0x800) /* when you get hit TODO: algo might be different. */ |
| 2228 | 2228 | { |
| 2229 | | *g &= (0x1f - m_rgb_ctrl[screen_num].gradient); |
| 2230 | | *b &= (0x1f - m_rgb_ctrl[screen_num].gradient); |
| 2229 | *r += m_rgb_ctrl[screen_num].gradient; |
| 2230 | *g -= m_rgb_ctrl[screen_num].gradient; |
| 2231 | *b -= m_rgb_ctrl[screen_num].gradient; |
| 2232 | if(*r > 0x1f) { *r = 0x1f; } |
| 2233 | if(*g < 0) { *g = 0; } |
| 2234 | if(*b < 0) { *b = 0; } |
| 2231 | 2235 | } |
| 2232 | 2236 | else |
| 2233 | 2237 | { |
| r21441 | r21442 | |
| 2238 | 2242 | void coolridr_state::flush_pal_data( UINT16 offset ) |
| 2239 | 2243 | { |
| 2240 | 2244 | int r,g,b; |
| 2241 | | int screen_type = (offset & 0x400) >> 10; |
| 2245 | int screen_type = (offset & 0x200) >> 9; |
| 2242 | 2246 | |
| 2243 | 2247 | r = ((m_h1_pal[offset] & 0x7c00) >> 10); |
| 2244 | 2248 | g = ((m_h1_pal[offset] & 0x03e0) >> 5); |
| r21441 | r21442 | |
| 2342 | 2346 | case 0x44: /* screen 2 / */ |
| 2343 | 2347 | m_rgb_ctrl[(cmd & 4) >> 2].setting = m_framebuffer_vram[(0+dma_index)/4] & 0xffffe0; |
| 2344 | 2348 | m_rgb_ctrl[(cmd & 4) >> 2].gradient = m_framebuffer_vram[(0+dma_index)/4] & 0x1f; |
| 2345 | | for(int i=((cmd & 4) * 0x100);i<((cmd & 4) * 0x100)+0x400;i++) |
| 2349 | |
| 2350 | /* 0x000-0x1ff - 0x400-0x5ff screen 1 */ |
| 2351 | /* 0x200-0x3ff - 0x600-0x7ff screen 2 */ |
| 2352 | for(int i=((cmd & 4) << 7);i<((cmd & 4) << 7)+0x200;i++) |
| 2353 | { |
| 2346 | 2354 | flush_pal_data( i ); |
| 2355 | flush_pal_data( i + 0x400 ); |
| 2356 | } |
| 2357 | |
| 2347 | 2358 | dma_index+=4; |
| 2348 | 2359 | break; |
| 2349 | 2360 | default: |