Results 1 to 4 of 4

Thread: Limit of number of vertices in a polygon

  1. #1
    Junior Member Newbie
    Join Date
    Jul 2003
    Location
    Sao Jose dos Campos, SP Brasil
    Posts
    1

    Limit of number of vertices in a polygon

    Hi, all

    I'm having a problem with large numbers of vertices in a polygon. I'm trying to display the output from a scientific model and this model has some ellipse type surfaces that have more then a 1000 points in it. I create a call list and create the polygons. This runs fine, but when I call glCallList on this call list my application crashes. If I place a function in the code to skip every 2 vertices, this brings the number of vertices down around 350 and everything runs fine. Note, I have multiple polygons of this type in the call list. It does not seem to matter the overall size of the call list, just the size of the polygons within the list.

    Is there a maximum number of vertices that a polygon can contain? If so how can I query for this number? Can this number be increased?

    Thanks,

    Jeff Naus

  2. #2
    Senior Member OpenGL Guru Relic's Avatar
    Join Date
    Apr 2000
    Posts
    2,450

    Re: Limit of number of vertices in a polygon

    "Is there a maximum number of vertices that a polygon can contain?"

    No, sounds like a driver bug.
    Try updating the drivers and if that's not helping and you're sure everything else is correct on your side send a small reproducer to your graphics hardware vendor's developer relation group.

  3. #3
    Senior Member OpenGL Pro
    Join Date
    Feb 2002
    Location
    Bonn, Germany
    Posts
    1,633

    Re: Limit of number of vertices in a polygon

    Convex polygons can also be rendered as triangle fans. You can easily do that by just changing the glBegin token (GL_POLYGON => GL_TRIANGLE_FAN ; doesn't get any easier than this ).

  4. #4
    Senior Member OpenGL Guru Relic's Avatar
    Join Date
    Apr 2000
    Posts
    2,450

    Re: Limit of number of vertices in a polygon

    Careful, GL_TRIANGLE_FANs work differently with flat shading or glPolygonMode(GL_LINE).

Similar Threads

  1. Number of vertices
    By Warzywo in forum OpenGL: Advanced Coding
    Replies: 1
    Last Post: 09-24-2008, 04:22 AM
  2. VBO. Different number of Vertices and TexCoords
    By AMACIAS in forum OpenGL: Basic Coding
    Replies: 7
    Last Post: 05-13-2008, 01:57 PM
  3. Is there a limit in the number of display lists?
    By xanatose in forum OpenGL: Basic Coding
    Replies: 3
    Last Post: 01-13-2005, 11:15 AM
  4. Polygon count limit in OpenGL?
    By in forum OpenGL: Basic Coding
    Replies: 4
    Last Post: 11-22-2002, 10:57 AM
  5. meshes with same number of vertices
    By in forum OpenGL: Basic Coding
    Replies: 0
    Last Post: 07-27-2002, 12:05 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