- [WIP] Comence amb el propertygrid

- [NEW] Módul aux
- [WIP] Módul tilemap ja mostra el mapa
- [FIX] japi/draw: les textures han de vores en NEAREST
This commit is contained in:
2025-11-18 17:12:53 +01:00
parent d686673b8e
commit 03baa43543
8 changed files with 183 additions and 1 deletions

View File

@@ -45,7 +45,10 @@ namespace draw
SDL_Texture *createSurface(const uint16_t w, const uint16_t h)
{
return SDL_CreateTexture(sdl_renderer, SDL_PIXELFORMAT_ARGB8888, SDL_TEXTUREACCESS_TARGET, w, h);
SDL_Texture *surf = SDL_CreateTexture(sdl_renderer, SDL_PIXELFORMAT_ARGB8888, SDL_TEXTUREACCESS_TARGET, w, h);
SDL_SetTextureScaleMode(surf, SDL_SCALEMODE_NEAREST);
return surf;
}
SDL_Texture *loadSurface(const char *filename, const int transparent)
@@ -61,6 +64,7 @@ namespace draw
uint32_t *pal = LoadPalette(buffer, &paletteSize);
SDL_Texture *surf = SDL_CreateTexture(sdl_renderer, SDL_PIXELFORMAT_ARGB8888, SDL_TEXTUREACCESS_STREAMING, w, h);
SDL_SetTextureScaleMode(surf, SDL_SCALEMODE_NEAREST);
SDL_SetTextureBlendMode(surf, SDL_BLENDMODE_BLEND);
Uint32 *sdl_pixels;