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

Unified Diff: cc/resources/video_resource_updater_unittest.cc

Issue 2122573003: media: replace LUMINANCE_F16 by RG_88 for 9/10-bit h264 videos Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase to ToT Created 4 years, 2 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
« no previous file with comments | « cc/resources/video_resource_updater.cc ('k') | cc/test/data/yuv_stripes_clipped_rg88.png » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/resources/video_resource_updater_unittest.cc
diff --git a/cc/resources/video_resource_updater_unittest.cc b/cc/resources/video_resource_updater_unittest.cc
index 9b9dcfccf9ab60ef7b9df11c429d745bd2b6ce9f..1d8dad7aab23a5336c29c631baad5cb465114c1c 100644
--- a/cc/resources/video_resource_updater_unittest.cc
+++ b/cc/resources/video_resource_updater_unittest.cc
@@ -253,7 +253,7 @@ TEST_F(VideoResourceUpdaterTest, SoftwareFrame) {
EXPECT_EQ(VideoFrameExternalResources::YUV_RESOURCE, resources.type);
}
-TEST_F(VideoResourceUpdaterTest, HighBitFrameNoF16) {
+TEST_F(VideoResourceUpdaterTest, HighBitFrameNo16bitTexture) {
VideoResourceUpdater updater(context_provider_.get(),
resource_provider3d_.get());
scoped_refptr<media::VideoFrame> video_frame = CreateTestHighBitFrame();
@@ -290,6 +290,23 @@ TEST_F(VideoResourceUpdaterTestWithF16, HighBitFrame) {
EXPECT_NEAR(resources2.offset, 0.5, 0.1);
}
+class VideoResourceUpdaterTestWithRG : public VideoResourceUpdaterTest {
+ public:
+ VideoResourceUpdaterTestWithRG() : VideoResourceUpdaterTest() {
+ context3d_->set_support_texture_rg(true);
+ }
+};
+
+TEST_F(VideoResourceUpdaterTestWithRG, HighBitFrame) {
+ VideoResourceUpdater updater(context_provider_.get(),
+ resource_provider3d_.get());
+ scoped_refptr<media::VideoFrame> video_frame = CreateTestHighBitFrame();
+
+ VideoFrameExternalResources resources =
+ updater.CreateExternalResourcesFromVideoFrame(video_frame);
+ EXPECT_EQ(VideoFrameExternalResources::YUV_RESOURCE, resources.type);
+}
+
TEST_F(VideoResourceUpdaterTest, HighBitFrameSoftwareCompositor) {
VideoResourceUpdater updater(nullptr, resource_provider_software_.get());
scoped_refptr<media::VideoFrame> video_frame = CreateTestHighBitFrame();
« no previous file with comments | « cc/resources/video_resource_updater.cc ('k') | cc/test/data/yuv_stripes_clipped_rg88.png » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698