# HG changeset patch # User atmos4 # Date 1002980339 0 # Node ID a7e539b11ba0d6babf334ebffd6606ddfcf55109 # Parent d90f8fc7ead64e894f4c8392b9eb1ac0eafa104a Fix non-X11 build diff -r d90f8fc7ead6 -r a7e539b11ba0 libvo/vo_sdl.c --- a/libvo/vo_sdl.c Sat Oct 13 11:58:41 2001 +0000 +++ b/libvo/vo_sdl.c Sat Oct 13 13:38:59 2001 +0000 @@ -565,10 +565,18 @@ /* calculate new video size/aspect */ if(!priv->mode) { if(priv->fulltype&FS) { +#ifdef HAVE_X11 aspect(&newwidth, &newheight, priv->XWidth ? priv->XWidth : priv->dstwidth, priv->XHeight ? priv->XHeight : priv->dstheight); +#else + aspect(&newwidth, &newheight, priv->dstwidth, priv->dstheight); +#endif } else if(priv->fulltype&VM) { +#ifdef HAVE_X11 aspect(&newwidth, &newheight, priv->dstwidth, (int)((float)priv->dstwidth*((float)priv->XHeight / (float)priv->XWidth))); +#else + aspect(&newwidth, &newheight, priv->dstwidth, priv->dstheight); +#endif } else { aspect(&newwidth, &newheight, priv->fullmodes[mode]->w, priv->fullmodes[mode]->h); } @@ -1085,7 +1093,11 @@ else if ( keypressed == SDLK_n ) { int newwidth = priv->dstwidth, newheight = priv->dstheight; +#ifdef HAVE_X11 aspect(&newwidth, &newheight, priv->dstwidth, (int)((float)priv->dstwidth*((float)priv->XHeight / (float)priv->XWidth))); +#else + aspect(&newwidth, &newheight, priv->dstwidth, priv->dstheight); +#endif if (priv->surface->w != newwidth || priv->surface->h != newheight) { priv->surface = SDL_SetVideoMode(newwidth, newheight, priv->bpp, priv->sdlflags); priv->windowsize.w = priv->surface->w;