SDL
2.0
|
Go to the source code of this file.
Data Structures | |
struct | DrawState |
Functions | |
static void | quit (int rc) |
SDL_Texture * | LoadTexture (SDL_Renderer *renderer, const char *file, SDL_bool transparent) |
void | Draw (DrawState *s) |
void | loop () |
int | main (int argc, char *argv[]) |
Variables | |
static SDLTest_CommonState * | state |
DrawState * | drawstates |
int | done |
Definition at line 98 of file testrendercopyex.c.
References DrawState::background, SDL_Rect::h, NULL, DrawState::renderer, DrawState::scale_direction, SDL_CreateTexture, SDL_DestroyTexture, SDL_PIXELFORMAT_ARGB8888, SDL_RenderCopy, SDL_RenderCopyEx, SDL_RenderGetViewport, SDL_RenderPresent, SDL_SetRenderTarget, SDL_TEXTUREACCESS_TARGET, DrawState::sprite, DrawState::sprite_rect, viewport, SDL_Rect::w, SDL_Rect::x, and SDL_Rect::y.
Referenced by loop().
SDL_Texture* LoadTexture | ( | SDL_Renderer * | renderer, |
const char * | file, | ||
SDL_bool | transparent | ||
) |
Definition at line 48 of file testrendercopyex.c.
References SDL_PixelFormat::BitsPerPixel, SDL_Surface::format, NULL, SDL_PixelFormat::palette, SDL_Surface::pixels, SDL_CreateTextureFromSurface, SDL_FreeSurface, SDL_GetError, SDL_LoadBMP, SDL_LOG_CATEGORY_APPLICATION, SDL_LogError, SDL_SetColorKey, and SDL_TRUE.
Referenced by main().
void loop | ( | ) |
Definition at line 140 of file testrendercopyex.c.
References done, Draw(), i, NULL, SDLTest_CommonState::num_windows, SDL_PollEvent, SDLTest_CommonEvent(), and SDLTest_CommonState::windows.
Referenced by main().
int main | ( | int | argc, |
char * | argv[] | ||
) |
Definition at line 163 of file testrendercopyex.c.
References DrawState::background, done, SDL_Rect::h, i, LoadTexture(), loop(), NULL, SDLTest_CommonState::num_windows, quit(), DrawState::renderer, SDLTest_CommonState::renderers, DrawState::scale_direction, SDL_FALSE, SDL_GetTicks(), SDL_INIT_VIDEO, SDL_Log, SDL_LOG_CATEGORY_APPLICATION, SDL_LOG_PRIORITY_INFO, SDL_LogSetPriority, SDL_QueryTexture, SDL_stack_alloc, SDL_stack_free, SDL_TRUE, SDLTest_CommonArg(), SDLTest_CommonCreateState(), SDLTest_CommonInit(), SDLTest_CommonUsage(), DrawState::sprite, DrawState::sprite_rect, SDL_Rect::w, DrawState::window, and SDLTest_CommonState::windows.
|
static |
Definition at line 41 of file testrendercopyex.c.
References SDLTest_CommonQuit().
Referenced by main().
int done |
Definition at line 37 of file testrendercopyex.c.
DrawState* drawstates |
Definition at line 36 of file testrendercopyex.c.
|
static |
Definition at line 25 of file testrendercopyex.c.