@@ 169,13 169,17 @@ static void
trackinfo(Biobuf *o, Ebml *e)
{
char *t;
+ int rate;
+ rate = e->audio.outsamplerate;
+ if(rate == 0)
+ rate = e->audio.samplerate;
t = ebmltracktype(e->tracktype);
Bprint(o, "%d\t%s\t%s\t", e->tracknum, t, format(e));
if(e->tracktype == Etrackvideo)
Bprint(o, "%d\t%d", e->video.width, e->video.height);
else if(e->tracktype == Etrackaudio)
- Bprint(o, "%d\t%d", e->audio.channels, (int)e->audio.outsamplerate);
+ Bprint(o, "%d\t%d", e->audio.channels, rate);
else if(e->tracktype == Etracksubtitles)
Bprint(o, "%s", e->lang);
else
@@ 262,9 266,6 @@ matroskarun(Biobuf *f)
trackdump = e.tracknum;
else if(trackdump == Dumpaudio && e.tracktype == Etrackaudio)
trackdump = e.tracknum;
-
- if(e.tracktype == Etrackaudio && e.audio.outsamplerate == 0)
- e.audio.outsamplerate = e.audio.samplerate;
}
if(e.tracknum == trackdump)
memmove(&te, &e, sizeof(e));