Skip to main content
Added info.
Source Link
akaltar
  • 1.7k
  • 14
  • 26

The simplest solution to this would be simply buffering the vertices into a VBO like you normally do, then rendering them as GL_POINTSGL_POINTS instead of GL_TRIANGLES or GL_TRIANGLE_STRIP.

This will give you a cloud of dots, that you can rotate the usual way with your vertex shader.

If you want nicely sized circles, you should use a geometry shader to create a camera-facing impostor/billboard from each vertex and process those using a fragment shader, you could event texture these.

While technically you could do the same with the built-in GL_POINTS approach, it is not supported properly by drivers in my experience, so you have to resort to your own geometry shader.

The simplest solution to this would be simply buffering the vertices into a VBO like you normally do, then rendering them as GL_POINTS.

This will give you a cloud of dots, that you can rotate the usual way with your vertex shader.

If you want nicely sized circles, you should use a geometry shader to create a camera-facing impostor/billboard from each vertex and process those using a fragment shader.

The simplest solution to this would be simply buffering the vertices into a VBO like you normally do, then rendering them as GL_POINTS instead of GL_TRIANGLES or GL_TRIANGLE_STRIP.

This will give you a cloud of dots, that you can rotate the usual way with your vertex shader.

If you want nicely sized circles, you should use a geometry shader to create a camera-facing impostor/billboard from each vertex and process those using a fragment shader, you could event texture these.

While technically you could do the same with the built-in GL_POINTS approach, it is not supported properly by drivers in my experience, so you have to resort to your own geometry shader.

Source Link
akaltar
  • 1.7k
  • 14
  • 26

The simplest solution to this would be simply buffering the vertices into a VBO like you normally do, then rendering them as GL_POINTS.

This will give you a cloud of dots, that you can rotate the usual way with your vertex shader.

If you want nicely sized circles, you should use a geometry shader to create a camera-facing impostor/billboard from each vertex and process those using a fragment shader.