|
static int | create_glut_perspective_camera_submenu (void(*icamera_submenu_callback)(int i), kjb::Perspective_camera *pc, bool enable_translation=true, bool enable_pitch=true, bool enable_yaw=true, bool enable_roll=true, bool enable_focal_length=true, bool enable_principal_point=true, bool enable_skew=true, bool enable_aspect_ratio=true, bool enable_world_scale=true, bool enable_clipping=true, bool enable_viewport=true, bool icentre_when_scaling_viewport=true, unsigned char iincrement_char=GLUT_PC_INCREMENT_CHARACTER, unsigned char idecrement_char=GLUT_PC_DECREMENT_CHARACTER) |
|
static void | camera_submenu_glut (int i) |
| This callback will be executed any time an entry of the camera submenu is selected. This is automatically called. Within this function the user defined callback will be called. More...
|
|
static void | keyboard_callback (unsigned char key) |
| This is the keyboard_callback for this camera submenu. The user HAS to call this in the GLUT keyboard callback when appropriate. More...
|
|
static void | enable_camera () |
| Enables the camera. When the camera is not enabled all submenu selections and the submenu keyboard callback have no effect. More...
|
|
static void | disable_camera () |
| Disable the camera. When the camera is not enabled all submenu selections and the submenu keyboard callback have no effect. More...
|
|
static double | retrieve_translation_x_increment () |
| returns the increment step used for the x-coordinate of the camera centre More...
|
|
static double | retrieve_translation_y_increment () |
| returns the increment step used for the y-coordinate of the camera centre More...
|
|
static double | retrieve_translation_z_increment () |
| returns the increment step used for the z-coordinate of the camera centre More...
|
|
static double | retrieve_pitch_increment () |
| returns the increment step used for the pitch More...
|
|
static double | retrieve_yaw_increment () |
| returns the increment step used for the yaw More...
|
|
static double | retrieve_roll_increment () |
| returns the increment step used for the roll More...
|
|
static double | retrieve_focal_length_increment () |
| returns the increment step used for the focal length More...
|
|
static double | retrieve_principal_point_x_increment () |
| returns the increment step used for the x coordinate of the principal point More...
|
|
static double | retrieve_principal_point_y_increment () |
| returns the increment step used for the y coordinate of the principal point More...
|
|
static double | retrieve_skew_increment () |
| returns the increment step used for the skew More...
|
|
static double | retrieve_aspect_ratio_increment () |
| returns the increment step used for the aspect ratio More...
|
|
static double | retrieve_world_scale_increment () |
| returns the increment step used for the world scale More...
|
|
static double | retrieve_near_clipping_increment () |
| returns the increment step used for the near clipping plane More...
|
|
static double | retrieve_far_clipping_increment () |
| returns the increment step used for the far clipping plane More...
|
|
static double | retrieve_width_increment () |
| returns the increment step used for the viewport width More...
|
|
static double | retrieve_height_increment () |
| returns the increment step used for the viewport height More...
|
|
static void | update_translation_x_increment (double iincrement) |
| sets the increment step used for the x-coordinate of the camera centre More...
|
|
static void | update_translation_y_increment (double iincrement) |
| sets the increment step used for the y-coordinate of the camera centre More...
|
|
static void | update_translation_z_increment (double iincrement) |
| sets the increment step used for the z-coordinate of the camera centre More...
|
|
static void | update_pitch_increment (double iincrement) |
| sets the increment step used for the pitch More...
|
|
static void | update_yaw_increment (double iincrement) |
| sets the increment step used for the yaw More...
|
|
static void | update_roll_increment (double iincrement) |
| sets the increment step used for the roll More...
|
|
static void | update_focal_length_increment (double iincrement) |
| sets the increment step used for the focal length More...
|
|
static void | update_principal_point_x_increment (double iincrement) |
| sets the increment step used for the x coordinate of the principal point More...
|
|
static void | update_principal_point_y_increment (double iincrement) |
| sets the increment step used for the y coordinate of the principal point More...
|
|
static void | update_skew_increment (double iincrement) |
| sets the increment step used for the skew More...
|
|
static void | update_aspect_ratio_increment (double iincrement) |
| sets the increment step used for the aspect ratio More...
|
|
static void | update_world_scale_increment (double iincrement) |
| sets the increment step used for the world scale More...
|
|
static void | update_near_clipping_increment (double iincrement) |
| sets the increment step used for the near clipping plane More...
|
|
static void | update_far_clipping_increment (double iincrement) |
| sets the increment step used for the far clipping plane More...
|
|
static void | update_width_increment (double iincrement) |
| sets the increment step used for the viewport width More...
|
|
static void | update_height_increment (double iincrement) |
| sets the increment step used for the viewport height More...
|
|
provides an easy way to add a glut submenu that handles a full perspective camera to your application. This class only creates the menu, it's up to the user to add it to the main glut menu. Upon creation of the submenu, the user has to provide a callback (camera_submenu_callback) that will be called every time one entry in the camera submenu will be selected. Optionally, an empty callback can be passed, if the user does not need to take any further action. It is also up to the user to call the keyboard_callback provided in this class the glut keyboard callback when appropriate. This class provides a submenu entry for each parameter of the camera. Upon selection, the keys 'j' and 'k' allow the user to increment or decrement the value of each parameter by the increment_step for that parameter. Each increment_step can be specified by the user. The user can also decide to use different characters (ie characters other than 'j' and 'k').