PDA

View Full Version : OpenGL rotate circle from its position



jamesK
12-20-2016, 11:42 AM
Hi,

I am trying to rotate a circle from its center.
This makes the circle rotate in a circle. How do i make it turn just from the position it is instead of turning in a big circle?


glRotatef(spin, 0.0f, 0.0f, 1.0f);

Dark Photon
12-20-2016, 04:54 PM
Envision a table spinning slowly about its center. Now imagine laying a tire on top of that table. Where would you have to put the tire to generate the motion you're seeing. Now, where would you need to move the tire to generate the motion you're looking for.