twn_textures.c: actually fix srcrect updating lol

This commit is contained in:
veclav talica 2024-09-23 14:07:02 +03:00
parent 53518ff5e1
commit c8469e9416

View File

@ -231,7 +231,7 @@ static bool update_rects(struct texture_cache *cache, stbrp_rect *rects, stbrp_r
/* updates the atlas location of every rect in the cache */ /* updates the atlas location of every rect in the cache */
static void update_texture_rects_in_atlas(struct texture_cache *cache, stbrp_rect *rects) { static void update_texture_rects_in_atlas(struct texture_cache *cache, stbrp_rect *rects) {
int r = 0; int r = 0;
for (size_t i = 0; i < arrlenu(rects); ++i) { for (size_t i = 0; i < shlenu(cache->hash); ++i) {
if (cache->hash[i].value.loner_texture != 0) if (cache->hash[i].value.loner_texture != 0)
continue; continue;