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

Unified Diff: content/browser/media/media_internals_unittest.cc

Issue 1204063005: Reland: Video Capture: extract storage info from pixel format in VideoCaptureFormat. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: dcheng@s https://codereview.chromium.org/1210743003/#ps20001 Created 5 years, 6 months 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: content/browser/media/media_internals_unittest.cc
diff --git a/content/browser/media/media_internals_unittest.cc b/content/browser/media/media_internals_unittest.cc
index 1f5640332108749dbccb3f74dc19b78bf27fda3a..52699538f1fcc51e170107b0e42d566847c63265 100644
--- a/content/browser/media/media_internals_unittest.cc
+++ b/content/browser/media/media_internals_unittest.cc
@@ -152,14 +152,14 @@ TEST_F(MediaInternalsVideoCaptureDeviceTest,
const float kFrameRate = 30.0f;
const gfx::Size kFrameSize(1280, 720);
const media::VideoPixelFormat kPixelFormat = media::PIXEL_FORMAT_I420;
- const media::VideoCaptureFormat capture_format(
- kFrameSize, kFrameRate, kPixelFormat);
- const std::string expected_string =
- base::StringPrintf("resolution: %s, fps: %.3f, pixel format: %s",
- kFrameSize.ToString().c_str(),
- kFrameRate,
- media::VideoCaptureFormat::PixelFormatToString(
- kPixelFormat).c_str());
+ const media::VideoPixelStorage kPixelStorage = media::PIXEL_STORAGE_CPU;
+ const media::VideoCaptureFormat capture_format(kFrameSize, kFrameRate,
+ kPixelFormat, kPixelStorage);
+ const std::string expected_string = base::StringPrintf(
+ "(%s)@%.3ffps, pixel format: %s storage: %s.",
+ kFrameSize.ToString().c_str(), kFrameRate,
+ media::VideoCaptureFormat::PixelFormatToString(kPixelFormat).c_str(),
+ media::VideoCaptureFormat::PixelStorageToString(kPixelStorage).c_str());
EXPECT_EQ(expected_string, capture_format.ToString());
}

Powered by Google App Engine
This is Rietveld 408576698