From b41d2ab5e44647564572c5162bf3109de4aaac82 Mon Sep 17 00:00:00 2001 From: Charlie Stanton Date: Sat, 5 Apr 2025 22:29:17 +0100 Subject: Add other images to SDL --- Makefile | 10 +++++++++- res/exit.png | Bin 0 -> 320 bytes res/pause.png | Bin 0 -> 232 bytes res/play.png | Bin 0 -> 308 bytes res/restart.png | Bin 0 -> 311 bytes src/all.c | 2 +- 6 files changed, 10 insertions(+), 2 deletions(-) create mode 100644 res/exit.png create mode 100644 res/pause.png create mode 100644 res/play.png create mode 100644 res/restart.png diff --git a/Makefile b/Makefile index aa91fae..d48073d 100644 --- a/Makefile +++ b/Makefile @@ -27,12 +27,20 @@ build/%.qoi: res/%.png mkdir -p build magick $< $@ -build/images.c: build/continue.qoi build/img +build/images.c: build/continue.qoi build/exit.qoi build/pause.qoi build/play.qoi build/restart.qoi build/img mkdir -p build (\ build/img pixels build/continue.qoi 1 && \ + build/img pixels build/exit.qoi 2 && \ + build/img pixels build/pause.qoi 3 && \ + build/img pixels build/play.qoi 4 && \ + build/img pixels build/restart.qoi 5 && \ echo 'Image images[] = {{0},' && \ build/img image build/continue.qoi 1 && \ + build/img image build/exit.qoi 2 && \ + build/img image build/pause.qoi 3 && \ + build/img image build/play.qoi 4 && \ + build/img image build/restart.qoi 5 && \ echo '};' \ ) > build/images.c diff --git a/res/exit.png b/res/exit.png new file mode 100644 index 0000000..74630b5 Binary files /dev/null and b/res/exit.png differ diff --git a/res/pause.png b/res/pause.png new file mode 100644 index 0000000..0637a60 Binary files /dev/null and b/res/pause.png differ diff --git a/res/play.png b/res/play.png new file mode 100644 index 0000000..a4d4b00 Binary files /dev/null and b/res/play.png differ diff --git a/res/restart.png b/res/restart.png new file mode 100644 index 0000000..8df131a Binary files /dev/null and b/res/restart.png differ diff --git a/src/all.c b/src/all.c index e5c86db..7955b90 100644 --- a/src/all.c +++ b/src/all.c @@ -139,7 +139,7 @@ static DrawList *render(State *state, UI *ui, Arena *a) { .h = cellHeight, .fill = {255, 0, 0, 63}, .border = {255, 0, 0, 255}, - .image = 1, + .image = 5, }; drawList->els[drawList->len++] = (DrawElement) { -- cgit v1.2.3