Reputation: 3284
So I am in need of a little nudge or push in the right direction. I am trying to set up a radial grid. On top of the radial grid will be spheres, the grid itself is for the observer to notice direction change and directional awareness. The concept is this grid, well allow users to navigate through a 'solar system' and be more aware of the three dimensional space.
(the grid will not be malliable, like space-time grids that show the warping due to mass of objects, the planets will like somewhat above the grid itself. In a sense, a static radial grid.)
Any Help is appreciated.
Upvotes: 1
Views: 933
Reputation: 52387
Just out of my head. If I would want to create a typical 2D grid, I would use two nested for loops to spawn the appropriate glQuads into a display list and then let it be drawn as wireframe (see How do you render primitives as wireframes in OpenGL?).
To change this into a radial grid, basically you loop over angle and magnitude instead of x,y. Then you use sin() or cos() functions to calculate x/y coordinates of your quad corners properly.
The drawback of this solution is that if your grid is not fine grained enough, the user may get distracted by the fact that the radial lines you're drawing aren't curves.
Hope this helps to get you further.
Upvotes: 1