From b939adfa155f2b3ca5c5226e86da85629654d79b Mon Sep 17 00:00:00 2001 From: Keith Whitwell Date: Thu, 24 May 2007 10:44:53 +0100 Subject: Use the x11 driver as a test harness for the softpipe/state_tracker code. This has some limitations as we currently require a mapped framebuffer, so it only really works with double-buffered ximage rgba8888 windows. --- src/mesa/drivers/x11/xm_api.c | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'src/mesa/drivers/x11/xm_api.c') diff --git a/src/mesa/drivers/x11/xm_api.c b/src/mesa/drivers/x11/xm_api.c index a07d0a90cf..af1a169a76 100644 --- a/src/mesa/drivers/x11/xm_api.c +++ b/src/mesa/drivers/x11/xm_api.c @@ -80,6 +80,9 @@ #include "tnl/t_pipeline.h" #include "drivers/common/driverfuncs.h" +#include "softpipe/state_tracker/st_public.h" +#include "softpipe/generic/g_context.h" + /** * Global X driver lock */ @@ -1556,6 +1559,10 @@ XMesaContext XMesaCreateContext( XMesaVisual v, XMesaContext share_list ) xmesa_register_swrast_functions( mesaCtx ); _swsetup_Wakeup(mesaCtx); + + st_create_context( mesaCtx, + generic_create() ); + return c; } @@ -1758,6 +1765,8 @@ PUBLIC GLboolean XMesaMakeCurrent2( XMesaContext c, XMesaBuffer drawBuffer, XMesaBuffer readBuffer ) { + _mesa_printf("%s %p %p %p\n", __FUNCTION__, drawBuffer, readBuffer ); + if (c) { if (!drawBuffer || !readBuffer) return GL_FALSE; /* must specify buffers! */ -- cgit v1.2.3