summaryrefslogtreecommitdiffstats
path: root/src/mesa/main/get.c
diff options
context:
space:
mode:
authorNeil Roberts <neil@linux.intel.com>2016-02-04 16:12:04 +0000
committerNeil Roberts <neil@linux.intel.com>2016-02-05 11:04:44 +0000
commitd8d4661ddb2ecef33721fbca2a9bb7bd1d84b7cf (patch)
tree3b5f1aac3962ce1f871cdf694e61a446241cfd8a /src/mesa/main/get.c
parent2065e380b2edafd6e38aa5bb0ff222dc1f6f5ad8 (diff)
downloadexternal_mesa3d-d8d4661ddb2ecef33721fbca2a9bb7bd1d84b7cf.zip
external_mesa3d-d8d4661ddb2ecef33721fbca2a9bb7bd1d84b7cf.tar.gz
external_mesa3d-d8d4661ddb2ecef33721fbca2a9bb7bd1d84b7cf.tar.bz2
main: Use _mesa_geometric_samples to calculate the value of GL_SAMPLES
Otherwise it won't take into account the default samples for framebuffers with no attachments. Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu>
Diffstat (limited to 'src/mesa/main/get.c')
-rw-r--r--src/mesa/main/get.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/mesa/main/get.c b/src/mesa/main/get.c
index f78a98b..73aa8c5 100644
--- a/src/mesa/main/get.c
+++ b/src/mesa/main/get.c
@@ -1085,6 +1085,10 @@ find_custom_value(struct gl_context *ctx, const struct value_desc *d, union valu
case GL_DISPATCH_INDIRECT_BUFFER_BINDING:
v->value_int = ctx->DispatchIndirectBuffer->Name;
break;
+ /* GL_ARB_multisample */
+ case GL_SAMPLES:
+ v->value_int = _mesa_geometric_samples(ctx->DrawBuffer);
+ break;
}
}