diff src/video/directfb/SDL_DirectFB_yuv.c @ 3920:e5a65c16913b SDL-1.2

Need to set DLSCL_ADMINISTRATIVE coop level in directfb driver, or YUV overlay creation will fail in newer DirectFB versions. Fixes Bugzilla #394.
author Ryan C. Gordon <icculus@icculus.org>
date Tue, 20 Feb 2007 21:05:12 +0000
parents 23fe15f88c03
children a8a548394a81
line wrap: on
line diff
--- a/src/video/directfb/SDL_DirectFB_yuv.c	Fri Feb 16 04:56:17 2007 +0000
+++ b/src/video/directfb/SDL_DirectFB_yuv.c	Tue Feb 20 21:05:12 2007 +0000
@@ -118,6 +118,15 @@
       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)
     {