You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Looks like the colourspace logic is initialising the wrong colourspace before testing things...
Simple patch (really doesn't seem necessary to fork/create branch/create pull-request, it's only 1 line :)
diff --git a/src/render/SDL_render.c b/src/render/SDL_render.c
index 06c0381ca..eed841561 100644
--- a/src/render/SDL_render.c
+++ b/src/render/SDL_render.c
@@ -1634,7 +1634,7 @@ SDL_Texture *SDL_CreateTextureFromSurface(SDL_Renderer *renderer, SDL_Surface *s
}
}
- texture_colorspace = SDL_GetSurfaceColorspace(surface);
+ surface_colorspace = SDL_GetSurfaceColorspace(surface);
// Try to have the best pixel format for the texture
// No alpha, but a colorkey => promote to alpha
The first reference to the colourspace is later on down the file, line 1700 at this moment in time, where tests on surface_colorspace are used to determine texture_colorspace
Looks like the colourspace logic is initialising the wrong colourspace before testing things...
Simple patch (really doesn't seem necessary to fork/create branch/create pull-request, it's only 1 line :)
The first reference to the colourspace is later on down the file, line 1700 at this moment in time, where tests on
surface_colorspace
are used to determinetexture_colorspace
So it's pretty clear the intent was to set
surface_colorspace
nottexture_colorspace
Seems that re-implementing the render api to work on top of the GPU API can have some benefits after all :)
The text was updated successfully, but these errors were encountered: