Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 #ifndef MEDIA_CAPTURE_VIDEO_CAPTURE_TYPES_H_ | 5 #ifndef MEDIA_CAPTURE_VIDEO_CAPTURE_TYPES_H_ |
| 6 #define MEDIA_CAPTURE_VIDEO_CAPTURE_TYPES_H_ | 6 #define MEDIA_CAPTURE_VIDEO_CAPTURE_TYPES_H_ |
| 7 | 7 |
| 8 #include <stddef.h> | 8 #include <stddef.h> |
| 9 | 9 |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 10 matching lines...) Expand all Loading... | |
| 21 typedef int VideoCaptureSessionId; | 21 typedef int VideoCaptureSessionId; |
| 22 | 22 |
| 23 // Storage type for the pixels. | 23 // Storage type for the pixels. |
| 24 // TODO(mcasas): http://crbug.com/504160 Consider making this an enum class. | 24 // TODO(mcasas): http://crbug.com/504160 Consider making this an enum class. |
| 25 // TODO(chfremer): Extend or remove this enum. | 25 // TODO(chfremer): Extend or remove this enum. |
| 26 enum VideoPixelStorage { | 26 enum VideoPixelStorage { |
| 27 PIXEL_STORAGE_CPU, | 27 PIXEL_STORAGE_CPU, |
| 28 PIXEL_STORAGE_MAX = PIXEL_STORAGE_CPU, | 28 PIXEL_STORAGE_MAX = PIXEL_STORAGE_CPU, |
| 29 }; | 29 }; |
| 30 | 30 |
| 31 enum class VideoFacingMode { | |
| 32 // The source is facing toward the user (a self-view camera). | |
| 33 USER = 0, | |
| 34 // The source is facing away from the user (viewing the environment). | |
| 35 ENVIRONMENT, | |
| 36 // The source is facing to the left of the user. | |
| 37 LEFT, | |
| 38 // The source is facing to the right of the user. | |
| 39 RIGHT, | |
|
mcasas
2017/01/11 22:24:59
I'd add here NONE/UNKNOWN or similar.
shenghao
2017/01/12 08:10:48
Done.
| |
| 40 }; | |
| 41 | |
| 31 // Policies for capture devices that have source content that varies in size. | 42 // Policies for capture devices that have source content that varies in size. |
| 32 // It is up to the implementation how the captured content will be transformed | 43 // It is up to the implementation how the captured content will be transformed |
| 33 // (e.g., scaling and/or letterboxing) in order to produce video frames that | 44 // (e.g., scaling and/or letterboxing) in order to produce video frames that |
| 34 // strictly adheree to one of these policies. | 45 // strictly adheree to one of these policies. |
| 35 enum ResolutionChangePolicy { | 46 enum ResolutionChangePolicy { |
| 36 // Capture device outputs a fixed resolution all the time. The resolution of | 47 // Capture device outputs a fixed resolution all the time. The resolution of |
| 37 // the first frame is the resolution for all frames. | 48 // the first frame is the resolution for all frames. |
| 38 RESOLUTION_POLICY_FIXED_RESOLUTION, | 49 RESOLUTION_POLICY_FIXED_RESOLUTION, |
| 39 | 50 |
| 40 // Capture device is allowed to output frames of varying resolutions. The | 51 // Capture device is allowed to output frames of varying resolutions. The |
| (...skipping 99 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 140 // Policy for resolution change. | 151 // Policy for resolution change. |
| 141 ResolutionChangePolicy resolution_change_policy; | 152 ResolutionChangePolicy resolution_change_policy; |
| 142 | 153 |
| 143 // User-specified power line frequency. | 154 // User-specified power line frequency. |
| 144 PowerLineFrequency power_line_frequency; | 155 PowerLineFrequency power_line_frequency; |
| 145 }; | 156 }; |
| 146 | 157 |
| 147 } // namespace media | 158 } // namespace media |
| 148 | 159 |
| 149 #endif // MEDIA_CAPTURE_VIDEO_CAPTURE_TYPES_H_ | 160 #endif // MEDIA_CAPTURE_VIDEO_CAPTURE_TYPES_H_ |
| OLD | NEW |