kopia lustrzana https://github.com/OpenRTX/OpenRTX
In SDL engine force display rendering when brightness texture is changed
rodzic
980fa32e73
commit
763eb0c2be
|
@ -259,10 +259,15 @@ static bool set_brightness(uint8_t brightness)
|
|||
* Color modulation is not always supported by the renderer;
|
||||
* it will return -1 if color modulation is not supported.
|
||||
*/
|
||||
return SDL_SetTextureColorMod(displayTexture,
|
||||
brightness,
|
||||
brightness,
|
||||
brightness) == 0;
|
||||
int colMod = SDL_SetTextureColorMod(displayTexture,
|
||||
brightness,
|
||||
brightness,
|
||||
brightness) == 0;
|
||||
|
||||
SDL_RenderCopy(renderer, displayTexture, NULL, NULL);
|
||||
SDL_RenderPresent(renderer);
|
||||
|
||||
return colMod;
|
||||
}
|
||||
|
||||
|
||||
|
|
Ładowanie…
Reference in New Issue