mesa: update derived framebuffer state in GetMultisamplefv
This makes sure that ctx->DrawBuffer->Visual.samples is up-to-date. Reviewed-by: Eric Anholt <eric@anholt.net>
This commit is contained in:
parent
b6475f9437
commit
4f1fd920c9
|
@ -30,6 +30,7 @@
|
|||
#include "main/mtypes.h"
|
||||
#include "main/fbobject.h"
|
||||
#include "main/glformats.h"
|
||||
#include "main/state.h"
|
||||
|
||||
|
||||
/**
|
||||
|
@ -73,6 +74,10 @@ _mesa_GetMultisamplefv(GLenum pname, GLuint index, GLfloat * val)
|
|||
{
|
||||
GET_CURRENT_CONTEXT(ctx);
|
||||
|
||||
if (ctx->NewState & _NEW_BUFFERS) {
|
||||
_mesa_update_state(ctx);
|
||||
}
|
||||
|
||||
switch (pname) {
|
||||
case GL_SAMPLE_POSITION: {
|
||||
if (index >= ctx->DrawBuffer->Visual.samples) {
|
||||
|
|
Loading…
Reference in New Issue