summaryrefslogtreecommitdiff
path: root/emu/7seg.h
diff options
context:
space:
mode:
authorAndreas Baumann <mail@andreasbaumann.cc>2020-11-29 19:31:22 +0100
committerAndreas Baumann <mail@andreasbaumann.cc>2020-11-29 19:31:22 +0100
commitc7b0b280339064ab1b673ab7767d0318b2e9b72a (patch)
treeb597ee3f3c36db401eccb5bca5e8d7f8a8db8485 /emu/7seg.h
parentaca930d803177cb6ea8ebadd77b6ef09ab2b5b49 (diff)
download6502-c7b0b280339064ab1b673ab7767d0318b2e9b72a.tar.gz
6502-c7b0b280339064ab1b673ab7767d0318b2e9b72a.tar.bz2
7-segment display is now drawn
Diffstat (limited to 'emu/7seg.h')
-rw-r--r--emu/7seg.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/emu/7seg.h b/emu/7seg.h
index 98c6908..4da0e1f 100644
--- a/emu/7seg.h
+++ b/emu/7seg.h
@@ -10,6 +10,11 @@
#include <stdint.h>
#include <stdbool.h>
+#ifdef WITH_GUI
+#include <SDL.h>
+#include <SDL2_gfxPrimitives.h>
+#endif
+
// VIA connected on PORTA to 3 wires leading to the 3 coupled 74HC595
// shift register which enable the ROM address lines to read the LED
// segment data (cells 0-15 contain the encoded 7 segments of 16 hexdigits)
@@ -45,6 +50,9 @@ void seg7_init( seg7_t *seg, uint16_t addr, bool initialize );
uint8_t seg7_read( void *obj, uint16_t addr );
void seg7_write( void *obj, uint16_t addr, uint8_t data );
+#ifdef WITH_GUI
+void seg7_draw( void *obj, SDL_Renderer *renderer );
+#endif
void seg7_deinit( void *obj );
#endif