diff options
author | Bad Diode <bd@badd10de.dev> | 2021-05-19 12:13:29 +0200 |
---|---|---|
committer | Bad Diode <bd@badd10de.dev> | 2021-05-19 12:13:29 +0200 |
commit | 9873680f9d24e30afc1962987fac2c3ad1612f7b (patch) | |
tree | 5135bd3bd1d0e41c8725d51c7a56c1b0a1e2f904 /src/uxn/devices/ppu.h | |
parent | a2f89131491a4cf7914becfd98d277544d26579a (diff) | |
download | uxngba-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.h | 10 |
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 | /* |
8 | Copyright (c) 2021 Devine Lu Linvega | 8 | Copyright (c) 2021 Devine Lu Linvega |
9 | Copyright (c) 2021 Andrew Alderwick | 9 | Copyright (c) 2021 Andrew Alderwick |
10 | Copyright (c) 2021 Bad Diode | ||
10 | 11 | ||
11 | Permission to use, copy, modify, and distribute this software for any | 12 | Permission to use, copy, modify, and distribute this software for any |
12 | purpose with or without fee is hereby granted, provided that the above | 13 | purpose with or without fee is hereby granted, provided that the above |
@@ -21,16 +22,15 @@ typedef unsigned short Uint16; | |||
21 | typedef unsigned int Uint32; | 22 | typedef unsigned int Uint32; |
22 | 23 | ||
23 | typedef struct Ppu { | 24 | typedef 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 | ||
29 | int initppu(Ppu *p, Uint8 hor, Uint8 ver, Uint8 pad); | 29 | int initppu(Ppu *p, Uint8 hor, Uint8 ver, Uint8 pad); |
30 | void putcolors(Ppu *p, Uint8 *addr); | 30 | void putcolors(Ppu *p, Uint8 *addr); |
31 | void putpixel(Ppu *p, Uint8 *layer, Uint16 x, Uint16 y, Uint8 color); | 31 | void putpixel(Ppu *p, Uint32 *layer, Uint16 x, Uint16 y, Uint8 color); |
32 | void puticn(Ppu *p, Uint8 *layer, Uint16 x, Uint16 y, Uint8 *sprite, Uint8 color, Uint8 flipx, Uint8 flipy); | 32 | void puticn(Ppu *p, Uint32 *layer, Uint16 x, Uint16 y, Uint8 *sprite, Uint8 color, Uint8 flipx, Uint8 flipy); |
33 | void putchr(Ppu *p, Uint8 *layer, Uint16 x, Uint16 y, Uint8 *sprite, Uint8 color, Uint8 flipx, Uint8 flipy); | 33 | void putchr(Ppu *p, Uint32 *layer, Uint16 x, Uint16 y, Uint8 *sprite, Uint8 color, Uint8 flipx, Uint8 flipy); |
34 | void drawppu(Ppu *p); | 34 | void drawppu(Ppu *p); |
35 | void drawdebugger(Ppu *p, Uint8 *stack, Uint8 ptr); | 35 | void drawdebugger(Ppu *p, Uint8 *stack, Uint8 ptr); |
36 | #endif // UXNGBA_PPU_H | 36 | #endif // UXNGBA_PPU_H |