diff options
author | Jan Ekström <jeebjp@gmail.com> | 2022-06-01 23:50:49 +0300 |
---|---|---|
committer | Jan Ekström <jeebjp@gmail.com> | 2022-06-12 21:05:59 +0300 |
commit | 1d15a5a059064216d97775181506b7f8432eb30d (patch) | |
tree | 800e351de568b30d14279489e5f5bb3609a94c5d /meson.build | |
parent | 602995fd40f03440f5fa64113b6188cb46ffcc9c (diff) | |
download | mpv-1d15a5a059064216d97775181506b7f8432eb30d.tar.bz2 mpv-1d15a5a059064216d97775181506b7f8432eb30d.tar.xz |
audio: add AVChannelLayout helpers to convert from/to mp_chmap
This is the new FFmpeg channel layout structure, which now
combines channel count and layout into a single location.
Only unspecified (channel count only) and native (channel layout
mask based) layouts are currently supported for the initial move
towards non-deprecated APIs.
Diffstat (limited to 'meson.build')
-rw-r--r-- | meson.build | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/meson.build b/meson.build index 0b07582a33..b8db70f923 100644 --- a/meson.build +++ b/meson.build @@ -15,9 +15,11 @@ build_root = meson.project_build_root() source_root = meson.project_source_root() python = find_program('python3') +avutil = dependency('libavutil', version: '>= 56.12.100') + ffmpeg = { 'name': 'ffmpeg', - 'deps': [dependency('libavutil', version: '>= 56.12.100'), + 'deps': [avutil, dependency('libavcodec', version: '>= 58.12.100'), dependency('libavformat', version: '>= 58.9.100'), dependency('libswscale', version: '>= 5.0.101'), @@ -595,6 +597,12 @@ endif # misc dependencies +av_ch_layout_available = avutil.version().version_compare('>= 57.24.100') +if av_ch_layout_available + features += 'av-channel-layout' + sources += files('audio/chmap_avchannel.c') +endif + cdda_opt = get_option('cdda').require( get_option('gpl'), error_message: 'the build is not GPL!', @@ -1696,6 +1704,7 @@ conf_data.set_quoted('FULLCONFIG', feature_str) conf_data.set10('HAVE_ALSA', alsa.found()) conf_data.set10('HAVE_ANDROID', android) conf_data.set10('HAVE_AUDIOUNIT', audiounit['use']) +conf_data.set10('HAVE_AV_CHANNEL_LAYOUT', av_ch_layout_available) conf_data.set10('HAVE_BSD_FSTATFS', bsd_fstatfs) conf_data.set10('HAVE_BSD_THREAD_NAME', bsd_thread_name) conf_data.set10('HAVE_CACA', caca.found()) |