--- a/src/texture.c Sat Aug 02 15:19:06 2025 +0200 +++ b/src/texture.c Sat Aug 02 15:45:43 2025 +0200 @@ -90,6 +90,10 @@ 0, format, GL_UNSIGNED_BYTE, surface->pixels); asc_error_catch_gl("Writing texture data"); + if (tex->use_mipmaps) { + glGenerateTextureMipmap(tex->tex_id); + asc_error_catch_gl("Generating texture mipmaps"); + } } void asc_texture_from_file(AscTexture *tex, const char *name) { @@ -137,6 +141,7 @@ memset(&tex[i], 0, sizeof(AscTexture)); tex[i].tex_id = textures[i]; tex[i].target = texture_targets[target]; + tex[i].use_mipmaps = min_filter > 1; glBindTexture(tex[i].target, tex[i].tex_id); glTexParameteri(tex[i].target, GL_TEXTURE_MIN_FILTER, texture_filters[min_filter]);