mesa: use default geometry's samples when there are no attachments

Whether multisampling is turned on depends, in part, on whether
attachments are themselves multisample surfaces. However when there are
no attachments, we should rely on the default geometry for this.

Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
This commit is contained in:
Ilia Mirkin 2016-01-31 01:09:40 -05:00
parent 095da3b550
commit 18f688d62a

View file

@ -352,7 +352,7 @@ update_multisample(struct gl_context *ctx)
ctx->Multisample._Enabled = GL_FALSE;
if (ctx->Multisample.Enabled &&
ctx->DrawBuffer &&
ctx->DrawBuffer->Visual.sampleBuffers)
_mesa_geometric_samples(ctx->DrawBuffer) > 0)
ctx->Multisample._Enabled = GL_TRUE;
}