Index: media/base/video_frame_unittest.cc |
diff --git a/media/base/video_frame_unittest.cc b/media/base/video_frame_unittest.cc |
index 24b8a2b4b5d4d23ddbae47adbd96e63def52356a..2a1bb946c88bfd89b775a9c28c6e7e650b96d169 100644 |
--- a/media/base/video_frame_unittest.cc |
+++ b/media/base/video_frame_unittest.cc |
@@ -331,7 +331,7 @@ TEST(VideoFrame, |
EXPECT_EQ(release_sync_point, called_sync_point); |
} |
-TEST(VideoFrame, ZeroInitialized) { |
+TEST(VideoFrame, InitializedAndZeroed) { |
DaleCurtis
2015/07/09 23:29:44
Just move to the frame pool unittests?
emircan
2015/07/10 00:22:53
Done.
|
const int kWidth = 64; |
const int kHeight = 48; |
const base::TimeDelta kTimestamp = base::TimeDelta::FromMicroseconds(1337); |
@@ -339,6 +339,7 @@ TEST(VideoFrame, ZeroInitialized) { |
gfx::Size size(kWidth, kHeight); |
scoped_refptr<media::VideoFrame> frame = VideoFrame::CreateFrame( |
media::VideoFrame::YV12, size, gfx::Rect(size), size, kTimestamp); |
+ memset(frame->data(0), 0, VideoFrame::AlignedAllocationSize(frame)); |
for (size_t i = 0; i < VideoFrame::NumPlanes(frame->format()); ++i) |
EXPECT_EQ(0, frame->data(i)[0]); |