Container class for the viewer, does not need to be weel written. More...
Public Member Functions | |
MC_navigator_tool () | |
MC_matrix | current_light1 () const |
MC_v3d_vector | axis_light1 () const |
MC_matrix | current_cam1 () const |
MC_v3d_vector | axis_cam1 () const |
void | go_forward_trackball_cam1 (const double &d_L) |
void | go_right_trackball_cam1 (const double &d_L) |
void | go_up_trackball_cam1 (const double &d_L) |
std::ostream & | write_cam1 (std::ostream &stream) const |
const MC_navigator_tool & | write_cam1_file (std::string &filename) const |
MC_navigator_tool & | read_cam1 (std::istream ¶m) |
MC_navigator_tool & | read_cam1_file (const std::string &filename) |
std::ostream & | write_light1 (std::ostream &stream) const |
const MC_navigator_tool & | write_light1_file (std::string &filename) const |
MC_navigator_tool & | read_light1 (std::istream ¶m) |
MC_navigator_tool & | read_light1_file (const std::string &filename) |
double | delta_time () |
return current_time-old_time; | |
double | update_fps () |
update the fps and return fps | |
int | increase_frame_number () |
increase the frame drawn and return the number | |
MC_double_vector | projection_param () const |
MC_matrix | projection_matrix () const |
MC_v3d_vector | ray_world_space_cam1 (const int &x_screen, const int &y_screen) const |
give the (x,y) coordinate in screen space and return the center and the ray pointed in world space | |
Public Attributes | |
MC_trackball | trackball_cam1 |
MC_v3d | tr_cam1 |
double | dist_cam1 |
MC_trackball | trackball_light1 |
MC_v3d | tr_light1 |
double | dist_light1 |
unsigned int | current_time |
unsigned int | old_time |
unsigned int | frame |
double | current_fps |
int | x_previous |
int | y_previous |
int | x_screen_size_1 |
int | y_screen_size_1 |
double | fov |
double | znear |
double | zfar |
double | size_pointer |
bool | left_button |
bool | right_button |
Container class for the viewer, does not need to be weel written.
mesh_conv::MC_navigator_tool::MC_navigator_tool | ( | ) |
References current_fps, current_time, dist_cam1, fov, frame, left_button, old_time, PI, right_button, size_pointer, x_previous, x_screen_size_1, y_previous, y_screen_size_1, zfar, and znear.
MC_v3d_vector mesh_conv::MC_navigator_tool::axis_cam1 | ( | ) | const |
References current_cam1(), and mesh_conv::MC_matrix::to_matrix3().
MC_v3d_vector mesh_conv::MC_navigator_tool::axis_light1 | ( | ) | const |
References current_light1(), and mesh_conv::MC_matrix::to_matrix3().
MC_matrix mesh_conv::MC_navigator_tool::current_cam1 | ( | ) | const |
References mesh_conv::MC_matrix::add_translation(), mesh_conv::MC_quaternion::conjugated(), dist_cam1, mesh_conv::MC_matrix::identity(), mesh_conv::MC_quaternion::matrix(), mesh_conv::MC_trackball::quaternion(), mesh_conv::MC_matrix::to_matrix3(), mesh_conv::MC_matrix::to_matrix4(), tr_cam1, and trackball_cam1.
Referenced by axis_cam1(), and ray_world_space_cam1().
MC_matrix mesh_conv::MC_navigator_tool::current_light1 | ( | ) | const |
References mesh_conv::MC_matrix::add_translation(), mesh_conv::MC_quaternion::conjugated(), dist_light1, mesh_conv::MC_matrix::identity(), mesh_conv::MC_quaternion::matrix(), mesh_conv::MC_trackball::quaternion(), mesh_conv::MC_matrix::to_matrix3(), mesh_conv::MC_matrix::to_matrix4(), tr_light1, and trackball_light1.
Referenced by axis_light1().
double mesh_conv::MC_navigator_tool::delta_time | ( | ) | [inline] |
return current_time-old_time;
References current_time, and old_time.
Referenced by display_callback().
void mesh_conv::MC_navigator_tool::go_forward_trackball_cam1 | ( | const double & | d_L | ) |
References mesh_conv::MC_quaternion::conjugated(), mesh_conv::MC_trackball::quaternion(), tr_cam1, and trackball_cam1.
Referenced by keyboard_callback().
void mesh_conv::MC_navigator_tool::go_right_trackball_cam1 | ( | const double & | d_L | ) |
References mesh_conv::MC_quaternion::conjugated(), mesh_conv::MC_trackball::quaternion(), tr_cam1, and trackball_cam1.
Referenced by keyboard_callback().
void mesh_conv::MC_navigator_tool::go_up_trackball_cam1 | ( | const double & | d_L | ) |
References mesh_conv::MC_quaternion::conjugated(), mesh_conv::MC_trackball::quaternion(), tr_cam1, and trackball_cam1.
Referenced by keyboard_callback().
int mesh_conv::MC_navigator_tool::increase_frame_number | ( | ) | [inline] |
MC_matrix mesh_conv::MC_navigator_tool::projection_matrix | ( | ) | const |
MC_double_vector mesh_conv::MC_navigator_tool::projection_param | ( | ) | const |
References fov, x_screen_size_1, y_screen_size_1, zfar, and znear.
Referenced by display_callback(), projection_matrix(), and ray_world_space_cam1().
MC_v3d_vector mesh_conv::MC_navigator_tool::ray_world_space_cam1 | ( | const int & | x_screen, | |
const int & | y_screen | |||
) | const |
give the (x,y) coordinate in screen space and return the center and the ray pointed in world space
References current_cam1(), mesh_conv::MC_matrix::inverted(), mesh_conv::MC_v3d::normalized(), projection_param(), mesh_conv::MC_matrix::to_matrix3(), mesh_conv::MC_matrix::translation_part(), x_screen_size_1, y_screen_size_1, and znear.
MC_navigator_tool & mesh_conv::MC_navigator_tool::read_cam1 | ( | std::istream & | param | ) |
References dist_cam1, mesh_conv::MC_trackball::quaternion(), tr_cam1, and trackball_cam1.
Referenced by read_cam1_file().
MC_navigator_tool & mesh_conv::MC_navigator_tool::read_cam1_file | ( | const std::string & | filename | ) |
MC_navigator_tool & mesh_conv::MC_navigator_tool::read_light1 | ( | std::istream & | param | ) |
References dist_light1, mesh_conv::MC_trackball::quaternion(), tr_light1, and trackball_light1.
Referenced by read_light1_file().
MC_navigator_tool & mesh_conv::MC_navigator_tool::read_light1_file | ( | const std::string & | filename | ) |
double mesh_conv::MC_navigator_tool::update_fps | ( | ) |
update the fps and return fps
References current_fps, current_time, frame, and old_time.
Referenced by display_callback().
std::ostream & mesh_conv::MC_navigator_tool::write_cam1 | ( | std::ostream & | stream | ) | const |
References dist_cam1, mesh_conv::MC_trackball::quaternion(), tr_cam1, and trackball_cam1.
Referenced by write_cam1_file().
const MC_navigator_tool & mesh_conv::MC_navigator_tool::write_cam1_file | ( | std::string & | filename | ) | const |
std::ostream & mesh_conv::MC_navigator_tool::write_light1 | ( | std::ostream & | stream | ) | const |
References dist_light1, mesh_conv::MC_trackball::quaternion(), tr_light1, and trackball_light1.
Referenced by write_light1_file().
const MC_navigator_tool & mesh_conv::MC_navigator_tool::write_light1_file | ( | std::string & | filename | ) | const |
Referenced by draw_fps(), MC_navigator_tool(), and update_fps().
unsigned int mesh_conv::MC_navigator_tool::current_time |
Referenced by delta_time(), display_callback(), MC_navigator_tool(), and update_fps().
Referenced by current_cam1(), display_callback(), draw_pointer(), keyboard_callback(), MC_navigator_tool(), motion_callback(), read_cam1(), and write_cam1().
Referenced by current_light1(), read_light1(), and write_light1().
Referenced by MC_navigator_tool(), and projection_param().
unsigned int mesh_conv::MC_navigator_tool::frame |
Referenced by increase_frame_number(), MC_navigator_tool(), and update_fps().
Referenced by MC_navigator_tool(), motion_callback(), and mouse_callback().
unsigned int mesh_conv::MC_navigator_tool::old_time |
Referenced by delta_time(), MC_navigator_tool(), and update_fps().
Referenced by MC_navigator_tool(), motion_callback(), and mouse_callback().
Referenced by MC_navigator_tool().
Referenced by current_light1(), read_light1(), and write_light1().
Referenced by current_light1(), read_light1(), and write_light1().
Referenced by MC_navigator_tool(), motion_callback(), and mouse_callback().
Referenced by display_callback(), main(), MC_navigator_tool(), motion_callback(), projection_param(), ray_world_space_cam1(), reshape_callback(), and setup_opengl().
Referenced by MC_navigator_tool(), motion_callback(), and mouse_callback().
Referenced by display_callback(), main(), MC_navigator_tool(), motion_callback(), projection_param(), ray_world_space_cam1(), reshape_callback(), and setup_opengl().
Referenced by MC_navigator_tool(), projection_matrix(), and projection_param().
Referenced by MC_navigator_tool(), projection_matrix(), projection_param(), and ray_world_space_cam1().