Guest User

Untitled

a guest
Apr 19th, 2018
79
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.25 KB | None | 0 0
  1. void Camera::motion(int x,int y){
  2. theta+= x / 200; /* Adjust this to control the sensitivity */
  3. phi+= y / 200;
  4.  
  5. target.x = cos(theta) * sin(phi);
  6. target.y = cos(phi);
  7. target.z = sin(theta) * sin(phi);
  8. }
Add Comment
Please, Sign In to add comment