summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRyan C. Gordon <icculus@icculus.org>2007-02-20 21:05:12 +0000
committerRyan C. Gordon <icculus@icculus.org>2007-02-20 21:05:12 +0000
commit5a1673792630530f97cf5ed0c04e761a8a7949f6 (patch)
tree535e61faff1f63951271da487108f84aee3a9a13
parentbd9852e0da5fd75e9273030ef5efb61679adc752 (diff)
downloadsdl-5a1673792630530f97cf5ed0c04e761a8a7949f6.tar.gz
Need to set DLSCL_ADMINISTRATIVE coop level in directfb driver, or YUV overlay
creation will fail in newer DirectFB versions. Fixes Bugzilla #394.
-rw-r--r--src/video/directfb/SDL_DirectFB_yuv.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/video/directfb/SDL_DirectFB_yuv.c b/src/video/directfb/SDL_DirectFB_yuv.c
index 583b8274e..ad0910e98 100644
--- a/src/video/directfb/SDL_DirectFB_yuv.c
+++ b/src/video/directfb/SDL_DirectFB_yuv.c
@@ -118,6 +118,15 @@ static DFBResult CreateYUVSurface(_THIS, struct private_yuvhwdata *hwdata,
break;
}
+ /* Need to set coop level or newer DirectFB versions will fail here. */
+ ret = layer->SetCooperativeLevel (layer, DLSCL_ADMINISTRATIVE);
+ if (ret)
+ {
+ SetDirectFBError("IDirectFBDisplayLayer::SetCooperativeLevel() failed", ret);
+ layer->Release (layer);
+ return ret;
+ }
+
ret = layer->SetConfiguration (layer, &conf);
if (ret)
{