Use SvcRateAllocator for av1
same as VP9, Av1 encoder supports spatial scalability and thus SvcRateAllocator better fits for it than SimulcastRateAllocator Bug: webrtc:12148 Change-Id: I3f78afb3aec00b6a8a7242fe8dce07752e7a514e Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/191960 Reviewed-by: Philip Eliasson <philipel@webrtc.org> Reviewed-by: Rasmus Brandt <brandtr@webrtc.org> Commit-Queue: Danil Chapovalov <danilchap@webrtc.org> Cr-Commit-Position: refs/heads/master@{#32565}
This commit is contained in:
parent
43ef5d99c1
commit
9c99b7964f
@ -331,7 +331,7 @@ rtc_library("builtin_video_bitrate_allocator_factory") {
|
||||
"../../api:scoped_refptr",
|
||||
"../../media:rtc_media_base",
|
||||
"../../modules/video_coding:video_coding_utility",
|
||||
"../../modules/video_coding:webrtc_vp9_helpers",
|
||||
"../../modules/video_coding/svc:svc_rate_allocator",
|
||||
"../video_codecs:video_codecs_api",
|
||||
]
|
||||
absl_deps = [ "//third_party/abseil-cpp/absl/base:core_headers" ]
|
||||
|
||||
@ -15,7 +15,7 @@
|
||||
#include "absl/base/macros.h"
|
||||
#include "api/video/video_bitrate_allocator.h"
|
||||
#include "api/video_codecs/video_codec.h"
|
||||
#include "modules/video_coding/codecs/vp9/svc_rate_allocator.h"
|
||||
#include "modules/video_coding/svc/svc_rate_allocator.h"
|
||||
#include "modules/video_coding/utility/simulcast_rate_allocator.h"
|
||||
|
||||
namespace webrtc {
|
||||
@ -30,15 +30,13 @@ class BuiltinVideoBitrateAllocatorFactory
|
||||
|
||||
std::unique_ptr<VideoBitrateAllocator> CreateVideoBitrateAllocator(
|
||||
const VideoCodec& codec) override {
|
||||
std::unique_ptr<VideoBitrateAllocator> rate_allocator;
|
||||
switch (codec.codecType) {
|
||||
case kVideoCodecAV1:
|
||||
case kVideoCodecVP9:
|
||||
rate_allocator.reset(new SvcRateAllocator(codec));
|
||||
break;
|
||||
return std::make_unique<SvcRateAllocator>(codec);
|
||||
default:
|
||||
rate_allocator.reset(new SimulcastRateAllocator(codec));
|
||||
return std::make_unique<SimulcastRateAllocator>(codec);
|
||||
}
|
||||
return rate_allocator;
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user