setBlendMode method

bool setBlendMode(
  1. int blendMode
)

Set the blend mode used for blit operations.

To copy a surface to another surface (or texture) without blending with the existing data, the blendmode of the SOURCE surface should be set to SDL_BLENDMODE_NONE.

\param surface the SDL_Surface structure to update. \param blendMode the SDL_BlendMode to use for blit blending. \returns true on success or false on failure; call SDL_GetError() for more information.

\since This function is available since SDL 3.1.3.

\sa SDL_GetSurfaceBlendMode

extern SDL_DECLSPEC bool SDLCALL SDL_SetSurfaceBlendMode(SDL_Surface *surface, SDL_BlendMode blendMode)

Implementation

bool setBlendMode(int blendMode) {
  return sdlSetSurfaceBlendMode(this, blendMode);
}