encircle any point on the screen

Started by
0 comments, last by saman_artorious 10 years, 8 months ago

How can I draw a circle surround any given point on the screen? Normally, OpenGL draws the circle centered at (0,0). My position indicator consists of pixels rendered as rectangles. The number of pixels is a multiplication of angle and range given to me. For example, if ppi shall be drawn for 360 degree and range 1000, then I draw 360 * 1000 pixels on the screen. Accordingly, any point is detected with its relevant angle and range. Let's say a point exists at 50 degree and range 500. How can I encircle that point now?

Advertisement

I solved the problem. I calculated the central coordinate of the target circle and added it to the original drawing which is rendered at (0,0).

This topic is closed to new replies.

Advertisement