Mesa (master): mesa: fix remaining xfb prims check for GLES with multiple instances

Nicolai Hähnle nh at kemper.freedesktop.org
Wed Apr 19 06:11:44 UTC 2017


Module: Mesa
Branch: master
Commit: ea9a8940cadb30ac8d72a26b82bdb54872c0e199
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=ea9a8940cadb30ac8d72a26b82bdb54872c0e199

Author: Nicolai Hähnle <nicolai.haehnle at amd.com>
Date:   Thu Apr 13 20:53:17 2017 +0200

mesa: fix remaining xfb prims check for GLES with multiple instances

Found by inspection.

Cc: mesa-stable at lists.freedesktop.org
Reviewed-by: Timothy Arceri <tarceri at itsqueeze.com>
Reviewed-by: Marek Olšák <marek.olsak at amd.com>

---

 src/mesa/main/api_validate.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/mesa/main/api_validate.c b/src/mesa/main/api_validate.c
index af4f7cb4bf..8f834324ad 100644
--- a/src/mesa/main/api_validate.c
+++ b/src/mesa/main/api_validate.c
@@ -865,7 +865,7 @@ validate_draw_arrays(struct gl_context *ctx, const char *func,
    if (_mesa_is_gles3(ctx) && _mesa_is_xfb_active_and_unpaused(ctx) &&
        !_mesa_has_OES_geometry_shader(ctx) &&
        !_mesa_has_OES_tessellation_shader(ctx)) {
-      size_t prim_count = vbo_count_tessellated_primitives(mode, count, 1);
+      size_t prim_count = vbo_count_tessellated_primitives(mode, count, numInstances);
       if (xfb_obj->GlesRemainingPrims < prim_count) {
          _mesa_error(ctx, GL_INVALID_OPERATION,
                      "%s(exceeds transform feedback size)", func);




More information about the mesa-commit mailing list