Skip to main content
gamedev.net
🔒 Locked

ArcBalls

Started by z9u2K Dec 7, 2001 at 7:43 AM 0 replies 600+ views
Original Post
z9u2K
z9u2K
Hey, I''m having trouble creating an arcball class... I need it to have: * a vector that has the position of the object in space, and the center of the camera (the same point). * a float which defines the radius of the arcball... I''ve looked into the DirectX SDK''s ArcBall class but there the arcball creates a world matrix, not a view matrix, I need it to generate a view atrix without effecting the object''s transform... Another thing, I need it to be able to translate the center of the object relative to the current view, let''s say, when the user drags the right mouse button, he will move the entire arcball...
Fruny
Fruny
GLUI has an arcball class. The source code is available at http://www.cs.unc.edu/~rademach/glui/. It is as good as any example we could give you.
"Debugging is twice as hard as writing the code in the first place. Therefore, if you write the code as cleverly as possible, you are, by definition, not smart enough to debug it." — Brian W. Kernighan

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.