Mesa (master): st/mesa: Increase GL_POINT_SIZE_RANGE minimum to 1.0
GitLab Mirror
gitlab-mirror at kemper.freedesktop.org
Mon Sep 16 21:05:18 UTC 2019
Module: Mesa
Branch: master
Commit: d9d6305b80b957ec80b2eb6ccffeab84f6766f19
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=d9d6305b80b957ec80b2eb6ccffeab84f6766f19
Author: Kenneth Graunke <kenneth at whitecape.org>
Date: Thu Sep 12 19:12:10 2019 -0700
st/mesa: Increase GL_POINT_SIZE_RANGE minimum to 1.0
Table 23.54 of the OpenGL 4.5 spec lists the minimum values for
GL_POINT_SIZE_RANGE as [1, 1]. So zero is not allowed (even though
arguably this could be useful for MSAA rendering, where a sub-1px
point might cover only some samples...)
This fixes the WebGL 2.0 conformance suite's state.gl-get-calls test
on Chromium on Linux, which uses desktop OpenGL. The test checks that
the minimum value of GL_ALIASED_POINT_SIZE_RANGE is 1. Unfortunately,
that query doesn't exist in desktop GL, so it checks POINT_SIZE_RANGE,
which is the anti-aliased value. There's not really anything better
for Chromium to do here, unfortunately. When running Chromium with
--api=es3, it maps it to the correct query and the test already works.
Reviewed-by: Jordan Justen <jordan.l.justen at intel.com>
Reviewed-by: Eric Anholt <eric at anholt.net>
---
src/mesa/state_tracker/st_extensions.c | 5 +----
1 file changed, 1 insertion(+), 4 deletions(-)
diff --git a/src/mesa/state_tracker/st_extensions.c b/src/mesa/state_tracker/st_extensions.c
index ed81134f4c5..40e51f828de 100644
--- a/src/mesa/state_tracker/st_extensions.c
+++ b/src/mesa/state_tracker/st_extensions.c
@@ -132,11 +132,8 @@ void st_init_limits(struct pipe_screen *screen,
c->MaxPointSizeAA =
_maxf(1.0f, screen->get_paramf(screen, PIPE_CAPF_MAX_POINT_WIDTH_AA));
- /* these are not queryable. Note that GL basically mandates a 1.0 minimum
- * for non-aa sizes, but we can go down to 0.0 for aa points.
- */
c->MinPointSize = 1.0f;
- c->MinPointSizeAA = 0.0f;
+ c->MinPointSizeAA = 1.0f;
c->MaxTextureMaxAnisotropy =
_maxf(2.0f,
More information about the mesa-commit
mailing list