summaryrefslogtreecommitdiffstats
path: root/win/CS/Controls
diff options
context:
space:
mode:
authorsr55 <[email protected]>2011-04-18 20:47:02 +0000
committersr55 <[email protected]>2011-04-18 20:47:02 +0000
commitd0d06731c765a1a4c43558639405533d2af088b7 (patch)
treeb1becf16be4d6ff51300ca36a6191679b04503ca /win/CS/Controls
parente63f490b2e0a90bafb690e1d1f1f1e2f44729309 (diff)
WinGui:
- added mpeg2 option to the encoders list. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@3938 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'win/CS/Controls')
-rw-r--r--win/CS/Controls/AudioPanel.cs27
1 files changed, 27 insertions, 0 deletions
diff --git a/win/CS/Controls/AudioPanel.cs b/win/CS/Controls/AudioPanel.cs
index 471ac9d2f..5e6341641 100644
--- a/win/CS/Controls/AudioPanel.cs
+++ b/win/CS/Controls/AudioPanel.cs
@@ -8,6 +8,7 @@ namespace Handbrake.Controls
using System;
using System.Collections.Generic;
using System.ComponentModel;
+ using System.Drawing;
using System.Linq;
using System.Windows.Forms;
@@ -76,6 +77,32 @@ namespace Handbrake.Controls
}
}
+ /// <summary>
+ /// Gets the Estimated Bitrate for Tracks and Passthru Tracks
+ /// Returns a Size object (Encoded Tracks, Passthru Trask)
+ /// </summary>
+ public Size EstimatedBitrate
+ {
+ get
+ {
+ int encodedTracks = 0;
+ int passthruTracks = 0;
+ foreach (AudioTrack track in this.AudioTracks)
+ {
+ if (track.Encoder == AudioEncoder.Ac3Passthrough || track.Encoder == AudioEncoder.DtsPassthrough)
+ {
+ passthruTracks += track.ScannedTrack.Bitrate;
+ }
+ else
+ {
+ encodedTracks += track.Bitrate;
+ }
+ }
+
+ return new Size(encodedTracks, passthruTracks);
+ }
+ }
+
#endregion
#region Public Methods