Lines Matching refs:frame1
494 static bool IsEqual(const cricket::VideoFrame& frame1, in IsEqual() argument
497 return IsEqual(frame1, in IsEqual()
507 static bool IsEqualWithCrop(const cricket::VideoFrame& frame1, in IsEqualWithCrop() argument
510 return frame1.GetWidth() <= frame2.GetWidth() && in IsEqualWithCrop()
511 frame1.GetHeight() <= frame2.GetHeight() && in IsEqualWithCrop()
512 IsEqual(frame1, in IsEqualWithCrop()
573 T frame1, frame2; in ConstructI422() local
574 ASSERT_TRUE(LoadFrameNoRepeat(&frame1)); in ConstructI422()
580 EXPECT_EQ(0, libyuv::I420ToI422(frame1.GetYPlane(), frame1.GetYPitch(), in ConstructI422()
581 frame1.GetUPlane(), frame1.GetUPitch(), in ConstructI422()
582 frame1.GetVPlane(), frame1.GetVPitch(), in ConstructI422()
589 EXPECT_TRUE(IsEqual(frame1, frame2, 1)); in ConstructI422()
594 T frame1, frame2; in ConstructYuy2() local
595 ASSERT_TRUE(LoadFrameNoRepeat(&frame1)); in ConstructYuy2()
599 EXPECT_EQ(0, libyuv::I420ToYUY2(frame1.GetYPlane(), frame1.GetYPitch(), in ConstructYuy2()
600 frame1.GetUPlane(), frame1.GetUPitch(), in ConstructYuy2()
601 frame1.GetVPlane(), frame1.GetVPitch(), in ConstructYuy2()
606 EXPECT_TRUE(IsEqual(frame1, frame2, 0)); in ConstructYuy2()
611 T frame1, frame2; in ConstructYuy2Unaligned() local
612 ASSERT_TRUE(LoadFrameNoRepeat(&frame1)); in ConstructYuy2Unaligned()
616 EXPECT_EQ(0, libyuv::I420ToYUY2(frame1.GetYPlane(), frame1.GetYPitch(), in ConstructYuy2Unaligned()
617 frame1.GetUPlane(), frame1.GetUPitch(), in ConstructYuy2Unaligned()
618 frame1.GetVPlane(), frame1.GetVPitch(), in ConstructYuy2Unaligned()
623 EXPECT_TRUE(IsEqual(frame1, frame2, 0)); in ConstructYuy2Unaligned()
629 T frame1, frame2; in ConstructYuy2Wide() local
635 &frame1)); in ConstructYuy2Wide()
638 EXPECT_TRUE(IsEqual(frame1, frame2, 0)); in ConstructYuy2Wide()
643 T frame1, frame2; in ConstructUyvy() local
648 &frame1)); in ConstructUyvy()
651 EXPECT_TRUE(IsEqual(frame1, frame2, 0)); in ConstructUyvy()
686 T frame1, frame2; in ConstructABGR() local
691 &frame1)); in ConstructABGR()
694 EXPECT_TRUE(IsEqual(frame1, frame2, 2)); in ConstructABGR()
700 T frame1, frame2; in ConstructARGB() local
705 &frame1)); in ConstructARGB()
708 EXPECT_TRUE(IsEqual(frame1, frame2, 2)); in ConstructARGB()
714 T frame1, frame2; in ConstructARGBWide() local
719 kWidth * 10, kHeight / 10, &frame1)); in ConstructARGBWide()
722 EXPECT_TRUE(IsEqual(frame1, frame2, 2)); in ConstructARGBWide()
728 T frame1, frame2; in ConstructBGRA() local
733 &frame1)); in ConstructBGRA()
736 EXPECT_TRUE(IsEqual(frame1, frame2, 2)); in ConstructBGRA()
742 T frame1, frame2; in Construct24BG() local
747 &frame1)); in Construct24BG()
750 EXPECT_TRUE(IsEqual(frame1, frame2, 2)); in Construct24BG()
756 T frame1, frame2; in ConstructRaw() local
761 &frame1)); in ConstructRaw()
764 EXPECT_TRUE(IsEqual(frame1, frame2, 2)); in ConstructRaw()
769 T frame1, frame2; in ConstructRGB565() local
774 ASSERT_TRUE(LoadFrameNoRepeat(&frame1)); in ConstructRGB565()
775 EXPECT_EQ(out_size, frame1.ConvertToRgbBuffer(cricket::FOURCC_RGBP, in ConstructRGB565()
780 EXPECT_TRUE(IsEqual(frame1, frame2, 20)); in ConstructRGB565()
785 T frame1, frame2; in ConstructARGB1555() local
790 ASSERT_TRUE(LoadFrameNoRepeat(&frame1)); in ConstructARGB1555()
791 EXPECT_EQ(out_size, frame1.ConvertToRgbBuffer(cricket::FOURCC_RGBO, in ConstructARGB1555()
796 EXPECT_TRUE(IsEqual(frame1, frame2, 20)); in ConstructARGB1555()
801 T frame1, frame2; in ConstructARGB4444() local
806 ASSERT_TRUE(LoadFrameNoRepeat(&frame1)); in ConstructARGB4444()
807 EXPECT_EQ(out_size, frame1.ConvertToRgbBuffer(cricket::FOURCC_R444, in ConstructARGB4444()
812 EXPECT_TRUE(IsEqual(frame1, frame2, 20)); in ConstructARGB4444()
818 T frame1, frame2, frame3; \
824 webrtc::kVideoRotation_180, &frame1)); \
832 int width_rotate = static_cast<int>(frame1.GetWidth()); \
833 int height_rotate = static_cast<int>(frame1.GetHeight()); \
841 EXPECT_TRUE(IsEqual(frame1, frame3, 0)); \
849 T frame1, frame2, frame3; \
855 &frame1)); \
863 int width_rotate = static_cast<int>(frame1.GetWidth()); \
864 int height_rotate = static_cast<int>(frame1.GetHeight()); \
872 EXPECT_TRUE(IsEqual(frame1, frame3, 0)); \
1058 T frame1, frame2; in ConstructI420CropHorizontal() local
1059 ASSERT_TRUE(LoadFrameNoRepeat(&frame1)); in ConstructI420CropHorizontal()
1063 EXPECT_TRUE(IsEqualWithCrop(frame2, frame1, kWidth / 8, 0, 0)); in ConstructI420CropHorizontal()
1068 T frame1, frame2; in ConstructYuy2CropHorizontal() local
1073 &frame1)); in ConstructYuy2CropHorizontal()
1077 EXPECT_TRUE(IsEqualWithCrop(frame2, frame1, kWidth / 8, 0, 0)); in ConstructYuy2CropHorizontal()
1082 T frame1, frame2; in ConstructARGBCropHorizontal() local
1087 &frame1)); in ConstructARGBCropHorizontal()
1091 EXPECT_TRUE(IsEqualWithCrop(frame2, frame1, kWidth / 8, 0, 2)); in ConstructARGBCropHorizontal()
1096 T frame1, frame2; in ConstructI420CropVertical() local
1097 ASSERT_TRUE(LoadFrameNoRepeat(&frame1)); in ConstructI420CropVertical()
1101 EXPECT_TRUE(IsEqualWithCrop(frame2, frame1, 0, kHeight / 8, 0)); in ConstructI420CropVertical()
1106 T frame1, frame2, frame3; in ConstructI420Aliases() local
1108 &frame1)); in ConstructI420Aliases()
1113 EXPECT_TRUE(IsEqual(frame1, frame2, 0)); in ConstructI420Aliases()
1114 EXPECT_TRUE(IsEqual(frame1, frame3, 0)); in ConstructI420Aliases()
1119 T frame1, frame2; in ConstructMjpgI420() local
1120 ASSERT_TRUE(LoadFrameNoRepeat(&frame1)); in ConstructMjpgI420()
1123 EXPECT_TRUE(IsEqual(frame1, frame2, 32)); in ConstructMjpgI420()
1128 T frame1, frame2; in ConstructMjpgI422() local
1129 ASSERT_TRUE(LoadFrameNoRepeat(&frame1)); in ConstructMjpgI422()
1132 EXPECT_TRUE(IsEqual(frame1, frame2, 32)); in ConstructMjpgI422()
1137 T frame1, frame2; in ConstructMjpgI444() local
1138 ASSERT_TRUE(LoadFrameNoRepeat(&frame1)); in ConstructMjpgI444()
1141 EXPECT_TRUE(IsEqual(frame1, frame2, 32)); in ConstructMjpgI444()
1146 T frame1, frame2; in ConstructMjpgI411() local
1147 ASSERT_TRUE(LoadFrameNoRepeat(&frame1)); in ConstructMjpgI411()
1150 EXPECT_TRUE(IsEqual(frame1, frame2, 32)); in ConstructMjpgI411()
1156 T frame1, frame2; in ConstructMjpgI400() local
1157 ASSERT_TRUE(LoadFrameNoRepeat(&frame1)); in ConstructMjpgI400()
1160 EXPECT_TRUE(IsPlaneEqual("y", frame1.GetYPlane(), frame1.GetYPitch(), in ConstructMjpgI400()
1163 EXPECT_TRUE(IsEqual(frame1, frame2, 128)); in ConstructMjpgI400()
1289 T frame1, frame2, frame3, frame4; in ConstructYuy2Aliases() local
1294 &frame1)); in ConstructYuy2Aliases()
1301 EXPECT_TRUE(IsEqual(frame1, frame2, 0)); in ConstructYuy2Aliases()
1302 EXPECT_TRUE(IsEqual(frame1, frame3, 0)); in ConstructYuy2Aliases()
1303 EXPECT_TRUE(IsEqual(frame1, frame4, 0)); in ConstructYuy2Aliases()
1308 T frame1, frame2, frame3, frame4; in ConstructUyvyAliases() local
1313 &frame1)); in ConstructUyvyAliases()
1320 EXPECT_TRUE(IsEqual(frame1, frame2, 0)); in ConstructUyvyAliases()
1321 EXPECT_TRUE(IsEqual(frame1, frame3, 0)); in ConstructUyvyAliases()
1322 EXPECT_TRUE(IsEqual(frame1, frame4, 0)); in ConstructUyvyAliases()
1327 T frame1, frame2; in ConstructCopy() local
1328 ASSERT_TRUE(LoadFrameNoRepeat(&frame1)); in ConstructCopy()
1330 EXPECT_TRUE(frame2.Init(frame1)); in ConstructCopy()
1332 EXPECT_TRUE(IsEqual(frame1, frame2, 0)); in ConstructCopy()
1337 T frame1, frame2; in ConstructCopyIsRef() local
1338 ASSERT_TRUE(LoadFrameNoRepeat(&frame1)); in ConstructCopyIsRef()
1340 EXPECT_TRUE(frame2.Init(frame1)); in ConstructCopyIsRef()
1342 EXPECT_TRUE(IsEqual(frame1, frame2, 0)); in ConstructCopyIsRef()
1343 EXPECT_EQ(frame1.GetYPlane(), frame2.GetYPlane()); in ConstructCopyIsRef()
1344 EXPECT_EQ(frame1.GetUPlane(), frame2.GetUPlane()); in ConstructCopyIsRef()
1345 EXPECT_EQ(frame1.GetVPlane(), frame2.GetVPlane()); in ConstructCopyIsRef()
1361 T frame1, frame2; in ConstructYuy2AllSizes() local
1368 &frame1)); in ConstructYuy2AllSizes()
1371 EXPECT_TRUE(IsEqual(frame1, frame2, 0)); in ConstructYuy2AllSizes()
1379 T frame1, frame2; in ConstructARGBAllSizes() local
1386 &frame1)); in ConstructARGBAllSizes()
1389 EXPECT_TRUE(IsEqual(frame1, frame2, 64)); in ConstructARGBAllSizes()
1402 &frame1)); in ConstructARGBAllSizes()
1405 EXPECT_TRUE(IsEqual(frame1, frame2, 64)); in ConstructARGBAllSizes()
1412 T frame1, frame2; in Reset() local
1418 EXPECT_TRUE(frame1.InitToBlack(kWidth, kHeight, 1, 1, 0)); in Reset()
1420 EXPECT_TRUE(IsBlack(frame1)); in Reset()
1421 EXPECT_TRUE(IsEqual(frame1, frame2, 0)); in Reset()
1422 EXPECT_TRUE(frame1.Reset(cricket::FOURCC_I420, kWidth, kHeight, kWidth, in Reset()
1427 EXPECT_EQ(webrtc::kVideoRotation_0, frame1.GetVideoRotation()); in Reset()
1429 EXPECT_EQ(rotation, frame1.GetVideoRotation()); in Reset()
1434 EXPECT_TRUE(kHeight == frame1.GetWidth()); in Reset()
1435 EXPECT_TRUE(kWidth == frame1.GetHeight()); in Reset()
1437 EXPECT_TRUE(kWidth == frame1.GetWidth()); in Reset()
1438 EXPECT_TRUE(kHeight == frame1.GetHeight()); in Reset()
1440 EXPECT_FALSE(IsBlack(frame1)); in Reset()
1441 EXPECT_FALSE(IsEqual(frame1, frame2, 0)); in Reset()
1475 T frame1, frame2; in ConvertToBuffer() local
1490 ASSERT_TRUE(LoadFrameNoRepeat(&frame1)); in ConvertToBuffer()
1493 EXPECT_EQ(out_size, frame1.ConvertToRgbBuffer(fourcc, in ConvertToBuffer()
1512 EXPECT_TRUE(IsEqual(frame1, frame2, error)); in ConvertToBuffer()
1797 T frame1, frame2; in ConvertToI422Buffer() local
1803 ASSERT_TRUE(LoadFrameNoRepeat(&frame1)); in ConvertToI422Buffer()
1805 EXPECT_EQ(0, libyuv::I420ToI422(frame1.GetYPlane(), frame1.GetYPitch(), in ConvertToI422Buffer()
1806 frame1.GetUPlane(), frame1.GetUPitch(), in ConvertToI422Buffer()
1807 frame1.GetVPlane(), frame1.GetVPitch(), in ConvertToI422Buffer()
1816 EXPECT_TRUE(IsEqual(frame1, frame2, 1)); in ConvertToI422Buffer()