View Full Version : High performance "line" drawing

10-15-2015, 03:01 PM
at the moment i develop an interface to watch big tree like structers. Therefore i need a fast method to draw arround >10.000 lines with Alphablending,Z-Buffer. Each line must be customizable in color, width and position at both endpoints. Additional it should be an axis billboard (current solution) or 3D model.

Currently i use a big vertexbuffer with "GL_LINES" and calculate the billboard vertices in the geometry shader:

//More or less 4 times:

fColor = vertex[0].vColor;
gl_Position = projectionView * (gl_in[0].gl_Position - Direction0);

When i draw the lines it correct blending order (from back to front) the fps drops to only 20-30. In inverse order (wrong for alpha) i get >300fps.
So its only GPU limited...

Any method to increase performance (in correct alpha-blending order) massive?