[Piglit] Testing for GL_ARB_draw_instanced

Eric Anholt eric at anholt.net
Tue Feb 28 13:32:34 PST 2012


Here's testing for almost everything else I came up with from the spec.
The weaknesses I'd note are:

* We don't test whether one of the required shader extensions or GL3
  is actually present.

* We don't test for the non-presence of variables if optional
  extensions are not present.

* We don't test very large instance counts.

* We don't test interaction with non-GL3 (EXT_gpu_shader4 or
  NV_vertex_program4).

* We don't test other implied behavior of text like:

   "The command

        void DrawElementsInstancedARB(enum mode, sizei count, enum type,
                const void *indices, sizei primcount);

    behaves identically to DrawElements except that <primcount>
    instances of the set of elements are executed, and the value of
    <instanceID> advances for each iteration.  It has the same effect
    as:

        if (mode, count, or type is invalid )
            generate appropriate error
        else {
            for (int i = 0; i < primcount; i++) {
                instanceID = i;
                DrawElements(mode, count, type, indices, i);
            }
            instanceID = 0;
        }"

  We test that basic instancing-related rendering works, and we test
  the explicitly mentioned error behavior for "type" in the spec, but
  for example checking whether count or mode are invalid is not done.



More information about the Piglit mailing list