diff --git a/src/rendering/sprites.h b/src/rendering/sprites.h index 6825532..2e8d894 100644 --- a/src/rendering/sprites.h +++ b/src/rendering/sprites.h @@ -114,7 +114,7 @@ static struct sprite_batch { .constant_colored = true, }; - const uint32_t uniform_color = *(uint32_t *)&primitives[0].sprite.color; + const uint32_t uniform_color = *(const uint32_t *)&primitives[0].sprite.color; /* batch size is clamped so that reallocated short indices could be used */ if (len >= QUAD_ELEMENT_BUFFER_LENGTH) @@ -137,7 +137,7 @@ static struct sprite_batch { break; /* if all are modulated the same we can skip sending the color data */ - if (batch.constant_colored && *(uint32_t *)¤t->sprite.color == uniform_color) + if (batch.constant_colored && *(const uint32_t *)¤t->sprite.color == uniform_color) batch.constant_colored = false; ++batch.size;