On Tue, Jun 27, 2017 at 3:18 PM, Ian Romanick <i...@freedesktop.org> wrote: > On 06/27/2017 11:23 AM, Ilia Mirkin wrote: >> On Tue, Jun 27, 2017 at 1:09 PM, Ian Romanick <i...@freedesktop.org> wrote: >>> From: Ian Romanick <ian.d.roman...@intel.com> >>> >>> On NV20 (and probably also on earlier NV GPUs that lack >>> GL_ARB_texture_border_clamp) fixes the following piglit tests: >>> >>> gl-1.0-beginend-coverage gltexparameter[if]{v,} >>> push-pop-texture-state >>> texwrap 1d >>> texwrap 1d proj >>> texwrap 2d proj >>> texwrap formats >>> >>> All told, 49 more tests pass on NV20 (10de:0201). >>> >>> No changes on Intel CI run or RV250 (1002:4c66). >>> >>> Signed-off-by: Ian Romanick <ian.d.roman...@intel.com> >> >> Contrary to my recollections, you appear to be quite right - >> TEXTURE_BORDER_COLOR has always been there in [desktop] GL. I always >> associated it with ARB_texture_border_clamp. > > Yeah... it's needed for GL_CLAMP. All the piglit tests that use > GL_CLAMP were failing on NV20 because they got a GL error. :) > >> Reviewed-by: Ilia Mirkin <imir...@alum.mit.edu> > > For the series or just this patch?
Just for this patch. Thinking about 2/3, and it's probably unfair for me to review 3/3 :) > >>> --- >>> src/mesa/main/texparam.c | 10 +++++++++- >>> 1 file changed, 9 insertions(+), 1 deletion(-) >>> >>> diff --git a/src/mesa/main/texparam.c b/src/mesa/main/texparam.c >>> index 3c110de..857faf6 100644 >>> --- a/src/mesa/main/texparam.c >>> +++ b/src/mesa/main/texparam.c >>> @@ -736,8 +736,16 @@ set_tex_parameterf(struct gl_context *ctx, >>> break; >>> >>> case GL_TEXTURE_BORDER_COLOR: >>> + /* Border color exists in desktop OpenGL since 1.0 for GL_CLAMP. In >>> + * OpenGL ES 2.0+, it only exists in when >>> GL_OES_texture_border_clamp is >>> + * enabled. It is never available in OpenGL ES 1.x. >>> + * >>> + * FIXME: Every driver that supports GLES2 has this extension. Elide >>> + * the check? >>> + */ >>> if (ctx->API == API_OPENGLES || >>> - !ctx->Extensions.ARB_texture_border_clamp) >>> + (ctx->API == API_OPENGLES2 && >>> + !ctx->Extensions.ARB_texture_border_clamp)) >>> goto invalid_pname; >>> >>> if (!_mesa_target_allows_setting_sampler_parameters(texObj->Target)) >>> -- >>> 2.9.4 >>> >>> _______________________________________________ >>> mesa-dev mailing list >>> mesa-dev@lists.freedesktop.org >>> https://lists.freedesktop.org/mailman/listinfo/mesa-dev >> > _______________________________________________ mesa-dev mailing list mesa-dev@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/mesa-dev