summaryrefslogtreecommitdiffstats
path: root/libhb/muxmkv.c
diff options
context:
space:
mode:
authorjstebbins <[email protected]>2009-04-18 18:44:01 +0000
committerjstebbins <[email protected]>2009-04-18 18:44:01 +0000
commitf090626988119eef202bfa9eddae7f92d99f3967 (patch)
tree06fd13bf5a2b98ef966db3ce9a778aac494e2b98 /libhb/muxmkv.c
parent2776908045cff478bc3d3269978c9c193be8bc1d (diff)
Enable DTS passthru for matroska container
since we have no way to create silent dts frames for insertion to maintain sync, frames from other streams may be dropped when there is a sync problem on the DTS stream git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@2339 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'libhb/muxmkv.c')
-rw-r--r--libhb/muxmkv.c15
1 files changed, 14 insertions, 1 deletions
diff --git a/libhb/muxmkv.c b/libhb/muxmkv.c
index 83a7daa45..fa9241fe6 100644
--- a/libhb/muxmkv.c
+++ b/libhb/muxmkv.c
@@ -165,6 +165,11 @@ static int MKVInit( hb_mux_object_t * m )
switch (audio->config.out.codec)
{
+ case HB_ACODEC_DCA:
+ track->codecPrivate = NULL;
+ track->codecPrivateSize = 0;
+ track->codecID = MK_ACODEC_DTS;
+ break;
case HB_ACODEC_AC3:
track->codecPrivate = NULL;
track->codecPrivateSize = 0;
@@ -221,7 +226,15 @@ static int MKVInit( hb_mux_object_t * m )
track->trackType = MK_TRACK_AUDIO;
track->language = audio->config.lang.iso639_2;
track->extra.audio.samplingFreq = (float)audio->config.out.samplerate;
- track->extra.audio.channels = (audio->config.out.codec == HB_ACODEC_AC3 ) ? HB_INPUT_CH_LAYOUT_GET_DISCRETE_COUNT(audio->config.in.channel_layout) : HB_AMIXDOWN_GET_DISCRETE_CHANNEL_COUNT(audio->config.out.mixdown);
+ if (audio->config.out.codec == HB_ACODEC_AC3 ||
+ audio->config.out.codec == HB_ACODEC_DCA)
+ {
+ track->extra.audio.channels = HB_INPUT_CH_LAYOUT_GET_DISCRETE_COUNT(audio->config.in.channel_layout);
+ }
+ else
+ {
+ track->extra.audio.channels = HB_AMIXDOWN_GET_DISCRETE_CHANNEL_COUNT(audio->config.out.mixdown);
+ }
// track->defaultDuration = job->arate * 1000;
mux_data->track = mk_createTrack(m->file, track);
if (audio->config.out.codec == HB_ACODEC_VORBIS && track->codecPrivate != NULL)