mirror of
https://gitee.com/openharmony/third_party_ffmpeg
synced 2024-11-27 05:00:37 +00:00
Add EVRCA and SMV codec id
Demuxing files should be possible even if there are no decoding support in lavc (yet). Signed-off-by: Paul B Mahol <onemda@gmail.com>
This commit is contained in:
parent
6cff56f0ba
commit
2a89081cad
@ -447,6 +447,8 @@ enum AVCodecID {
|
||||
AV_CODEC_ID_PAF_AUDIO = MKBETAG('P','A','F','A'),
|
||||
AV_CODEC_ID_OPUS = MKBETAG('O','P','U','S'),
|
||||
AV_CODEC_ID_TAK = MKBETAG('t','B','a','K'),
|
||||
AV_CODEC_ID_EVRC = MKBETAG('s','e','v','c'),
|
||||
AV_CODEC_ID_SMV = MKBETAG('s','s','m','v'),
|
||||
|
||||
/* subtitle codecs */
|
||||
AV_CODEC_ID_FIRST_SUBTITLE = 0x17000, ///< A dummy ID pointing at the start of subtitle codecs.
|
||||
|
@ -2343,6 +2343,20 @@ static const AVCodecDescriptor codec_descriptors[] = {
|
||||
.long_name = NULL_IF_CONFIG_SMALL("TAK (Tom's lossless Audio Kompressor)"),
|
||||
.props = AV_CODEC_PROP_LOSSLESS,
|
||||
},
|
||||
{
|
||||
.id = AV_CODEC_ID_EVRC,
|
||||
.type = AVMEDIA_TYPE_AUDIO,
|
||||
.name = "evrc",
|
||||
.long_name = NULL_IF_CONFIG_SMALL("EVRC (Enhanced Variable Rate Codec)"),
|
||||
.props = AV_CODEC_PROP_LOSSY,
|
||||
},
|
||||
{
|
||||
.id = AV_CODEC_ID_SMV,
|
||||
.type = AVMEDIA_TYPE_AUDIO,
|
||||
.name = "smv",
|
||||
.long_name = NULL_IF_CONFIG_SMALL("SMV (Selectable Mode Vocoder)"),
|
||||
.props = AV_CODEC_PROP_LOSSY,
|
||||
},
|
||||
|
||||
/* subtitle codecs */
|
||||
{
|
||||
|
@ -294,6 +294,8 @@ const AVCodecTag ff_codec_movaudio_tags[] = {
|
||||
{ AV_CODEC_ID_QDMC, MKTAG('Q', 'D', 'M', 'C') },
|
||||
{ AV_CODEC_ID_SPEEX, MKTAG('s', 'p', 'e', 'x') }, /* Flash Media Server */
|
||||
{ AV_CODEC_ID_WMAV2, MKTAG('W', 'M', 'A', '2') },
|
||||
{ AV_CODEC_ID_EVRC, MKTAG('s', 'e', 'v', 'c') }, /* 3GPP2 */
|
||||
{ AV_CODEC_ID_SMV, MKTAG('s', 's', 'm', 'v') }, /* 3GPP2 */
|
||||
{ AV_CODEC_ID_NONE, 0 },
|
||||
};
|
||||
|
||||
|
@ -102,11 +102,9 @@ static int qcp_read_header(AVFormatContext *s)
|
||||
if (is_qcelp_13k_guid(buf)) {
|
||||
st->codec->codec_id = AV_CODEC_ID_QCELP;
|
||||
} else if (!memcmp(buf, guid_evrc, 16)) {
|
||||
av_log(s, AV_LOG_ERROR, "EVRC codec is not supported.\n");
|
||||
return AVERROR_PATCHWELCOME;
|
||||
st->codec->codec_id = AV_CODEC_ID_EVRC;
|
||||
} else if (!memcmp(buf, guid_smv, 16)) {
|
||||
av_log(s, AV_LOG_ERROR, "SMV codec is not supported.\n");
|
||||
return AVERROR_PATCHWELCOME;
|
||||
st->codec->codec_id = AV_CODEC_ID_SMV;
|
||||
} else {
|
||||
av_log(s, AV_LOG_ERROR, "Unknown codec GUID.\n");
|
||||
return AVERROR_INVALIDDATA;
|
||||
|
Loading…
Reference in New Issue
Block a user