Apply white tint to texture

Is there a blend mode for applying white to textures? I’m trying to achieve the invulnerability respawn effect seen in the attached images.

Use SDL_SetTextureColorMod() or SDL_SetTextureColorModFloat()

I can’t get white to show with that function, SDL_SetTextureColorMod(t, 255,255,255) displays the original image

It’s color modulation (the color of each pixel gets multiplied by the value you specify). Try providing values above white. If I was at my computer I’d test this. You might have to use the floating point version of the function (so, supply values above 1.0)

1 Like

values above 1.0 worked, thanks for the help!

1 Like