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_BASE_VIDEO_CAPTURE_TYPES_H_ | 5 #ifndef MEDIA_BASE_VIDEO_CAPTURE_TYPES_H_ |
| 6 #define MEDIA_BASE_VIDEO_CAPTURE_TYPES_H_ | 6 #define MEDIA_BASE_VIDEO_CAPTURE_TYPES_H_ |
| 7 | 7 |
| 8 #include <stddef.h> | 8 #include <stddef.h> |
| 9 | 9 |
| 10 #include <vector> | 10 #include <vector> |
| 11 | 11 |
| 12 #include "build/build_config.h" | 12 #include "build/build_config.h" |
| 13 #include "media/base/media_export.h" | 13 #include "media/base/media_export.h" |
| 14 #include "media/base/video_types.h" | 14 #include "media/base/video_types.h" |
| 15 #include "ui/gfx/geometry/size.h" | 15 #include "ui/gfx/geometry/size.h" |
| 16 | 16 |
| 17 namespace media { | 17 namespace media { |
| 18 | 18 |
| 19 // TODO(wjia): this type should be defined in a common place and | 19 // TODO(wjia): this type should be defined in a common place and |
| 20 // shared with device manager. | 20 // shared with device manager. |
| 21 typedef int VideoCaptureSessionId; | 21 typedef int VideoCaptureSessionId; |
| 22 | 22 |
| 23 // Storage type for the pixels. In principle, all combinations of Storage and | 23 // Storage type for the pixels. |
| 24 // Format are possible, though some are very typical, such as texture + ARGB, | |
| 25 // and others are only available if the platform allows it e.g. GpuMemoryBuffer. | |
| 26 // 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. |
|
mcasas
2016/10/06 18:31:15
Yeah, depending on the plans, add a TODO()
to exte
emircan
2016/10/07 17:40:12
Added a TODO for chfremer.
| |
| 27 enum VideoPixelStorage { | 25 enum VideoPixelStorage { |
| 28 PIXEL_STORAGE_CPU, | 26 PIXEL_STORAGE_CPU, |
| 29 PIXEL_STORAGE_GPUMEMORYBUFFER, | 27 PIXEL_STORAGE_MAX = PIXEL_STORAGE_CPU, |
| 30 PIXEL_STORAGE_MAX = PIXEL_STORAGE_GPUMEMORYBUFFER, | |
| 31 }; | 28 }; |
| 32 | 29 |
| 33 // Policies for capture devices that have source content that varies in size. | 30 // Policies for capture devices that have source content that varies in size. |
| 34 // It is up to the implementation how the captured content will be transformed | 31 // It is up to the implementation how the captured content will be transformed |
| 35 // (e.g., scaling and/or letterboxing) in order to produce video frames that | 32 // (e.g., scaling and/or letterboxing) in order to produce video frames that |
| 36 // strictly adheree to one of these policies. | 33 // strictly adheree to one of these policies. |
| 37 enum ResolutionChangePolicy { | 34 enum ResolutionChangePolicy { |
| 38 // Capture device outputs a fixed resolution all the time. The resolution of | 35 // Capture device outputs a fixed resolution all the time. The resolution of |
| 39 // the first frame is the resolution for all frames. | 36 // the first frame is the resolution for all frames. |
| 40 RESOLUTION_POLICY_FIXED_RESOLUTION, | 37 RESOLUTION_POLICY_FIXED_RESOLUTION, |
| (...skipping 102 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 143 // Policy for resolution change. | 140 // Policy for resolution change. |
| 144 ResolutionChangePolicy resolution_change_policy; | 141 ResolutionChangePolicy resolution_change_policy; |
| 145 | 142 |
| 146 // User-specified power line frequency. | 143 // User-specified power line frequency. |
| 147 PowerLineFrequency power_line_frequency; | 144 PowerLineFrequency power_line_frequency; |
| 148 }; | 145 }; |
| 149 | 146 |
| 150 } // namespace media | 147 } // namespace media |
| 151 | 148 |
| 152 #endif // MEDIA_BASE_VIDEO_CAPTURE_TYPES_H_ | 149 #endif // MEDIA_BASE_VIDEO_CAPTURE_TYPES_H_ |
| OLD | NEW |