summaryrefslogtreecommitdiff
path: root/lib/nes/display.cc
diff options
context:
space:
mode:
authorHannes Schulze <haschu0103@outlook.de>2025-01-23 22:02:11 +0100
committerHannes Schulze <haschu0103@outlook.de>2025-01-23 22:02:11 +0100
commitb1d1573702f21e3104606d6ade5f5d39ec86a33a (patch)
treed703be130a5d6f9ff2626313d3380ed34de44dd7 /lib/nes/display.cc
parent6512dd599d13035f6a90b2009344e02c488f5aae (diff)
restructure project
Diffstat (limited to 'lib/nes/display.cc')
-rw-r--r--lib/nes/display.cc16
1 files changed, 16 insertions, 0 deletions
diff --git a/lib/nes/display.cc b/lib/nes/display.cc
new file mode 100644
index 0000000..4ff1d5f
--- /dev/null
+++ b/lib/nes/display.cc
@@ -0,0 +1,16 @@
+#include "nes/display.hh"
+#include "nes/util/rgb.hh"
+
+namespace nes
+{
+ auto display::clear(rgb const color) -> void
+ {
+ for (auto y = unsigned{ 0 }; y < height; ++y)
+ {
+ for (auto x = unsigned{ 0 }; x < width; ++x)
+ {
+ set(x, y, color);
+ }
+ }
+ }
+} // namespace nes \ No newline at end of file