STATE_camera_move_toward_point_2D

 

 



   x,y are points on the window
   usually we get this point from events like OnLButtonDown()
   The function moves the camera towards the point (or far from the point depending 
   on the given value, factor).
   Note that the direction of the camera doesn't change. (Use STATE_camera_point_at() to make the target point at the center)
   returns OK, VR_ERRORR.
   factor can be any number. Here are some examples:
   factor== -2 , the camera will triple its distance from the given point
   factor== -1 , the camera will double its distance from the given point
   factor==0 means, the camera wont move
   factor==0.5 the camera will move half way to the point
   factor==1 the camera will move to the given point x,y
   factor==2 the camera will pass the point (will be in the same distance but on the other side of the line that connects the point and the line).

 

 

Go to page 1      Select API

 

Copyright © 2007 3DSTATE Corporation. www.3dstate.com