diff options
author | Vito Caputo <vcaputo@pengaru.com> | 2022-04-30 10:13:23 -0700 |
---|---|---|
committer | Vito Caputo <vcaputo@pengaru.com> | 2022-05-01 21:02:44 -0700 |
commit | 17beb406f2033ef522b0aebee07bae64317fa8fe (patch) | |
tree | 0b19666754b4b47a68d9a803060367c3b4876475 /src/modules/swarm/swarm.c | |
parent | a59229c5513e73348c87bcfc5cc4b39a31012437 (diff) |
til_fb: add draw flags for controlling texturability
Just adds TIL_FB_DRAW_FLAG_TEXTURABLE so callers can granularly
inhibit texturing if desired.
Diffstat (limited to 'src/modules/swarm/swarm.c')
-rw-r--r-- | src/modules/swarm/swarm.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/modules/swarm/swarm.c b/src/modules/swarm/swarm.c index e2381ab..2d37e28 100644 --- a/src/modules/swarm/swarm.c +++ b/src/modules/swarm/swarm.c @@ -333,7 +333,7 @@ static void swarm_draw_as_points(swarm_context_t *ctxt, til_fb_fragment_t *fragm boid_t *b = &ctxt->boids[i]; v2f_t nc = swarm_scale(swarm_project_point(ctxt, &b->position), scale); - til_fb_fragment_put_pixel_checked(fragment, nc.x, nc.y, color); + til_fb_fragment_put_pixel_checked(fragment, TIL_FB_DRAW_FLAG_TEXTURABLE, nc.x, nc.y, color); } } @@ -357,7 +357,7 @@ static void draw_line_unchecked(til_fb_fragment_t *fragment, int x1, int y1, int minor -= x_delta; } /* XXX FIXME: segfaults occasionally when _unchecked !!! */ - til_fb_fragment_put_pixel_checked(fragment, x1, y1, color); + til_fb_fragment_put_pixel_checked(fragment, TIL_FB_DRAW_FLAG_TEXTURABLE, x1, y1, color); } } else { /* Y-major */ @@ -368,7 +368,7 @@ static void draw_line_unchecked(til_fb_fragment_t *fragment, int x1, int y1, int } /* XXX FIXME: segfaults occasionally when _unchecked !!! */ - til_fb_fragment_put_pixel_checked(fragment, x1, y1, color); + til_fb_fragment_put_pixel_checked(fragment, TIL_FB_DRAW_FLAG_TEXTURABLE, x1, y1, color); } } } |