From d0e2dc99d2305ecea709632c75027fd33d863088 Mon Sep 17 00:00:00 2001 From: Ulysse Cura Date: Sat, 8 Aug 2026 19:10:59 +0200 Subject: [PATCH] Done working on asset corruption. --- src/asset_manager.c | 16 ---------------- 1 file changed, 16 deletions(-) diff --git a/src/asset_manager.c b/src/asset_manager.c index 05f5fd8..e41bc09 100644 --- a/src/asset_manager.c +++ b/src/asset_manager.c @@ -190,22 +190,6 @@ static inline int load_texture(asset_t *asset, asset_header_def_t *asset_header_ return EXIT_FAILURE; } - for(size_t i = 0; i < height; i++) - { - for(size_t j = 0; j < width; j += sizeof(uint16_t)) - { - uint8_t r, g, b; - - r = *(uint16_t *)&tmp_surface->pixels[i * sizeof(uint16_t) * width + j] & 0x001F; - g = *(uint16_t *)&tmp_surface->pixels[i * sizeof(uint16_t) * width + j + 1] >> 5; - b = *(uint16_t *)&tmp_surface->pixels[i * sizeof(uint16_t) * width + j + 2] >> 11; - - printf("\033[48;2;%d;%d;%dm ", r, g, b); - } - - puts("\033[m"); - } - if(!SDL_SetSurfaceColorKey(tmp_surface, true, 0xF81F)) { error_printf("Failed to set color key of temporary surface : %s", SDL_GetError());