| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "extensions/browser/api/webcam_private/v4l2_webcam.h" | 5 #include "extensions/browser/api/webcam_private/v4l2_webcam.h" |
| 6 | 6 |
| 7 #include <errno.h> |
| 7 #include <fcntl.h> | 8 #include <fcntl.h> |
| 8 #include <linux/uvcvideo.h> | 9 #include <linux/uvcvideo.h> |
| 9 #include <linux/videodev2.h> | 10 #include <linux/videodev2.h> |
| 10 #include <stdio.h> | 11 #include <stdio.h> |
| 11 #include <sys/ioctl.h> | 12 #include <sys/ioctl.h> |
| 12 #include <unistd.h> | 13 #include <unistd.h> |
| 13 | 14 |
| 14 #include "base/posix/eintr_wrapper.h" | 15 #include "base/posix/eintr_wrapper.h" |
| 15 | 16 |
| 16 #define V4L2_CID_PAN_SPEED (V4L2_CID_CAMERA_CLASS_BASE+32) | 17 #define V4L2_CID_PAN_SPEED (V4L2_CID_CAMERA_CLASS_BASE+32) |
| (...skipping 179 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 196 if (!SetWebcamParameter(fd_.get(), V4L2_CID_ZOOM_ABSOLUTE, kDefaultZoom)) { | 197 if (!SetWebcamParameter(fd_.get(), V4L2_CID_ZOOM_ABSOLUTE, kDefaultZoom)) { |
| 197 callback.Run(false); | 198 callback.Run(false); |
| 198 return; | 199 return; |
| 199 } | 200 } |
| 200 } | 201 } |
| 201 | 202 |
| 202 callback.Run(true); | 203 callback.Run(true); |
| 203 } | 204 } |
| 204 | 205 |
| 205 } // namespace extensions | 206 } // namespace extensions |
| OLD | NEW |