Rube Goldberg Machine 1.0
This is the base code for Rube Goldberg designed for the CS296 Software Systems Lab
|
00001 /* 00002 * Base code for CS 296 Software Systems Lab 00003 * Department of Computer Science and Engineering, IIT Bombay 00004 * Instructor: Parag Chaudhuri 00005 */ 00006 00009 #ifndef _CALLBACKS_HPP_ 00010 #define _CALLBACKS_HPP_ 00011 00022 00023 00024 #include "render.hpp" 00025 #include "cs296_base.hpp" 00026 00027 namespace cs296 00028 { 00029 class callbacks_t 00030 { 00031 public: 00034 static b2Vec2 convert_screen_to_world(int32 x, int32 y); 00035 00039 static void resize_cb(int32 w, int32 h); 00040 00043 static void keyboard_cb(unsigned char key, int x, int y); 00044 00046 static void keyboard_special_cb(int key, int x, int y); 00047 00049 static void keyboard_up_cb(unsigned char key, int x, int y); 00050 00053 static void mouse_cb(int32 button, int32 state, int32 x, int32 y); 00054 00057 static void mouse_motion_cb(int32 x, int32 y); 00058 00061 static void timer_cb(int); 00062 00066 static void display_cb(void); 00067 00069 static void restart_cb(int); 00070 00072 static void pause_cb(int); 00073 00075 static void single_step_cb(int); 00076 00078 static void exit_cb(int code); 00079 }; 00080 }; 00081 00082 #endif