17 #include <emscripten/emscripten.h> 109 for (row=0; row<32; ++
row) {
110 for (col=0; col<32; ++col) {
116 data[
i] = mask[
i] = 0;
118 switch (image[4+row][col]) {
131 sscanf(image[4+row],
"%d,%d", &hot_x, &hot_y);
176 #ifdef __EMSCRIPTEN__ 178 emscripten_cancel_main_loop();
187 const char *color_cursor =
NULL;
197 for (i = 1; i < argc;) {
202 color_cursor = argv[
i];
228 SDL_Log(
"Error, couldn't create cursor\n");
234 SDL_Log(
"Error, couldn't create system cursor %d\n", i);
242 #ifdef __EMSCRIPTEN__ 243 emscripten_set_main_loop(
loop, 0, 1);
#define SDL_LoadBMP(file)
SDLTest_CommonState * SDLTest_CommonCreateState(char **argv, Uint32 flags)
Parse command line parameters and create common state.
#define SDL_CreateSystemCursor
int SDLTest_CommonArg(SDLTest_CommonState *state, int index)
Process one common argument.
A collection of pixels used in software blitting.
GLint GLenum GLsizei GLsizei GLsizei GLint GLsizei const GLvoid * data
SDL_bool SDLTest_CommonInit(SDLTest_CommonState *state)
Open test window.
static const char * arrow[]
int main(int argc, char *argv[])
void SDLTest_CommonEvent(SDLTest_CommonState *state, SDL_Event *event, int *done)
Common event handler for test windows.
static SDL_Cursor * cursors[1+SDL_NUM_SYSTEM_CURSORS]
static SDL_Renderer * renderer
static SDLTest_CommonState * state
SDL_SystemCursor
Cursor types for SDL_CreateSystemCursor().
static SDL_Cursor * init_color_cursor(const char *file)
#define SDL_CreateColorCursor
const char * SDLTest_CommonUsage(SDLTest_CommonState *state)
Returns common usage information.
SDL_Renderer ** renderers
return Display return Display Bool Bool int int int return Display XEvent Bool(*) XPointer return Display return Display Drawable _Xconst char unsigned int unsigned int return Display Pixmap Pixmap XColor XColor unsigned int unsigned int return Display _Xconst char char int char return Display Visual unsigned int int int char unsigned int unsigned int in i)
static int current_cursor
#define SDL_LogSetPriority
static SDL_Cursor * init_system_cursor(const char *image[])
SDL_MouseButtonEvent button
#define SDL_arraysize(array)
#define SDL_SetRenderDrawColor
void SDLTest_CommonQuit(SDLTest_CommonState *state)
Close test window.
#define SDL_RenderPresent
int uint32_t uint32_t uint32_t uint32_t uint32_t int drmModeModeInfoPtr mode int uint32_t uint32_t uint32_t uint32_t int32_t hot_x