diff options
author | jstebbins <[email protected]> | 2011-06-14 01:24:34 +0000 |
---|---|---|
committer | jstebbins <[email protected]> | 2011-06-14 01:24:34 +0000 |
commit | d4b5c3e9ea690220fb7e959aed0c68a2e73b0316 (patch) | |
tree | 824b35f6b87a1bab96de73f5bcb0eccf43a5e213 /macosx | |
parent | b3b9ef3add434b865c3deed92cb9e04a8703f389 (diff) |
Add DTS-HD passthru \o/
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4055 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'macosx')
-rw-r--r-- | macosx/HBAudio.m | 15 | ||||
-rw-r--r-- | macosx/HBAudioController.m | 2 |
2 files changed, 14 insertions, 3 deletions
diff --git a/macosx/HBAudio.m b/macosx/HBAudio.m index 194d4dd16..920cd13ae 100644 --- a/macosx/HBAudio.m +++ b/macosx/HBAudio.m @@ -135,6 +135,13 @@ static NSMutableArray *masterBitRateArray = nil; [NSNumber numberWithInt: HB_ACODEC_DCA], keyAudioMustMatchTrack, nil]]; [masterCodecArray addObject: [NSDictionary dictionaryWithObjectsAndKeys: + NSLocalizedString(@"DTS-HD Passthru", @"DTS-HD Passthru"), keyAudioCodecName, + [NSNumber numberWithInt: HB_ACODEC_DCA_HD_PASS], keyAudioCodec, + [NSNumber numberWithBool: NO], keyAudioMP4, + [NSNumber numberWithBool: YES], keyAudioMKV, + [NSNumber numberWithInt: HB_ACODEC_DCA_HD], keyAudioMustMatchTrack, + nil]]; + [masterCodecArray addObject: [NSDictionary dictionaryWithObjectsAndKeys: NSLocalizedString(@"Vorbis (vorbis)", @"Vorbis (vorbis)"), keyAudioCodecName, [NSNumber numberWithInt: HB_ACODEC_VORBIS], keyAudioCodec, [NSNumber numberWithBool: NO], keyAudioMP4, @@ -151,6 +158,10 @@ static NSMutableArray *masterBitRateArray = nil; NSLocalizedString(@"DTS Passthru", @"DTS Passthru"), keyAudioMixdownName, [NSNumber numberWithInt: HB_ACODEC_DCA_PASS], keyAudioMixdown, nil]]; + [masterMixdownArray addObject: [NSDictionary dictionaryWithObjectsAndKeys: + NSLocalizedString(@"DTS-HD Passthru", @"DTS-HD Passthru"), keyAudioMixdownName, + [NSNumber numberWithInt: HB_ACODEC_DCA_HD_PASS], keyAudioMixdown, + nil]]; for (i = 0; i < hb_audio_mixdowns_count; i++) { [masterMixdownArray addObject: [NSDictionary dictionaryWithObjectsAndKeys: @@ -639,7 +650,7 @@ static NSMutableArray *masterBitRateArray = nil; if (YES == retval) { int myMixdown = [[[self mixdown] objectForKey: keyAudioMixdown] intValue]; - if (HB_ACODEC_AC3_PASS == myMixdown || HB_ACODEC_DCA_PASS == myMixdown) + if (myMixdown & HB_ACODEC_PASS_FLAG) { retval = NO; } @@ -672,7 +683,7 @@ static NSMutableArray *masterBitRateArray = nil; if (YES == retval) { int myCodecCodec = [[[self codec] objectForKey: keyAudioCodec] intValue]; - if (HB_ACODEC_AC3_PASS == myCodecCodec || HB_ACODEC_DCA_PASS == myCodecCodec) + if (myCodecCodec & HB_ACODEC_PASS_FLAG) { retval = NO; } diff --git a/macosx/HBAudioController.m b/macosx/HBAudioController.m index b604fcc87..be7df4507 100644 --- a/macosx/HBAudioController.m +++ b/macosx/HBAudioController.m @@ -105,7 +105,7 @@ NSString *HBMixdownChangedNotification = @"HBMixdownChangedNotification"; [aDict setObject: [[anAudio bitRate] objectForKey: keyAudioBitrateName] forKey: [prefix stringByAppendingString: @"Bitrate"]]; // output is not passthru so apply gain - if (HB_ACODEC_AC3_PASS != [[[anAudio codec] objectForKey: keyAudioCodec] intValue] && HB_ACODEC_DCA_PASS != [[[anAudio codec] objectForKey: keyAudioCodec] intValue]) + if (!([[[anAudio codec] objectForKey: keyAudioCodec] intValue] & HB_ACODEC_PASS_FLAG)) { [aDict setObject: [anAudio gain] forKey: [prefix stringByAppendingString: @"TrackGainSlider"]]; } |