Results 1 to 2 of 2

Thread: vertex shader not running on all vertices

  1. #1
    Member Contributor
    Join Date
    Jul 2018

    vertex shader not running on all vertices


    I have a vertex shader that reads in a buffer of vertices (buffer bound to a vertex array).

    Code :
    /*enabling program goes here*/
    glDrawArraysInstanced(GL_POINTS, 0, numpoints, 1);
    /*disabling program code goes here*/

    However, the vertex shader only produces output for the first 2 vertices.
    I have checked the buffer bound to vertex array. It has the required 50 vertices that the vertex shader should run on.

    The program writes out to a buffer which is how i know what output i got. This output buffer has more than enough space, so I know that is not because my output buffer is short.

    Is there a way i can verify that the vertex shader ran on all the vertices? Could there be anything else wrong (hoping someone has experiences to share) that I am not testing?


  2. #2
    Member Contributor
    Join Date
    Jul 2018
    Note that the output buffer is sent in to the shader program by address , not by buffer object bending/name.

    Code :
    I don't think that this approach has anything to do with the vertices not being visited since at least two are written out.

Similar Threads

  1. Running a vertex shader without any per-vertex attribute
    By mobeen in forum OpenGL: Basic Coding
    Replies: 4
    Last Post: 03-11-2013, 06:12 AM
  2. how vertex shader operates on vertices?
    By SagoO in forum OpenGL: GLSL
    Replies: 9
    Last Post: 03-29-2011, 04:54 AM
  3. Only running a vertex shader
    By CastleBravo in forum OpenGL: GLSL
    Replies: 5
    Last Post: 03-13-2011, 03:37 AM
  4. discard vertices in vertex shader
    By Dylan in forum OpenGL: GLSL
    Replies: 5
    Last Post: 12-06-2006, 09:38 AM
  5. Change vertices using vertex shader
    By xboct in forum OpenGL: Advanced Coding
    Replies: 1
    Last Post: 10-27-2003, 12:35 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
Proudly hosted by Digital Ocean