sdlGetSurfaceBlendMode function

int sdlGetSurfaceBlendMode(
  1. Pointer<SdlSurface> surface,
  2. Pointer<Int32> blendMode
)

Get the blend mode used for blit operations.

\param surface the SDL_Surface structure to query \param blendMode a pointer filled in with the current SDL_BlendMode \returns 0 on success or a negative error code on failure; call SDL_GetError() for more information.

\since This function is available since SDL 2.0.0.

\sa SDL_SetSurfaceBlendMode

extern DECLSPEC int SDLCALL SDL_GetSurfaceBlendMode(SDL_Surface * surface, SDL_BlendMode *blendMode)

Implementation

int sdlGetSurfaceBlendMode(
    Pointer<SdlSurface> surface, Pointer<Int32> blendMode) {
  final sdlGetSurfaceBlendModeLookupFunction = libSdl2.lookupFunction<
      Int32 Function(Pointer<SdlSurface> surface, Pointer<Int32> blendMode),
      int Function(Pointer<SdlSurface> surface,
          Pointer<Int32> blendMode)>('SDL_GetSurfaceBlendMode');
  return sdlGetSurfaceBlendModeLookupFunction(surface, blendMode);
}