diff options
| author | 3gg <3gg@shellblade.net> | 2026-02-14 19:07:14 -0800 |
|---|---|---|
| committer | 3gg <3gg@shellblade.net> | 2026-02-14 19:07:14 -0800 |
| commit | 2bdc393e9a3987f5e35a967933cde0c4bf3ceeca (patch) | |
| tree | 6b28fdafbd4503f513e3f749f0cfa55e22015f5b | |
| parent | ef56151860ef4fec2ad9177557d7f81977905e2d (diff) | |
Use float colour
| -rw-r--r-- | CMakeLists.txt | 2 | ||||
| -rw-r--r-- | src/main.c | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 7bf9869..ca5a231 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt | |||
| @@ -29,7 +29,7 @@ target_link_libraries(game | |||
| 29 | stb | 29 | stb |
| 30 | swgfx) | 30 | swgfx) |
| 31 | 31 | ||
| 32 | target_compile_options(game PRIVATE -Wall -Wextra) | 32 | target_compile_options(game PRIVATE -Wall -Wextra -Wno-missing-braces) |
| 33 | 33 | ||
| 34 | # Tools. | 34 | # Tools. |
| 35 | 35 | ||
| @@ -274,7 +274,7 @@ static void RenderTriangle2d(swgfx* gfx) { | |||
| 274 | 274 | ||
| 275 | static void Checkerboard(swgfx* gfx, int width, int height) { | 275 | static void Checkerboard(swgfx* gfx, int width, int height) { |
| 276 | assert(gfx); | 276 | assert(gfx); |
| 277 | const sgPixel colour = (sgPixel){255, 0, 255, 255}; | 277 | const sgColour4 colour = (sgColour4){1, 0, 1, 1}; |
| 278 | for (int y = 0; y < height; ++y) { | 278 | for (int y = 0; y < height; ++y) { |
| 279 | for (int x = 0; x < width; ++x) { | 279 | for (int x = 0; x < width; ++x) { |
| 280 | if (((x ^ y) & 1) == 1) { | 280 | if (((x ^ y) & 1) == 1) { |
