SDL_LoadBMP_IO(3)

SDL_LoadBMP_IO3

Load a bmp image from a seekable sdl data stream.

Usage

#include "SDL3/SDL.h"

SDL_Surface * SDL_LoadBMP_IO(SDL_IOStream *src, bool closeio);

Header file

Defined in SDL3/SDL_surface.h

Overview

The new surface should be freed with

SDL_DestroySurface (). Not doing so will result in a memory leak.

Function parameters

src

the data stream for the surface.

closeio

if true, calls SDL_CloseIO () on src before returning, even in the case of an error.

Return value

( SDL_Surface
*) Returns a pointer to a new

SDL_Surface
structure or NULL on failure; call

SDL_GetError () for more information.

Thread safety

It is safe to call this function from any thread.

Availability

This function is available since SDL 3.2.0.

From libsdl3-doc 3.2.10+ds-1 in Debian 13 (Trixie). Parsed by carta from the page's man source.