~ubuntu-branches/ubuntu/lucid/sdlmame/lucid

« back to all changes in this revision

Viewing changes to src/mame/video/vigilant.c

  • Committer: Bazaar Package Importer
  • Author(s): Cesare Falco
  • Date: 2009-11-03 17:10:15 UTC
  • mfrom: (1.1.5 upstream)
  • Revision ID: james.westby@ubuntu.com-20091103171015-6hop4ory5lxnumpn
Tags: 0.135-0ubuntu1
* New upstream release - Closes (LP: #403212)
* debian/watch: unstable releases are no longer detected
* mame.ini: added the cheat subdirectories to cheatpath so zipped
  cheatfiles will be searched too
* renamed crsshair subdirectory to crosshair to reflect upstream change
* mame.ini: renamed references to crosshair subdirectory (see above)

Show diffs side-by-side

added added

removed removed

Lines of Context:
77
77
                {
78
78
                        for( col=0; col<512; col+=32 )
79
79
                        {
80
 
                                drawgfx(bg_bitmap,
81
 
                                                machine->gfx[2],
 
80
                                drawgfx_opaque(bg_bitmap,
 
81
                                                0,machine->gfx[2],
82
82
                                                charcode,
83
83
                                                row < 128 ? 0 : 1,
84
84
                                                0,0,
85
 
                                                512*page + col,row,
86
 
                                                0,TRANSPARENCY_NONE,0);
 
85
                                                512*page + col,row);
87
86
                                charcode++;
88
87
                        }
89
88
                }
202
201
                                {
203
202
                                        sx = (sx + scroll) & 0x1ff;
204
203
 
205
 
                                        drawgfx(bitmap,machine->gfx[0],
 
204
                                        drawgfx_transmask(bitmap,&bottomvisiblearea,machine->gfx[0],
206
205
                                                        tile_number,
207
206
                                                        color,
208
207
                                                        0,0,
209
 
                                                        sx,sy,
210
 
                                                        &bottomvisiblearea,TRANSPARENCY_PENS,0x00ff);
 
208
                                                        sx,sy,0x00ff);
211
209
                                }
212
210
                        }
213
211
                }
216
214
                        if (sy >= 48)
217
215
                                sx = (sx + scroll) & 0x1ff;
218
216
 
219
 
                        drawgfx(bitmap,machine->gfx[0],
 
217
                        drawgfx_transpen(bitmap,cliprect,machine->gfx[0],
220
218
                                        tile_number,
221
219
                                        color,
222
220
                                        0,0,
223
221
                                        sx,sy,
224
 
                                        cliprect,(opaque || color >= 4) ? TRANSPARENCY_NONE : TRANSPARENCY_PEN,0);
 
222
                                        (opaque || color >= 4) ? -1 : 0);
225
223
                }
226
224
        }
227
225
}
269
267
                        if (flipy) c += h-1-y;
270
268
                        else c += y;
271
269
 
272
 
                        drawgfx(bitmap,machine->gfx[1],
 
270
                        drawgfx_transpen(bitmap,cliprect,machine->gfx[1],
273
271
                                        c,
274
272
                                        color,
275
273
                                        flipx,flipy,
276
 
                                        sx,sy + 16*y,
277
 
                                        cliprect,TRANSPARENCY_PEN,0);
 
274
                                        sx,sy + 16*y,0);
278
275
                }
279
276
        }
280
277
}
281
278
 
 
279
VIDEO_UPDATE( kikcubic )
 
280
{
 
281
        int offs;
 
282
 
 
283
        for (offs = 0; offs<videoram_size; offs+=2 )
 
284
        {
 
285
                int sy = 8 * ((offs/2) / 64);
 
286
                int sx = 8 * ((offs/2) % 64);
 
287
                int attributes = videoram[offs+1];
 
288
                int color = (attributes & 0xF0) >> 4;
 
289
                int tile_number = videoram[offs] | ((attributes & 0x0F) << 8);
 
290
 
 
291
                drawgfx_opaque(bitmap,cliprect,screen->machine->gfx[0],
 
292
                                tile_number,
 
293
                                color,
 
294
                                0,0,
 
295
                                sx,sy);
 
296
        }
 
297
 
 
298
        draw_sprites(screen->machine,bitmap,cliprect);
 
299
        return 0;
 
300
}
 
301
 
282
302
VIDEO_UPDATE( vigilant )
283
303
{
284
304
        int i;
317
337
        }
318
338
        return 0;
319
339
}
320
 
 
321
 
VIDEO_UPDATE( kikcubic )
322
 
{
323
 
        int offs;
324
 
 
325
 
 
326
 
        for (offs = 0; offs<videoram_size; offs+=2 )
327
 
        {
328
 
                int sy = 8 * ((offs/2) / 64);
329
 
                int sx = 8 * ((offs/2) % 64);
330
 
                int attributes = videoram[offs+1];
331
 
                int color = (attributes & 0xF0) >> 4;
332
 
                int tile_number = videoram[offs] | ((attributes & 0x0F) << 8);
333
 
 
334
 
                drawgfx(bitmap,screen->machine->gfx[0],
335
 
                                tile_number,
336
 
                                color,
337
 
                                0,0,
338
 
                                sx,sy,
339
 
                                cliprect,TRANSPARENCY_NONE,0);
340
 
        }
341
 
 
342
 
        draw_sprites(screen->machine,bitmap,cliprect);
343
 
        return 0;
344
 
}