Hi there,
I have been developing an application in OpenGL 4.x for some time, I master notions of VBO, VAO, MVP matrices and hierarchical models. I’m now running into a problem for which I’m picturing two possible solutions but I’m not sure they’re the right ones
I have a structure that contains coordinates of lines (n x two points) that are recalculated periodically
I simply have to draw lines between these points as it was possible if I understood correctly with the glBegin(GL_LINES) of the old OpenGL
I thought of these two solutions :

load the new coordinates into a VBO periodically in the render loop and draw lines. Is it good ? If so, what is the method to achieve this ?

Create in a VBO a normalized segment aligned for example on the abscissa then apply successive transformations (scale, rotate, translate, etc.) to position the segment where it should be. Is it good ? If so, concerning the rotations I think I will have gimbal lock problems ? What do you think ?

Other method ?
Many thanks in advance
Frank