22 #include <emscripten/emscripten.h> 30 #define MOOSEFRAME_SIZE (MOOSEPIC_W * MOOSEPIC_H) 31 #define MOOSEFRAMES_COUNT 10 34 {49, 49, 49, 255}, {66, 24, 0, 255}, {66, 33, 0, 255}, {66, 66, 66, 255},
35 {66, 115, 49, 255}, {74, 33, 0, 255}, {74, 41, 16, 255}, {82, 33, 8, 255},
36 {82, 41, 8, 255}, {82, 49, 16, 255}, {82, 82, 82, 255}, {90, 41, 8, 255},
37 {90, 41, 16, 255}, {90, 57, 24, 255}, {99, 49, 16, 255}, {99, 66, 24, 255},
38 {99, 66, 33, 255}, {99, 74, 33, 255}, {107, 57, 24, 255}, {107, 82, 41, 255},
39 {115, 57, 33, 255}, {115, 66, 33, 255}, {115, 66, 41, 255}, {115, 74, 0, 255},
40 {115, 90, 49, 255}, {115, 115, 115, 255}, {123, 82, 0, 255}, {123, 99, 57, 255},
41 {132, 66, 41, 255}, {132, 74, 41, 255}, {132, 90, 8, 255}, {132, 99, 33, 255},
42 {132, 99, 66, 255}, {132, 107, 66, 255}, {140, 74, 49, 255}, {140, 99, 16, 255},
43 {140, 107, 74, 255}, {140, 115, 74, 255}, {148, 107, 24, 255}, {148, 115, 82, 255},
44 {148, 123, 74, 255}, {148, 123, 90, 255}, {156, 115, 33, 255}, {156, 115, 90, 255},
45 {156, 123, 82, 255}, {156, 132, 82, 255}, {156, 132, 99, 255}, {156, 156, 156, 255},
46 {165, 123, 49, 255}, {165, 123, 90, 255}, {165, 132, 82, 255}, {165, 132, 90, 255},
47 {165, 132, 99, 255}, {165, 140, 90, 255}, {173, 132, 57, 255}, {173, 132, 99, 255},
48 {173, 140, 107, 255}, {173, 140, 115, 255}, {173, 148, 99, 255}, {173, 173, 173, 255},
49 {181, 140, 74, 255}, {181, 148, 115, 255}, {181, 148, 123, 255}, {181, 156, 107, 255},
50 {189, 148, 123, 255}, {189, 156, 82, 255}, {189, 156, 123, 255}, {189, 156, 132, 255},
51 {189, 189, 189, 255}, {198, 156, 123, 255}, {198, 165, 132, 255}, {206, 165, 99, 255},
52 {206, 165, 132, 255}, {206, 173, 140, 255}, {206, 206, 206, 255}, {214, 173, 115, 255},
53 {214, 173, 140, 255}, {222, 181, 148, 255}, {222, 189, 132, 255}, {222, 189, 156, 255},
54 {222, 222, 222, 255}, {231, 198, 165, 255}, {231, 231, 231, 255}, {239, 206, 173, 255}
87 color = &MooseColors[*src++];
88 *dst++ = (0xFF000000|(color->
r<<16)|(color->
g<<8)|color->
b);
100 switch (event.
type) {
119 #ifdef __EMSCRIPTEN__ 121 emscripten_cancel_main_loop();
142 if (handle ==
NULL) {
176 #ifdef __EMSCRIPTEN__ 177 emscripten_set_main_loop(
loop, 0, 1);
#define SDL_CreateTexture
#define MOOSEFRAMES_COUNT
#define SDL_RWread(ctx, ptr, size, n)
#define SDL_WINDOWPOS_UNDEFINED
#define SDL_UnlockTexture
GLenum GLenum GLuint texture
EGLImageKHR EGLint EGLint * handle
SDL_Texture * MooseTexture
GLint GLint GLsizei GLsizei GLsizei GLint GLenum GLenum const GLvoid * pixels
#define SDL_LogSetPriority
EGLSurface EGLNativeWindowType * window
SDL_Color MooseColors[84]
The type used to identify a window.
Uint8 MooseFrames[MOOSEFRAMES_COUNT][MOOSEFRAME_SIZE]
int main(int argc, char **argv)
#define SDL_DestroyRenderer
void UpdateTexture(SDL_Texture *texture, int frame)
#define SDL_CreateRenderer
#define SDL_RenderPresent