projects
/
mesa.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
e407fb1
)
mesa: move GET_CURRENT_CONTEXT() to top of _mesa_init_renderbuffer()
author
Brian Paul
<brianp@vmware.com>
Thu, 15 Jan 2015 22:30:40 +0000
(15:30 -0700)
committer
Brian Paul
<brianp@vmware.com>
Thu, 15 Jan 2015 23:15:34 +0000
(16:15 -0700)
To fix MSVC build.
Reviewed-by: Matt Turner <mattst88@gmail.com>
src/mesa/main/renderbuffer.c
patch
|
blob
|
history
diff --git
a/src/mesa/main/renderbuffer.c
b/src/mesa/main/renderbuffer.c
index cc97ab22bed931ecc34ca81fab3037b483d5a735..98f3c13b5574692856736db4e5935f65ca459d44 100644
(file)
--- a/
src/mesa/main/renderbuffer.c
+++ b/
src/mesa/main/renderbuffer.c
@@
-38,6
+38,8
@@
void
_mesa_init_renderbuffer(struct gl_renderbuffer *rb, GLuint name)
{
+ GET_CURRENT_CONTEXT(ctx);
+
mtx_init(&rb->Mutex, mtx_plain);
rb->ClassID = 0;
@@
-64,7
+66,6
@@
_mesa_init_renderbuffer(struct gl_renderbuffer *rb, GLuint name)
* specs. If the context is not current, we cannot determine the
* API, so default to GL_RGBA.
*/
- GET_CURRENT_CONTEXT(ctx);
if (ctx && _mesa_is_gles3(ctx)) {
rb->InternalFormat = GL_RGBA4;
} else {