any hints on making a GUI dial to rotate an object 360 degrees

hey,
heading probably says it.
I would appreciate any input on how to make a dial (like this: http://www.dokisoft.com/wp-content/uploads/2012/10/11c-dial-2.jpg)
The idea is to map degrees with the object’s, and making the obj rotate around its y-axis.
Im thinking a circular ‘slider’ or so, but how to make that?

I am using fingergestures btw, but that might be irrelevant,

any input is much appreciated!:slight_smile:
best,

I would use radial coordinates.

That is, I would convert the X, Y you get from your input system to degrees.

Of course, only if the click happened inside of the circle.

That seems like a good idea!
do you mean like if the user clicks in whatever x,y area it would correspond to a radial degree?

Have a look at the figure:
for instance by using a lot of small 3d objects and raycasting:
e.g. the user clicks on any of those divisions of a circle (the figure is for illustrative purposes only), so the object touched would message the object to rotate lets say 45degrees etc. the more divisions of the circle the more degrees to rotate. (max 360 objects of course)

does this even make sense? :slight_smile:

1282011--57905--$dial.JPG

What I meant is: when the user touches inside of the circle, take this point as and save it as a starting angle.

Whenever the user moves a finger, calculate the new angle based on the current point.

Subtract the two angles and you will get the wheel offset from the starting angle.