aboutsummaryrefslogtreecommitdiffstats
path: root/src/mesa/drivers/x11/xm_api.c
diff options
context:
space:
mode:
authorGeorge Sapountzis <[email protected]>2007-04-20 18:25:42 +0300
committerGeorge Sapountzis <[email protected]>2007-04-20 21:08:57 +0300
commit6346a753c6e77373cffcec6dd0df253efd159dd4 (patch)
tree674f37569f45501ee8eb4a181ca5f1cf0c0b99b7 /src/mesa/drivers/x11/xm_api.c
parent4d944b502f8a1ae372d9248e888612bffb5eb6a5 (diff)
xmesa: split FX functions to separate file, part 2.
Diffstat (limited to 'src/mesa/drivers/x11/xm_api.c')
-rw-r--r--src/mesa/drivers/x11/xm_api.c21
1 files changed, 8 insertions, 13 deletions
diff --git a/src/mesa/drivers/x11/xm_api.c b/src/mesa/drivers/x11/xm_api.c
index 692eb5f8078..5e2327a2d3b 100644
--- a/src/mesa/drivers/x11/xm_api.c
+++ b/src/mesa/drivers/x11/xm_api.c
@@ -1557,12 +1557,11 @@ PUBLIC
void XMesaDestroyContext( XMesaContext c )
{
GLcontext *mesaCtx = &c->mesa;
-#ifdef FX
- XMesaBuffer xmbuf = XMESA_BUFFER(mesaCtx->DrawBuffer);
- if (xmbuf && xmbuf->FXctx)
- fxMesaDestroyContext(xmbuf->FXctx);
+#ifdef FX
+ FXdestroyContext( XMESA_BUFFER(mesaCtx->DrawBuffer) );
#endif
+
_swsetup_DestroyContext( mesaCtx );
_swrast_DestroyContext( mesaCtx );
_tnl_DestroyContext( mesaCtx );
@@ -1767,15 +1766,6 @@ GLboolean XMesaMakeCurrent2( XMesaContext c, XMesaBuffer drawBuffer,
if (!drawBuffer || !readBuffer)
return GL_FALSE; /* must specify buffers! */
-#ifdef FX
- if (drawBuffer->FXctx) {
- fxMesaMakeCurrent(drawBuffer->FXctx);
-
- c->xm_buffer = drawBuffer;
-
- return GL_TRUE;
- }
-#endif
if (&(c->mesa) == _mesa_get_current_context()
&& c->mesa.DrawBuffer == &drawBuffer->mesa_buffer
&& c->mesa.ReadBuffer == &readBuffer->mesa_buffer
@@ -1786,6 +1776,11 @@ GLboolean XMesaMakeCurrent2( XMesaContext c, XMesaBuffer drawBuffer,
c->xm_buffer = drawBuffer;
+#ifdef FX
+ if (FXmakeCurrent( drawBuffer ))
+ return GL_TRUE;
+#endif
+
/* Call this periodically to detect when the user has begun using
* GL rendering from multiple threads.
*/