Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(93)

Unified Diff: media/base/video_capture_types.cc

Issue 1439533004: Remove dead code paths around PIXEL_STORAGE_TEXTURE in capture pipeline. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: media/base/video_capture_types.cc
diff --git a/media/base/video_capture_types.cc b/media/base/video_capture_types.cc
index 0bc6ae639511625fe34fa214aacb01fd65d860d9..9e917d41e49dcb163ee105c0960e903b4bd2db34 100644
--- a/media/base/video_capture_types.cc
+++ b/media/base/video_capture_types.cc
@@ -57,8 +57,10 @@ bool VideoCaptureFormat::IsValid() const {
(frame_size.GetArea() < media::limits::kMaxCanvas) &&
(frame_rate >= 0.0f) &&
(frame_rate < media::limits::kMaxFramesPerSecond) &&
- (pixel_storage != PIXEL_STORAGE_TEXTURE ||
- pixel_format == PIXEL_FORMAT_ARGB);
+ (pixel_format > PIXEL_FORMAT_UNKNOWN &&
mcasas 2015/11/13 19:13:57 Actually there's at least one case of valid VideoF
miu 2015/11/14 03:43:47 Done.
+ pixel_format <= PIXEL_FORMAT_MAX) &&
+ (pixel_storage == PIXEL_STORAGE_CPU ||
+ pixel_storage == PIXEL_STORAGE_GPUMEMORYBUFFER);
}
size_t VideoCaptureFormat::ImageAllocationSize() const {
@@ -80,8 +82,6 @@ std::string VideoCaptureFormat::PixelStorageToString(
switch (storage) {
case PIXEL_STORAGE_CPU:
return "CPU";
- case PIXEL_STORAGE_TEXTURE:
- return "TEXTURE";
case PIXEL_STORAGE_GPUMEMORYBUFFER:
return "GPUMEMORYBUFFER";
}

Powered by Google App Engine
This is Rietveld 408576698