From 7d148924e2fee1a2692d2c49a01e6770b630f906 Mon Sep 17 00:00:00 2001 From: vin Date: Sun, 21 Jul 2024 13:53:04 -0400 Subject: start implementing PPU --- ppu.h | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 ppu.h (limited to 'ppu.h') diff --git a/ppu.h b/ppu.h new file mode 100644 index 0000000..1527b93 --- /dev/null +++ b/ppu.h @@ -0,0 +1,23 @@ +#ifndef PPU_H +#define PPU_H + +#include +#include + +#include "rom.h" + +struct ppu { + uint8_t oam[64*4]; + uint8_t vram[2048]; + uint8_t palette[16*2]; + uint16_t cycles, scanlines; + /* copied from rom */ + uint8_t *chr_rom; + size_t chr_rom_size; + enum screen_mirroring mirror; +}; +extern struct ppu ppu; + +void ppu_tick(void); + +#endif /* PPU_H */ -- cgit v1.2.3