Commit 4eff9743 authored by Aurelien Jacobs's avatar Aurelien Jacobs

matroskadec: simplify flag default

Originally committed as revision 14550 to svn://svn.ffmpeg.org/ffmpeg/trunk
parent ead30062
......@@ -189,15 +189,6 @@ typedef enum {
MATROSKA_TRACK_ENCODING_COMP_HEADERSTRIP = 3,
} MatroskaTrackEncodingCompAlgo;
/*
* These aren't in any way "matroska-form" things,
* it's just something I use in the muxer/demuxer.
*/
typedef enum {
MATROSKA_TRACK_DEFAULT = (1<<1),
} MatroskaTrackFlags;
/*
* Matroska Codec IDs. Strings.
*/
......
......@@ -63,7 +63,7 @@ typedef struct Track {
double time_scale;
uint64_t default_duration;
MatroskaTrackFlags flags;
uint64_t flag_default;
int encoding_scope;
MatroskaTrackEncodingCompAlgo encoding_algo;
......@@ -1393,10 +1393,7 @@ matroska_add_stream (MatroskaDemuxContext *matroska)
uint64_t num;
if ((res = ebml_read_uint(matroska, &id, &num)) < 0)
break;
if (num)
track->flags |= MATROSKA_TRACK_DEFAULT;
else
track->flags &= ~MATROSKA_TRACK_DEFAULT;
track->flag_default = num;
break;
}
......@@ -2640,7 +2637,7 @@ matroska_read_header (AVFormatContext *s,
if (strcmp(track->language, "und"))
av_strlcpy(st->language, track->language, 4);
if (track->flags & MATROSKA_TRACK_DEFAULT)
if (track->flag_default)
st->disposition |= AV_DISPOSITION_DEFAULT;
if (track->default_duration)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment