Skip to content

Instantly share code, notes, and snippets.

@rmallermartins
Created May 13, 2015 23:27
Show Gist options
  • Save rmallermartins/c468e96fb0b729509153 to your computer and use it in GitHub Desktop.
Save rmallermartins/c468e96fb0b729509153 to your computer and use it in GitHub Desktop.
//SDL_BlitSurface(SDL_Surface* origem, SDL_Rect* rectOrigem, SDL_Surface* destino, SDL_Rect* rectDestino);
SDL_BlitSurface(background, NULL, surface, NULL);
//SDL_UpdateWindowSurface(SDL_Window* janela);
SDL_UpdateWindowSurface(tela);
SDL_Surface* loadImage(string path)
{
SDL_Surface* image = IMG_Load(path.c_str());
if (image == NULL)
{
printf("Não foi possível carregar a imagem! SDL_image Error: %s\n", path.c_str(), IMG_GetError());
}
return image;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment