Move h264_profile_level_id and vp9_profile to api/video_codecs
This is a refactor to simplify a follow-up CL of adding SdpVideoFormat::IsSameCodec. The original files media/base/h264_profile_level_id.* and media/base/vp9_profile.h must be kept until downstream projects stop using them. Bug: chroimium:1187565 Change-Id: Ib39eca095a3d61939a914d9bffaf4b891ddd222f Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/215236 Reviewed-by: Harald Alvestrand <hta@webrtc.org> Reviewed-by: Kári Helgason <kthelgason@webrtc.org> Reviewed-by: Niels Moller <nisse@webrtc.org> Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org> Commit-Queue: Johannes Kron <kron@webrtc.org> Cr-Commit-Position: refs/heads/master@{#33782}
This commit is contained in:
committed by
Commit Bot
parent
8546666cb9
commit
c3fcee7c3a
@ -25,12 +25,12 @@
|
||||
#include "api/array_view.h"
|
||||
#include "api/transport/field_trial_based_config.h"
|
||||
#include "api/video/video_bitrate_allocation.h"
|
||||
#include "api/video_codecs/h264_profile_level_id.h"
|
||||
#include "api/video_codecs/sdp_video_format.h"
|
||||
#include "api/video_codecs/video_codec.h"
|
||||
#include "api/video_codecs/video_decoder.h"
|
||||
#include "api/video_codecs/video_encoder_config.h"
|
||||
#include "common_video/h264/h264_common.h"
|
||||
#include "media/base/h264_profile_level_id.h"
|
||||
#include "media/base/media_constants.h"
|
||||
#include "media/engine/internal_decoder_factory.h"
|
||||
#include "media/engine/internal_encoder_factory.h"
|
||||
@ -302,11 +302,11 @@ std::string VideoCodecTestFixtureImpl::Config::CodecName() const {
|
||||
name = CodecTypeToPayloadString(codec_settings.codecType);
|
||||
}
|
||||
if (codec_settings.codecType == kVideoCodecH264) {
|
||||
if (h264_codec_settings.profile == H264::kProfileConstrainedHigh) {
|
||||
if (h264_codec_settings.profile == H264Profile::kProfileConstrainedHigh) {
|
||||
return name + "-CHP";
|
||||
} else {
|
||||
RTC_DCHECK_EQ(h264_codec_settings.profile,
|
||||
H264::kProfileConstrainedBaseline);
|
||||
H264Profile::kProfileConstrainedBaseline);
|
||||
return name + "-CBP";
|
||||
}
|
||||
}
|
||||
@ -613,8 +613,8 @@ bool VideoCodecTestFixtureImpl::CreateEncoderAndDecoder() {
|
||||
? "1"
|
||||
: "0";
|
||||
params = {{cricket::kH264FmtpProfileLevelId,
|
||||
*H264::ProfileLevelIdToString(H264::ProfileLevelId(
|
||||
config_.h264_codec_settings.profile, H264::kLevel3_1))},
|
||||
*H264ProfileLevelIdToString(H264ProfileLevelId(
|
||||
config_.h264_codec_settings.profile, H264Level::kLevel3_1))},
|
||||
{cricket::kH264FmtpPacketizationMode, packetization_mode}};
|
||||
} else {
|
||||
params = {};
|
||||
|
||||
@ -95,7 +95,7 @@ TEST(VideoCodecTestMediaCodec, DISABLED_ForemanCif500kbpsH264CHP) {
|
||||
const auto frame_checker =
|
||||
std::make_unique<VideoCodecTestFixtureImpl::H264KeyframeChecker>();
|
||||
|
||||
config.h264_codec_settings.profile = H264::kProfileConstrainedHigh;
|
||||
config.h264_codec_settings.profile = H264Profile::kProfileConstrainedHigh;
|
||||
config.encoded_frame_checker = frame_checker.get();
|
||||
config.SetCodecSettings(cricket::kH264CodecName, 1, 1, 1, false, false, false,
|
||||
352, 288);
|
||||
|
||||
@ -71,7 +71,7 @@ MAYBE_TEST(VideoCodecTestVideoToolbox, ForemanCif500kbpsH264CHP) {
|
||||
const auto frame_checker =
|
||||
std::make_unique<VideoCodecTestFixtureImpl::H264KeyframeChecker>();
|
||||
auto config = CreateConfig();
|
||||
config.h264_codec_settings.profile = H264::kProfileConstrainedHigh;
|
||||
config.h264_codec_settings.profile = H264Profile::kProfileConstrainedHigh;
|
||||
config.SetCodecSettings(cricket::kH264CodecName, 1, 1, 1, false, false, false,
|
||||
352, 288);
|
||||
config.encoded_frame_checker = frame_checker.get();
|
||||
|
||||
Reference in New Issue
Block a user