SDL
2.0
|
Go to the source code of this file.
Macros | |
#define | NUM_OBJECTS 100 |
Functions | |
void | DrawPoints (SDL_Renderer *renderer) |
void | DrawLines (SDL_Renderer *renderer) |
void | DrawRects (SDL_Renderer *renderer) |
void | loop () |
int | main (int argc, char *argv[]) |
Variables | |
static SDLTest_CommonState * | state |
static int | num_objects |
static SDL_bool | cycle_color |
static SDL_bool | cycle_alpha |
static int | cycle_direction = 1 |
static int | current_alpha = 255 |
static int | current_color = 255 |
static SDL_BlendMode | blendMode = SDL_BLENDMODE_NONE |
int | done |
#define NUM_OBJECTS 100 |
Definition at line 25 of file testdraw2.c.
void DrawLines | ( | SDL_Renderer * | renderer | ) |
Definition at line 82 of file testdraw2.c.
References current_alpha, current_color, cycle_alpha, cycle_color, cycle_direction, SDL_Rect::h, i, num_objects, renderer, SDL_RenderDrawLine, SDL_RenderGetViewport, SDL_SetRenderDrawColor, viewport, and SDL_Rect::w.
Referenced by loop().
void DrawPoints | ( | SDL_Renderer * | renderer | ) |
Definition at line 39 of file testdraw2.c.
References current_alpha, current_color, cycle_alpha, cycle_color, cycle_direction, SDL_Rect::h, i, num_objects, renderer, SDL_RenderDrawPoint, SDL_RenderGetViewport, SDL_SetRenderDrawColor, viewport, and SDL_Rect::w.
Referenced by loop().
void DrawRects | ( | SDL_Renderer * | renderer | ) |
Definition at line 134 of file testdraw2.c.
References current_alpha, current_color, cycle_alpha, cycle_color, cycle_direction, SDL_Rect::h, i, num_objects, rect, renderer, SDL_RenderFillRect, SDL_RenderGetViewport, SDL_SetRenderDrawColor, viewport, SDL_Rect::w, SDL_Rect::x, and SDL_Rect::y.
Referenced by loop().
void loop | ( | ) |
Definition at line 179 of file testdraw2.c.
References done, DrawLines(), DrawPoints(), DrawRects(), i, NULL, SDLTest_CommonState::num_windows, renderer, SDLTest_CommonState::renderers, SDL_PollEvent, SDL_RenderClear, SDL_RenderPresent, SDL_SetRenderDrawColor, SDLTest_CommonEvent(), state, and SDLTest_CommonState::windows.
Referenced by main().
int main | ( | int | argc, |
char * | argv[] | ||
) |
Definition at line 209 of file testdraw2.c.
References blendMode, cycle_alpha, cycle_color, done, i, loop(), NULL, NUM_OBJECTS, num_objects, SDLTest_CommonState::num_windows, renderer, SDLTest_CommonState::renderers, SDL_atoi, SDL_BLENDMODE_ADD, SDL_BLENDMODE_BLEND, SDL_BLENDMODE_MOD, SDL_BLENDMODE_NONE, SDL_GetTicks(), SDL_INIT_VIDEO, SDL_isdigit, SDL_Log, SDL_LOG_CATEGORY_APPLICATION, SDL_LOG_PRIORITY_INFO, SDL_LogSetPriority, SDL_RenderClear, SDL_SetRenderDrawBlendMode, SDL_SetRenderDrawColor, SDL_strcasecmp, SDL_TRUE, SDLTest_CommonArg(), SDLTest_CommonCreateState(), SDLTest_CommonInit(), SDLTest_CommonQuit(), SDLTest_CommonUsage(), and state.
|
static |
Definition at line 34 of file testdraw2.c.
Referenced by _surfaceSetUp(), IsSupportedBlendMode(), main(), SDL_BlendFillRect(), SDL_BlendFillRect_ARGB8888(), SDL_BlendFillRect_RGB(), SDL_BlendFillRect_RGB555(), SDL_BlendFillRect_RGB565(), SDL_BlendFillRect_RGB888(), SDL_BlendFillRect_RGBA(), SDL_BlendFillRects(), SDL_BlendLine(), SDL_BlendLine_ARGB8888(), SDL_BlendLine_RGB2(), SDL_BlendLine_RGB4(), SDL_BlendLine_RGB555(), SDL_BlendLine_RGB565(), SDL_BlendLine_RGB888(), SDL_BlendLine_RGBA4(), SDL_BlendLines(), SDL_BlendPoint(), SDL_BlendPoint_ARGB8888(), SDL_BlendPoint_RGB(), SDL_BlendPoint_RGB555(), SDL_BlendPoint_RGB565(), SDL_BlendPoint_RGB888(), SDL_BlendPoint_RGBA(), SDL_BlendPoints(), SDL_ComposeCustomBlendMode(), SDL_CreateTextureFromSurface(), SDL_GetBlendModeAlphaOperation(), SDL_GetBlendModeColorOperation(), SDL_GetBlendModeDstAlphaFactor(), SDL_GetBlendModeDstColorFactor(), SDL_GetBlendModeSrcAlphaFactor(), SDL_GetBlendModeSrcColorFactor(), SDL_GetLongBlendMode(), SDL_GetRenderDrawBlendMode(), SDL_GetShortBlendMode(), SDL_GetSurfaceBlendMode(), SDL_GetTextureBlendMode(), SDL_SetRenderDrawBlendMode(), SDL_SetSurfaceBlendMode(), and SDL_SetTextureBlendMode().
|
static |
Definition at line 32 of file testdraw2.c.
Referenced by DrawLines(), DrawPoints(), and DrawRects().
|
static |
Definition at line 33 of file testdraw2.c.
Referenced by DrawLines(), DrawPoints(), and DrawRects().
|
static |
Definition at line 30 of file testdraw2.c.
Referenced by DrawLines(), DrawPoints(), DrawRects(), and main().
|
static |
Definition at line 29 of file testdraw2.c.
Referenced by DrawLines(), DrawPoints(), DrawRects(), and main().
|
static |
Definition at line 31 of file testdraw2.c.
Referenced by DrawLines(), DrawPoints(), and DrawRects().
int done |
Definition at line 36 of file testdraw2.c.
|
static |
Definition at line 28 of file testdraw2.c.
Referenced by DrawLines(), DrawPoints(), DrawRects(), and main().
|
static |
Definition at line 27 of file testdraw2.c.