Search Unity

Bug Issues with GL.LINE_STRIP and large number of lines

Discussion in 'General Graphics' started by xJackaL, Jul 22, 2021.

  1. xJackaL

    xJackaL

    Joined:
    Jul 22, 2021
    Posts:
    2
    I hope I'm not overstepping in calling this an engine bug, but today I have encountered some really weird behaviour of GL.LINE_STRIP when rendering a large amount of lines. In short, every 768 (exact value) vertices that are submitted, a line is skipped and leaves a gap in the strip.

    To make sure that the issue wasn't related to something else in my project, I have created a blank scene (which I'm attaching to this post) where a test circle is drawn using GL.LINE_STRIP with an adjustable number of points. You can see how a gap appears (on the right side of the circle) as soon as NumPoints >= 768 and a second gap when NumPoints >= 1536.

    I have checked both Unity's and DirectX/OpenGL own docs to see if they mention anything that might relate to this behaviour, but they don't. Also, this issue does not happen when using GL.LINES and passing each pair of vertices individually.

    I'm using Unity 2020.3.6f1 on Windows 10, my GPU is a Nvidia Quadro K5200 (driver version 391.25). I have verified that it happens with either DX11 and OpenGL 4.5 as graphics API, both in the Editor as well as in the built Player version.

    Looking forward to hear your thoughts on this, if I'm missing something or if it's indeed a bug in Unity's GL.
    Thanks.
     

    Attached Files:

    Last edited: Jul 23, 2021
  2. xJackaL

    xJackaL

    Joined:
    Jul 22, 2021
    Posts:
    2
    Anyone ?
     
  3. richardkettlewell

    richardkettlewell

    Unity Technologies

    Joined:
    Sep 9, 2015
    Posts:
    2,285
    If it’s as you describe it, I think it would be best to submit a bug report via Help/Report a Bug in the Editor, with a simple repro project.
     
    xJackaL likes this.