invisible
diff src/kinect.cc @ 7:4f1b8ddcd32e
minor fixes
author | Eleni Maria Stea <eleni@mutantstargoat.com> |
---|---|
date | Sun, 03 Nov 2013 21:58:56 +0200 |
parents | 700127288dc5 |
children | 65fd6d7c42b1 |
line diff
1.1 --- a/src/kinect.cc Sun Nov 03 20:36:45 2013 +0200 1.2 +++ b/src/kinect.cc Sun Nov 03 21:58:56 2013 +0200 1.3 @@ -7,18 +7,18 @@ 1.4 1.5 KinectParams::KinectParams() 1.6 { 1.7 - angle = 10; 1.8 + angle = 10; 1.9 1.10 - video_width = KINECT_VIDEO_WIDTH; 1.11 - video_height = KINECT_VIDEO_HEIGHT; 1.12 - depth_width = KINECT_DEPTH_WIDTH; 1.13 - depth_height = KINECT_DEPTH_HEIGHT; 1.14 + video_width = KINECT_VIDEO_WIDTH; 1.15 + video_height = KINECT_VIDEO_HEIGHT; 1.16 + depth_width = KINECT_DEPTH_WIDTH; 1.17 + depth_height = KINECT_DEPTH_HEIGHT; 1.18 1.19 - led_color = LED_RED; 1.20 - video_format = FREENECT_VIDEO_RGB; 1.21 - depth_format = FREENECT_DEPTH_11BIT; 1.22 - video_res = FREENECT_RESOLUTION_MEDIUM; 1.23 - depth_res = FREENECT_RESOLUTION_MEDIUM; 1.24 + led_color = LED_RED; 1.25 + video_format = FREENECT_VIDEO_RGB; 1.26 + depth_format = FREENECT_DEPTH_11BIT; 1.27 + video_res = FREENECT_RESOLUTION_MEDIUM; 1.28 + depth_res = FREENECT_RESOLUTION_MEDIUM; 1.29 } 1.30 1.31 bool init_kinect(freenect_context **kin_ctx, freenect_device **kin_dev, KinectParams *kin_params) 1.32 @@ -57,32 +57,32 @@ 1.33 return true; 1.34 } 1.35 1.36 -bool init_kinect_frames(freenect_context **kin_ctx, freenect_device **kin_dev, 1.37 +bool init_kinect_frames(freenect_context *kin_ctx, freenect_device *kin_dev, 1.38 KinectParams *kin_params) { 1.39 1.40 - freenect_set_video_callback(*kin_dev, video_cb); 1.41 - freenect_set_depth_callback(*kin_dev, depth_cb); 1.42 + freenect_set_video_callback(kin_dev, video_cb); 1.43 + freenect_set_depth_callback(kin_dev, depth_cb); 1.44 1.45 - if(freenect_set_video_mode(*kin_dev, 1.46 + if(freenect_set_video_mode(kin_dev, 1.47 freenect_find_video_mode(kin_params->video_res, 1.48 kin_params->video_format)) < 0) { 1.49 fprintf(stderr, "Failed to set kinect video mode.\n"); 1.50 return false; 1.51 } 1.52 1.53 - if(freenect_set_depth_mode(*kin_dev, 1.54 + if(freenect_set_depth_mode(kin_dev, 1.55 freenect_find_depth_mode(kin_params->depth_res, 1.56 kin_params->depth_format)) < 0) { 1.57 fprintf(stderr, "Failed to set kinect depth mode.\n"); 1.58 return false; 1.59 } 1.60 1.61 - if(freenect_start_video(*kin_dev) < 0) { 1.62 + if(freenect_start_video(kin_dev) < 0) { 1.63 fprintf(stderr, "Failed to start kinect video.\n"); 1.64 return false; 1.65 } 1.66 1.67 - if(freenect_start_depth(*kin_dev) < 0) { 1.68 + if(freenect_start_depth(kin_dev) < 0) { 1.69 fprintf(stderr, "Failed to start kinect depth video.\n"); 1.70 return false; 1.71 }