caution: this is NOT general! */
| 338 | |
| 339 | /* caution: this is NOT general! */ |
| 340 | static void |
| 341 | dofade(int start, int stop, int inc) |
| 342 | { |
| 343 | int i, j; |
| 344 | for (i = start; (i * inc) <= stop; i += inc) { |
| 345 | for (j = 0; j < amii_numcolors; ++j) { |
| 346 | int r, g, b; |
| 347 | |
| 348 | r = (amiv_init_map[j] & 0xf00) >> 8; |
| 349 | g = (amiv_init_map[j] & 0xf0) >> 4; |
| 350 | b = (amiv_init_map[j] & 0xf); |
| 351 | r = (r * i) / 16; |
| 352 | g = (g * i) / 16; |
| 353 | b = (b * i) / 16; |
| 354 | transpalette[j] = ((r << 8) | (g << 4) | b); |
| 355 | } |
| 356 | LoadRGB4(&HackScreen->ViewPort, transpalette, amii_numcolors); |
| 357 | Delay(1); |
| 358 | } |
| 359 | } |
| 360 | |
| 361 | #endif /* AMII_GRAPHICS */ |
| 362 |