diff --git a/platform/x86real/pc98/graph.cpp b/platform/x86real/pc98/graph.cpp new file mode 100644 index 00000000..c56589c9 --- /dev/null +++ b/platform/x86real/pc98/graph.cpp @@ -0,0 +1,18 @@ +#include "platform.h" +#include "x86real.h" +#include "platform/x86real/pc98/graph.hpp" + +void graph_show_16color_400line(void) +{ + // Enter 400-line mode + _AH = 0x42; + _CH = 0xC0; + geninterrupt(0x18); + + // Enter 16-color mode + outportb(0x6A, 1); + + // Show VRAM + _AH = 0x40; + geninterrupt(0x18); +} diff --git a/platform/x86real/pc98/graph.hpp b/platform/x86real/pc98/graph.hpp new file mode 100644 index 00000000..600afb8f --- /dev/null +++ b/platform/x86real/pc98/graph.hpp @@ -0,0 +1,5 @@ +// Generic graphics layer functions +// -------------------------------- + +// Puts the graphics GDC into the common 16-color 640×400 graphics mode. +void graph_show_16color_400line(void);