Updates to PocketPC (WinCE) support, thanks to Dmitry Yakimov at
activekitten.com. --HG-- extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/trunk%401155
This commit is contained in:
parent
91121c3104
commit
ba06fd388b
13 changed files with 211 additions and 41 deletions
|
@ -339,12 +339,20 @@ int main(int argc, char *argv[])
|
|||
}
|
||||
|
||||
/* Set 640x480 video mode */
|
||||
#ifndef _WIN32_WCE
|
||||
if ( (screen=SDL_SetVideoMode(640,480,video_bpp,videoflags)) == NULL ) {
|
||||
fprintf(stderr, "Couldn't set 640x480x%d video mode: %s\n",
|
||||
video_bpp, SDL_GetError());
|
||||
quit(2);
|
||||
}
|
||||
|
||||
#else
|
||||
/* Pocket PC */
|
||||
if ( (screen=SDL_SetVideoMode(240,320,video_bpp,SDL_FULLSCREEN)) == NULL ) {
|
||||
fprintf(stderr, "Couldn't set 240x320x%d video mode: %s\n",
|
||||
video_bpp, SDL_GetError());
|
||||
quit(2);
|
||||
}
|
||||
#endif
|
||||
/* Set the surface pixels and refresh! */
|
||||
if ( SDL_LockSurface(screen) < 0 ) {
|
||||
fprintf(stderr, "Couldn't lock the display surface: %s\n",
|
||||
|
|
|
@ -248,11 +248,18 @@ int main(int argc, char *argv[])
|
|||
flip = 0;
|
||||
nofade = 0;
|
||||
delay = 1;
|
||||
|
||||
#ifdef _WIN32_WCE
|
||||
w = 640;
|
||||
h = 320;
|
||||
desired_bpp = 0;
|
||||
video_flags = SDL_FULLSCREEN;
|
||||
#else
|
||||
w = 640;
|
||||
h = 480;
|
||||
desired_bpp = 0;
|
||||
video_flags = 0;
|
||||
|
||||
#endif
|
||||
if ( SDL_Init(SDL_INIT_VIDEO) < 0 ) {
|
||||
fprintf(stderr,
|
||||
"Couldn't initialize SDL: %s\n", SDL_GetError());
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue