diff options
author | 2025-05-22 12:34:20 +0200 | |
---|---|---|
committer | 2025-05-22 12:34:20 +0200 | |
commit | 0c7a2228b73f48ce58159af77fdf55cf9c682422 (patch) | |
tree | 1c3dd7b2e01768b43a3463607d1bd4bd978ba7ca /src/main/engine | |
parent | 4c3cee6bf51ecba1cd03c457e3facc1947e9fedc (diff) | |
download | tris-0c7a2228b73f48ce58159af77fdf55cf9c682422.tar.gz tris-0c7a2228b73f48ce58159af77fdf55cf9c682422.zip |
Add some default background
Diffstat (limited to 'src/main/engine')
-rw-r--r-- | src/main/engine/engine.c | 6 | ||||
-rw-r--r-- | src/main/engine/engine.h | 1 |
2 files changed, 7 insertions, 0 deletions
diff --git a/src/main/engine/engine.c b/src/main/engine/engine.c index fb0875a..3b77b40 100644 --- a/src/main/engine/engine.c +++ b/src/main/engine/engine.c @@ -314,3 +314,9 @@ engine_set_rendering_background(Engine *engine, float r, float g, float b, float color_set_rgba(engine->rendering_background, r, g, b, a); } } + +void +engine_set_rendering_background_c(Engine *engine, Color *color) +{ + engine_set_rendering_background(engine, color->r, color->g, color->b, color->a); +} diff --git a/src/main/engine/engine.h b/src/main/engine/engine.h index 1e26f05..b70c8c2 100644 --- a/src/main/engine/engine.h +++ b/src/main/engine/engine.h @@ -39,6 +39,7 @@ typedef struct { Engine *engine_new(int width, int height); void engine_set_rendering_background(Engine *engine, float r, float g, float b, float a); +void engine_set_rendering_background_c(Engine *engine, Color *color); void engine_draw_circle(float cx, float cy, float r, int num_segments, int outline); void engine_draw_line(float x1, float y1, float x2, float y2); void engine_loop(void); |