Set explicit scaling mode for all SDL textures

This commit is contained in:
Cameron Gutman 2026-01-17 02:34:54 -06:00
commit 218ffc2d55
2 changed files with 5 additions and 3 deletions

View file

@ -251,6 +251,11 @@ void SdlRenderer::renderOverlay(Overlay::OverlayType type)
m_OverlayTextures[type] = SDL_CreateTextureFromSurface(m_Renderer, newSurface);
SDL_FreeSurface(newSurface);
if (m_OverlayTextures[type]) {
// Overlays are always drawn at exact size
SDL_SetTextureScaleMode(m_OverlayTextures[type], SDL_ScaleModeNearest);
}
}
// If we have an overlay texture, render it too