1
0
mirror of https://github.com/FFmpeg/FFmpeg.git synced 2025-06-20 06:16:02 +02:00

avcodec/defs: Add AV_PROFILE_* defines, deprecate FF_PROFILE_* defines

These defines are also used in other contexts than just AVCodecContext
ones, e.g. in libavformat. Furthermore, given that these defines are
public, the AV-prefix is the right one, so deprecate (and not just move)
the FF-macros.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
This commit is contained in:
Andreas Rheinhardt
2023-09-02 14:57:41 +02:00
parent 0c6e5f321b
commit 8238bc0b5e
93 changed files with 879 additions and 727 deletions

View File

@ -228,7 +228,7 @@ static int dca_parse_params(DCAParseContext *pc1, const uint8_t *buf,
*sample_rate = ff_dca_sampling_freqs[pc1->sr_code];
*duration = 1024 << ff_dca_freq_ranges[pc1->sr_code];
*profile = FF_PROFILE_DTS_EXPRESS;
*profile = AV_PROFILE_DTS_EXPRESS;
return 0;
}
@ -253,7 +253,7 @@ static int dca_parse_params(DCAParseContext *pc1, const uint8_t *buf,
*sample_rate = asset->max_sample_rate;
*duration = (1 + (*sample_rate > 96000)) << nsamples_log2;
*profile = FF_PROFILE_DTS_HD_MA;
*profile = AV_PROFILE_DTS_HD_MA;
return 0;
}
@ -268,18 +268,18 @@ static int dca_parse_params(DCAParseContext *pc1, const uint8_t *buf,
*duration = h.npcmblocks * DCA_PCMBLOCK_SAMPLES;
*sample_rate = ff_dca_sample_rates[h.sr_code];
if (*profile != FF_PROFILE_UNKNOWN)
if (*profile != AV_PROFILE_UNKNOWN)
return 0;
*profile = FF_PROFILE_DTS;
*profile = AV_PROFILE_DTS;
if (h.ext_audio_present) {
switch (h.ext_audio_type) {
case DCA_EXT_AUDIO_XCH:
case DCA_EXT_AUDIO_XXCH:
*profile = FF_PROFILE_DTS_ES;
*profile = AV_PROFILE_DTS_ES;
break;
case DCA_EXT_AUDIO_X96:
*profile = FF_PROFILE_DTS_96_24;
*profile = AV_PROFILE_DTS_96_24;
break;
}
}
@ -296,9 +296,9 @@ static int dca_parse_params(DCAParseContext *pc1, const uint8_t *buf,
return 0;
if (asset->extension_mask & DCA_EXSS_XLL)
*profile = FF_PROFILE_DTS_HD_MA;
*profile = AV_PROFILE_DTS_HD_MA;
else if (asset->extension_mask & (DCA_EXSS_XBR | DCA_EXSS_XXCH | DCA_EXSS_X96))
*profile = FF_PROFILE_DTS_HD_HRA;
*profile = AV_PROFILE_DTS_HD_HRA;
return 0;
}