move intelScreenContext() to intel_swapbuffers.c and make static
authorBrian <brian.paul@tungstengraphics.com>
Fri, 2 Nov 2007 19:10:31 +0000 (13:10 -0600)
committerBrian <brian.paul@tungstengraphics.com>
Mon, 5 Nov 2007 15:04:47 +0000 (08:04 -0700)
src/mesa/drivers/dri/intel_winsys/intel_context.c
src/mesa/drivers/dri/intel_winsys/intel_screen.h
src/mesa/drivers/dri/intel_winsys/intel_swapbuffers.c

index dd646a432a5cec6fbd3238a3930a04dd08edfd5a..f0e654c0bedcac6fda006bb4509a80abbed5b0d9 100644 (file)
@@ -256,27 +256,3 @@ intelMakeCurrent(__DRIcontextPrivate * driContextPriv,
 
    return GL_TRUE;
 }
-
-
-struct intel_context *intelScreenContext(intelScreenPrivate *intelScreen)
-{
-  /*
-   * This should probably change to have the screen allocate a dummy
-   * context at screen creation. For now just use the current context.
-   */
-
-  GET_CURRENT_CONTEXT(ctx);
-  if (ctx == NULL) {
-     /* need a context for the first time makecurrent is called (for hw lock
-        when allocating priv buffers) */
-     if (intelScreen->dummyctxptr == NULL) {
-        _mesa_problem(NULL, "No current context in intelScreenContext\n");
-        return NULL;
-     }
-     return intelScreen->dummyctxptr;
-  }
-
-  return intel_context(ctx);
-}
-
index 549587a6f2b7462a99bc172e48b552c9fbcf862f..12a52062002c626f9c71dbe6a2b67dc36999f83f 100644 (file)
@@ -97,8 +97,6 @@ extern struct _DriBufferPool *driBatchPoolInit(int fd, unsigned flags,
                                                unsigned numBufs,
                                                unsigned checkDelayed);
 
-extern struct intel_context *intelScreenContext(intelScreenPrivate *intelScreen);
-
 extern GLboolean
 intelCreatePools(intelScreenPrivate *intelScreen);
 
index f6e7e16000f45de930c5a7ac675b800c2f837335..a80b5a4198a8df27fb031d83dc10441e0d9da6ad 100644 (file)
 #include "state_tracker/st_cb_fbo.h"
 
 
+static struct intel_context *
+intelScreenContext(intelScreenPrivate *intelScreen)
+{
+  /*
+   * This should probably change to have the screen allocate a dummy
+   * context at screen creation. For now just use the current context.
+   */
+
+  GET_CURRENT_CONTEXT(ctx);
+  if (ctx == NULL) {
+     /* need a context for the first time makecurrent is called (for hw lock
+        when allocating priv buffers) */
+     if (intelScreen->dummyctxptr == NULL) {
+        _mesa_problem(NULL, "No current context in intelScreenContext\n");
+        return NULL;
+     }
+     return intelScreen->dummyctxptr;
+  }
+
+  return intel_context(ctx);
+}
+
 
 /**
  * Return the pipe_surface for the given renderbuffer.