Revert "Add av1 test running real video clips."
This reverts commit 3a2be87b80759a659901776024609de7a19fbaca. Reason for revert: break internal test Original change's description: > Add av1 test running real video clips. > > Bug: None > Change-Id: I93bb8b3bf15d607d061aa74ad9e34609ffb2ef0a > Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/175821 > Commit-Queue: Jerome Jiang <jianj@google.com> > Commit-Queue: Stefan Holmer <holmer@google.com> > Reviewed-by: Stefan Holmer <stefan@webrtc.org> > Reviewed-by: Danil Chapovalov <danilchap@webrtc.org> > Cr-Commit-Position: refs/heads/master@{#31401} TBR=danilchap@webrtc.org,jianj@google.com,stefan@webrtc.org,holmer@google.com,marpan@webrtc.org Change-Id: I2689ab4f7f26af6e26a4a188a2aa0b4f90a1a92f No-Presubmit: true No-Tree-Checks: true No-Try: true Bug: None Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/176374 Reviewed-by: Ying Wang <yinwa@webrtc.org> Commit-Queue: Ying Wang <yinwa@webrtc.org> Cr-Commit-Position: refs/heads/master@{#31405}
This commit is contained in:
@ -19,7 +19,7 @@
|
||||
#include "absl/types/optional.h"
|
||||
#include "api/video/video_bitrate_allocation.h"
|
||||
#include "api/video/video_codec_type.h"
|
||||
#include "common_types.h" // NOLINT(build/include_directory)
|
||||
#include "common_types.h" // NOLINT(build/include)
|
||||
#include "rtc_base/system/rtc_export.h"
|
||||
|
||||
namespace webrtc {
|
||||
|
@ -6,7 +6,6 @@
|
||||
# in the file PATENTS. All contributing project authors may
|
||||
# be found in the AUTHORS file in the root of the source tree.
|
||||
|
||||
import("//third_party/libaom/options.gni")
|
||||
import("../../webrtc.gni")
|
||||
|
||||
rtc_library("encoded_frame") {
|
||||
@ -786,9 +785,6 @@ if (rtc_include_tests) {
|
||||
"codecs/vp8/test/vp8_impl_unittest.cc",
|
||||
"codecs/vp9/test/vp9_impl_unittest.cc",
|
||||
]
|
||||
if (enable_libaom) {
|
||||
sources += [ "codecs/test/videocodec_test_libaom.cc" ]
|
||||
}
|
||||
if (rtc_use_h264) {
|
||||
sources += [ "codecs/test/videocodec_test_openh264.cc" ]
|
||||
}
|
||||
|
@ -38,6 +38,7 @@ namespace webrtc {
|
||||
namespace {
|
||||
|
||||
// Encoder configuration parameters
|
||||
constexpr int kQpMax = 56;
|
||||
constexpr int kQpMin = 10;
|
||||
constexpr int kUsageProfile = 1; // 0 = good quality; 1 = real-time.
|
||||
constexpr int kMinQindex = 58; // Min qindex threshold for QP scaling.
|
||||
@ -183,7 +184,7 @@ int LibaomAv1Encoder::InitEncode(const VideoCodec* codec_settings,
|
||||
cfg_.g_input_bit_depth = kBitDepth;
|
||||
cfg_.kf_mode = AOM_KF_DISABLED;
|
||||
cfg_.rc_min_quantizer = kQpMin;
|
||||
cfg_.rc_max_quantizer = encoder_settings_.qpMax;
|
||||
cfg_.rc_max_quantizer = kQpMax;
|
||||
cfg_.g_usage = kUsageProfile;
|
||||
if (svc_controller_->StreamConfig().num_spatial_layers > 1 ||
|
||||
svc_controller_->StreamConfig().num_temporal_layers > 1) {
|
||||
@ -283,7 +284,7 @@ bool LibaomAv1Encoder::SetSvcParams(
|
||||
svc_config.num_spatial_layers * svc_config.num_temporal_layers;
|
||||
for (int i = 0; i < num_layers; ++i) {
|
||||
svc_params.min_quantizers[i] = kQpMin;
|
||||
svc_params.max_quantizers[i] = encoder_settings_.qpMax;
|
||||
svc_params.max_quantizers[i] = kQpMax;
|
||||
}
|
||||
|
||||
// Assume each temporal layer doubles framerate.
|
||||
|
@ -32,7 +32,6 @@ TEST(LibaomAv1EncoderTest, InitAndRelease) {
|
||||
codec_settings.width = 1280;
|
||||
codec_settings.height = 720;
|
||||
codec_settings.maxFramerate = 30;
|
||||
codec_settings.qpMax = 63;
|
||||
VideoEncoder::Capabilities capabilities(/*loss_notification=*/false);
|
||||
VideoEncoder::Settings encoder_settings(capabilities, /*number_of_cores=*/1,
|
||||
/*max_payload_size=*/1200);
|
||||
|
@ -100,7 +100,6 @@ class TestAv1Encoder {
|
||||
codec_settings.height = kHeight;
|
||||
codec_settings.maxFramerate = kFramerate;
|
||||
codec_settings.maxBitrate = 1000;
|
||||
codec_settings.qpMax = 63;
|
||||
VideoEncoder::Settings encoder_settings(
|
||||
VideoEncoder::Capabilities(/*loss_notification=*/false),
|
||||
/*number_of_cores=*/1, /*max_payload_size=*/1200);
|
||||
|
@ -205,9 +205,6 @@ void VideoCodecTestFixtureImpl::Config::SetCodecSettings(
|
||||
codec_settings.VP9()->numberOfSpatialLayers =
|
||||
static_cast<uint8_t>(num_spatial_layers);
|
||||
break;
|
||||
case kVideoCodecAV1:
|
||||
codec_settings.qpMax = 63;
|
||||
break;
|
||||
case kVideoCodecH264:
|
||||
codec_settings.H264()->frameDroppingOn = frame_dropper_on;
|
||||
codec_settings.H264()->keyFrameInterval = kBaseKeyFrameInterval;
|
||||
|
@ -1,97 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2020 The WebRTC project authors. All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by a BSD-style license
|
||||
* that can be found in the LICENSE file in the root of the source
|
||||
* tree. An additional intellectual property rights grant can be found
|
||||
* in the file PATENTS. All contributing project authors may
|
||||
* be found in the AUTHORS file in the root of the source tree.
|
||||
*/
|
||||
|
||||
#include <memory>
|
||||
#include <vector>
|
||||
|
||||
#include "api/test/create_videocodec_test_fixture.h"
|
||||
#include "api/test/video/function_video_encoder_factory.h"
|
||||
#include "api/video_codecs/sdp_video_format.h"
|
||||
#include "media/base/media_constants.h"
|
||||
#include "media/engine/internal_decoder_factory.h"
|
||||
#include "media/engine/internal_encoder_factory.h"
|
||||
#include "media/engine/simulcast_encoder_adapter.h"
|
||||
#include "test/gtest.h"
|
||||
#include "test/testsupport/file_utils.h"
|
||||
|
||||
namespace webrtc {
|
||||
namespace test {
|
||||
namespace {
|
||||
// Test clips settings.
|
||||
constexpr int kCifWidth = 352;
|
||||
constexpr int kCifHeight = 288;
|
||||
constexpr int kNumFramesLong = 300;
|
||||
|
||||
VideoCodecTestFixture::Config CreateConfig(std::string filename) {
|
||||
VideoCodecTestFixture::Config config;
|
||||
config.filename = filename;
|
||||
config.filepath = ResourcePath(config.filename, "yuv");
|
||||
config.num_frames = kNumFramesLong;
|
||||
config.use_single_core = true;
|
||||
return config;
|
||||
}
|
||||
|
||||
TEST(VideoCodecTestLibaom, HighBitrateAV1) {
|
||||
auto config = CreateConfig("foreman_cif");
|
||||
config.SetCodecSettings(cricket::kAv1CodecName, 1, 1, 1, false, true, true,
|
||||
kCifWidth, kCifHeight);
|
||||
config.num_frames = kNumFramesLong;
|
||||
auto fixture = CreateVideoCodecTestFixture(config);
|
||||
|
||||
std::vector<RateProfile> rate_profiles = {{500, 30, 0}};
|
||||
|
||||
std::vector<RateControlThresholds> rc_thresholds = {
|
||||
{12, 1, 0, 1, 0.3, 0.1, 0, 1}};
|
||||
|
||||
std::vector<QualityThresholds> quality_thresholds = {{37, 34, 0.94, 0.92}};
|
||||
|
||||
fixture->RunTest(rate_profiles, &rc_thresholds, &quality_thresholds, nullptr);
|
||||
}
|
||||
|
||||
TEST(VideoCodecTestLibaom, VeryLowBitrateAV1) {
|
||||
auto config = CreateConfig("foreman_cif");
|
||||
config.SetCodecSettings(cricket::kAv1CodecName, 1, 1, 1, false, true, true,
|
||||
kCifWidth, kCifHeight);
|
||||
auto fixture = CreateVideoCodecTestFixture(config);
|
||||
|
||||
std::vector<RateProfile> rate_profiles = {{50, 30, 0}};
|
||||
|
||||
std::vector<RateControlThresholds> rc_thresholds = {
|
||||
{15, 8, 75, 2, 2, 2, 2, 1}};
|
||||
|
||||
std::vector<QualityThresholds> quality_thresholds = {{28, 25, 0.70, 0.62}};
|
||||
|
||||
fixture->RunTest(rate_profiles, &rc_thresholds, &quality_thresholds, nullptr);
|
||||
}
|
||||
|
||||
#if !defined(WEBRTC_ANDROID)
|
||||
constexpr int kHdWidth = 1280;
|
||||
constexpr int kHdHeight = 720;
|
||||
TEST(VideoCodecTestLibaom, HdAV1) {
|
||||
auto config = CreateConfig("ConferenceMotion_1280_720_50");
|
||||
config.SetCodecSettings(cricket::kAv1CodecName, 1, 1, 1, false, true, true,
|
||||
kHdWidth, kHdHeight);
|
||||
config.num_frames = kNumFramesLong;
|
||||
auto fixture = CreateVideoCodecTestFixture(config);
|
||||
|
||||
std::vector<RateProfile> rate_profiles = {{1000, 50, 0}};
|
||||
|
||||
std::vector<RateControlThresholds> rc_thresholds = {
|
||||
{13, 3, 0, 1, 0.3, 0.1, 0, 1}};
|
||||
|
||||
std::vector<QualityThresholds> quality_thresholds = {{36, 32, 0.93, 0.87}};
|
||||
|
||||
fixture->RunTest(rate_profiles, &rc_thresholds, &quality_thresholds, nullptr);
|
||||
}
|
||||
#endif
|
||||
|
||||
} // namespace
|
||||
} // namespace test
|
||||
} // namespace webrtc
|
Reference in New Issue
Block a user