aboutsummaryrefslogtreecommitdiffstats
path: root/src/uxn/devices/ppu.h
diff options
context:
space:
mode:
authorBad Diode <bd@badd10de.dev>2021-05-19 12:13:29 +0200
committerBad Diode <bd@badd10de.dev>2021-05-19 12:13:29 +0200
commit9873680f9d24e30afc1962987fac2c3ad1612f7b (patch)
tree5135bd3bd1d0e41c8725d51c7a56c1b0a1e2f904 /src/uxn/devices/ppu.h
parenta2f89131491a4cf7914becfd98d277544d26579a (diff)
downloaduxngba-9873680f9d24e30afc1962987fac2c3ad1612f7b.tar.gz
uxngba-9873680f9d24e30afc1962987fac2c3ad1612f7b.zip
Update screen rendering to use 2 backgrounds
Diffstat (limited to 'src/uxn/devices/ppu.h')
-rw-r--r--src/uxn/devices/ppu.h10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/uxn/devices/ppu.h b/src/uxn/devices/ppu.h
index 187d364..213dc75 100644
--- a/src/uxn/devices/ppu.h
+++ b/src/uxn/devices/ppu.h
@@ -7,6 +7,7 @@
7/* 7/*
8Copyright (c) 2021 Devine Lu Linvega 8Copyright (c) 2021 Devine Lu Linvega
9Copyright (c) 2021 Andrew Alderwick 9Copyright (c) 2021 Andrew Alderwick
10Copyright (c) 2021 Bad Diode
10 11
11Permission to use, copy, modify, and distribute this software for any 12Permission to use, copy, modify, and distribute this software for any
12purpose with or without fee is hereby granted, provided that the above 13purpose with or without fee is hereby granted, provided that the above
@@ -21,16 +22,15 @@ typedef unsigned short Uint16;
21typedef unsigned int Uint32; 22typedef unsigned int Uint32;
22 23
23typedef struct Ppu { 24typedef struct Ppu {
24 Uint8 *bg, *fg; 25 Uint32 *bg, *fg;
25 Uint16 hor, ver, pad, width, height; 26 Uint16 hor, ver, pad, width, height;
26 Uint16 *output, colors[4];
27} Ppu; 27} Ppu;
28 28
29int initppu(Ppu *p, Uint8 hor, Uint8 ver, Uint8 pad); 29int initppu(Ppu *p, Uint8 hor, Uint8 ver, Uint8 pad);
30void putcolors(Ppu *p, Uint8 *addr); 30void putcolors(Ppu *p, Uint8 *addr);
31void putpixel(Ppu *p, Uint8 *layer, Uint16 x, Uint16 y, Uint8 color); 31void putpixel(Ppu *p, Uint32 *layer, Uint16 x, Uint16 y, Uint8 color);
32void puticn(Ppu *p, Uint8 *layer, Uint16 x, Uint16 y, Uint8 *sprite, Uint8 color, Uint8 flipx, Uint8 flipy); 32void puticn(Ppu *p, Uint32 *layer, Uint16 x, Uint16 y, Uint8 *sprite, Uint8 color, Uint8 flipx, Uint8 flipy);
33void putchr(Ppu *p, Uint8 *layer, Uint16 x, Uint16 y, Uint8 *sprite, Uint8 color, Uint8 flipx, Uint8 flipy); 33void putchr(Ppu *p, Uint32 *layer, Uint16 x, Uint16 y, Uint8 *sprite, Uint8 color, Uint8 flipx, Uint8 flipy);
34void drawppu(Ppu *p); 34void drawppu(Ppu *p);
35void drawdebugger(Ppu *p, Uint8 *stack, Uint8 ptr); 35void drawdebugger(Ppu *p, Uint8 *stack, Uint8 ptr);
36#endif // UXNGBA_PPU_H 36#endif // UXNGBA_PPU_H