Video encoding: allow to use system OpenH264
OpenH264 cannot be usually used everywhere as it's proprietary and for that reason it's usually disabled or apps using it are not allowed to be available in default installations. Using system OpenH264 option allows us to use e.g. noopenH264, that can be present in default installations and later replaced by OpenH264 installed from 3rd party repository. Bug: webrtc:14717 Change-Id: I015aacdb48c0636935f611459f0c9a6aa74a8f94 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/349301 Reviewed-by: Sergey Silkin <ssilkin@webrtc.org> Reviewed-by: Tomas Gunnarsson <tommi@webrtc.org> Commit-Queue: Jan Grulich <grulja@gmail.com> Cr-Commit-Position: refs/heads/main@{#42509}
This commit is contained in:
parent
578905e7ca
commit
0f862520dc
@ -6,6 +6,7 @@
|
||||
# in the file PATENTS. All contributing project authors may
|
||||
# be found in the AUTHORS file in the root of the source tree.
|
||||
|
||||
import("//build/config/linux/pkg_config.gni")
|
||||
import("//third_party/libaom/options.gni")
|
||||
import("../../webrtc.gni")
|
||||
|
||||
@ -366,6 +367,12 @@ rtc_source_set("codec_globals_headers") {
|
||||
deps = [ "../../rtc_base:checks" ]
|
||||
}
|
||||
|
||||
if (rtc_use_h264 && rtc_system_openh264) {
|
||||
pkg_config("openh264") {
|
||||
packages = [ "openh264" ]
|
||||
}
|
||||
}
|
||||
|
||||
rtc_library("video_coding_utility") {
|
||||
visibility = [ "*" ]
|
||||
sources = [
|
||||
@ -488,10 +495,12 @@ rtc_library("webrtc_h264") {
|
||||
]
|
||||
|
||||
if (rtc_use_h264) {
|
||||
deps += [
|
||||
"//third_party/ffmpeg",
|
||||
"//third_party/openh264:encoder",
|
||||
]
|
||||
deps += [ "//third_party/ffmpeg" ]
|
||||
if (rtc_system_openh264) {
|
||||
configs += [ ":openh264" ]
|
||||
} else {
|
||||
deps += [ "//third_party/openh264:encoder" ]
|
||||
}
|
||||
if (!build_with_mozilla) {
|
||||
deps += [ "../../media:rtc_media_base" ]
|
||||
}
|
||||
|
||||
@ -190,6 +190,9 @@ declare_args() {
|
||||
rtc_use_h264 =
|
||||
proprietary_codecs && !is_android && !is_ios && !(is_win && !is_clang)
|
||||
|
||||
# Use system OpenH264
|
||||
rtc_system_openh264 = false
|
||||
|
||||
# Enable to use H265
|
||||
if (build_with_chromium) {
|
||||
rtc_use_h265 = enable_hevc_parser_and_hw_decoder
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user