# HG changeset patch # User reimar # Date 1390086511 0 # Node ID 1be891d42dc96aebccd9a4b14db64973ce7d74eb # Parent a76b46200616380e6c2e7e86053a6c777ae0002d vo_sdl: Avoid setenv code duplication. diff -r a76b46200616 -r 1be891d42dc9 libvo/vo_sdl.c --- a/libvo/vo_sdl.c Sat Jan 18 23:08:29 2014 +0000 +++ b/libvo/vo_sdl.c Sat Jan 18 23:08:31 2014 +0000 @@ -1293,12 +1293,10 @@ } /* does the user want SDL to try and force Xv */ - if(sdl_forcexv) setenv("SDL_VIDEO_X11_NODIRECTCOLOR", "1", 1); - else setenv("SDL_VIDEO_X11_NODIRECTCOLOR", "0", 1); + setenv("SDL_VIDEO_X11_NODIRECTCOLOR", sdl_forcexv ? "1" : "0", 1); /* does the user want to disable Xv and use software scaling instead */ - if(sdl_hwaccel) setenv("SDL_VIDEO_YUV_HWACCEL", "1", 1); - else setenv("SDL_VIDEO_YUV_HWACCEL", "0", 1); + setenv("SDL_VIDEO_YUV_HWACCEL", sdl_hwaccel ? "1" : "0", 1); /* default to no fullscreen mode, we'll set this as soon we have the avail. modes */ priv->fullmode = -2;