mirror of
https://github.com/xenia-project/FFmpeg.git
synced 2025-01-19 10:13:13 +00:00
matroska: expand useless define for MS compat codec id strings
Originally committed as revision 14607 to svn://svn.ffmpeg.org/ffmpeg/trunk
This commit is contained in:
parent
20fb02c5b9
commit
cc8be50637
@ -203,9 +203,6 @@ typedef struct CodecMime{
|
|||||||
enum CodecID id;
|
enum CodecID id;
|
||||||
}CodecMime;
|
}CodecMime;
|
||||||
|
|
||||||
#define MATROSKA_CODEC_ID_VIDEO_VFW_FOURCC "V_MS/VFW/FOURCC"
|
|
||||||
#define MATROSKA_CODEC_ID_AUDIO_ACM "A_MS/ACM"
|
|
||||||
|
|
||||||
/* max. depth in the EBML tree structure */
|
/* max. depth in the EBML tree structure */
|
||||||
#define EBML_MAX_DEPTH 16
|
#define EBML_MAX_DEPTH 16
|
||||||
|
|
||||||
|
@ -1138,12 +1138,12 @@ static int matroska_read_header(AVFormatContext *s, AVFormatParameters *ap)
|
|||||||
if (st == NULL)
|
if (st == NULL)
|
||||||
return AVERROR(ENOMEM);
|
return AVERROR(ENOMEM);
|
||||||
|
|
||||||
if (!strcmp(track->codec_id, MATROSKA_CODEC_ID_VIDEO_VFW_FOURCC)
|
if (!strcmp(track->codec_id, "V_MS/VFW/FOURCC")
|
||||||
&& track->codec_priv.size >= 40
|
&& track->codec_priv.size >= 40
|
||||||
&& track->codec_priv.data != NULL) {
|
&& track->codec_priv.data != NULL) {
|
||||||
track->video.fourcc = AV_RL32(track->codec_priv.data + 16);
|
track->video.fourcc = AV_RL32(track->codec_priv.data + 16);
|
||||||
codec_id = codec_get_id(codec_bmp_tags, track->video.fourcc);
|
codec_id = codec_get_id(codec_bmp_tags, track->video.fourcc);
|
||||||
} else if (!strcmp(track->codec_id, MATROSKA_CODEC_ID_AUDIO_ACM)
|
} else if (!strcmp(track->codec_id, "A_MS/ACM")
|
||||||
&& track->codec_priv.size >= 18
|
&& track->codec_priv.size >= 18
|
||||||
&& track->codec_priv.data != NULL) {
|
&& track->codec_priv.data != NULL) {
|
||||||
uint16_t tag = AV_RL16(track->codec_priv.data);
|
uint16_t tag = AV_RL16(track->codec_priv.data);
|
||||||
|
@ -587,7 +587,7 @@ static int mkv_write_tracks(AVFormatContext *s)
|
|||||||
put_ebml_string(pb, MATROSKA_ID_CODECID, "V_QUICKTIME");
|
put_ebml_string(pb, MATROSKA_ID_CODECID, "V_QUICKTIME");
|
||||||
else if (!native_id)
|
else if (!native_id)
|
||||||
// if there is no mkv-specific codec ID, use VFW mode
|
// if there is no mkv-specific codec ID, use VFW mode
|
||||||
put_ebml_string(pb, MATROSKA_ID_CODECID, MATROSKA_CODEC_ID_VIDEO_VFW_FOURCC);
|
put_ebml_string(pb, MATROSKA_ID_CODECID, "V_MS/VFW/FOURCC");
|
||||||
|
|
||||||
subinfo = start_ebml_master(pb, MATROSKA_ID_TRACKVIDEO, 0);
|
subinfo = start_ebml_master(pb, MATROSKA_ID_TRACKVIDEO, 0);
|
||||||
// XXX: interlace flag?
|
// XXX: interlace flag?
|
||||||
@ -607,7 +607,7 @@ static int mkv_write_tracks(AVFormatContext *s)
|
|||||||
|
|
||||||
if (!native_id)
|
if (!native_id)
|
||||||
// no mkv-specific ID, use ACM mode
|
// no mkv-specific ID, use ACM mode
|
||||||
put_ebml_string(pb, MATROSKA_ID_CODECID, MATROSKA_CODEC_ID_AUDIO_ACM);
|
put_ebml_string(pb, MATROSKA_ID_CODECID, "A_MS/ACM");
|
||||||
|
|
||||||
subinfo = start_ebml_master(pb, MATROSKA_ID_TRACKAUDIO, 0);
|
subinfo = start_ebml_master(pb, MATROSKA_ID_TRACKAUDIO, 0);
|
||||||
put_ebml_uint (pb, MATROSKA_ID_AUDIOCHANNELS , codec->channels);
|
put_ebml_uint (pb, MATROSKA_ID_AUDIOCHANNELS , codec->channels);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user