summaryrefslogtreecommitdiffstats
path: root/src/gallium/targets/libgl-xlib/xlib.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/gallium/targets/libgl-xlib/xlib.c')
-rw-r--r--src/gallium/targets/libgl-xlib/xlib.c21
1 files changed, 13 insertions, 8 deletions
diff --git a/src/gallium/targets/libgl-xlib/xlib.c b/src/gallium/targets/libgl-xlib/xlib.c
index 69b4ddd33f7..2f8cd2d404a 100644
--- a/src/gallium/targets/libgl-xlib/xlib.c
+++ b/src/gallium/targets/libgl-xlib/xlib.c
@@ -36,16 +36,9 @@
#include "state_tracker/xlib_sw_winsys.h"
#include "xm_public.h"
+#include "state_tracker/st_api.h"
#include "state_tracker/st_gl_api.h"
-/* piggy back on this libGL for OpenGL support in EGL */
-struct st_api *
-st_api_create_OpenGL()
-{
- return st_gl_api_create();
-}
-
-
/* Helper function to choose and instantiate one of the software rasterizers:
* cell, llvmpipe, softpipe.
*
@@ -77,6 +70,10 @@ st_api_create_OpenGL()
#include "cell/ppu/cell_public.h"
#endif
+#ifdef GALLIUM_GALAHAD
+#include "galahad/glhd_public.h"
+#endif
+
static struct pipe_screen *
swrast_create_screen(struct sw_winsys *winsys)
{
@@ -111,6 +108,14 @@ swrast_create_screen(struct sw_winsys *winsys)
screen = softpipe_create_screen( winsys );
#endif
+#if defined(GALLIUM_GALAHAD)
+ if (screen) {
+ struct pipe_screen *galahad_screen = galahad_screen_create(screen);
+ if (galahad_screen)
+ screen = galahad_screen;
+ }
+#endif
+
return screen;
}