getting ready to have the camera poses plotted using spheres. auto-copy pthreadVC3d.dll and poses.csv to output directory
This commit is contained in:
@@ -31,9 +31,10 @@ void process_input() {
|
||||
}
|
||||
|
||||
static uint shader;
|
||||
void create_new_sphere(body* b) {
|
||||
void create_new_sphere(body* b, float scale=1) {
|
||||
assert(load_body(b, "Icosphere.obj"));
|
||||
b->shader = shader;
|
||||
b->scale = scale;
|
||||
b->pose = glm::translate(b->pose, glm::vec3(0, 0, 0));
|
||||
}
|
||||
|
||||
@@ -96,6 +97,7 @@ static void cursor_position_callback(GLFWwindow* window, double xpos, double ypo
|
||||
float dy = (ypos - prev_cursor_y);
|
||||
|
||||
glm::mat4 camera_to_world = glm::inverse(world_to_camera);
|
||||
// These could be acquired via some cross products. Don't know if that's more efficient.
|
||||
glm::vec4 strafe_x = camera_to_world[0];
|
||||
glm::vec4 strafe_y = camera_to_world[1];
|
||||
prev_cursor_x = xpos;
|
||||
|
||||
Reference in New Issue
Block a user