diff options
Diffstat (limited to 'win')
-rw-r--r-- | win/C#/Functions/PresetLoader.cs | 6 | ||||
-rw-r--r-- | win/C#/Functions/QueryGenerator.cs | 3 | ||||
-rw-r--r-- | win/C#/HandBrake.ApplicationServices/Model/EncodeTask.cs | 5 | ||||
-rw-r--r-- | win/C#/HandBrake.ApplicationServices/Utilities/PlistUtility.cs | 10 | ||||
-rw-r--r-- | win/C#/HandBrake.ApplicationServices/Utilities/QueryParserUtility.cs | 7 | ||||
-rw-r--r-- | win/C#/frmMain.Designer.cs | 39 | ||||
-rw-r--r-- | win/C#/frmMain.cs | 13 |
7 files changed, 8 insertions, 75 deletions
diff --git a/win/C#/Functions/PresetLoader.cs b/win/C#/Functions/PresetLoader.cs index 64e153e16..342eb5e5d 100644 --- a/win/C#/Functions/PresetLoader.cs +++ b/win/C#/Functions/PresetLoader.cs @@ -203,12 +203,6 @@ namespace Handbrake.Functions mainWindow.text_bitrate.Text = presetQuery.VideoBitrate.ToString();
}
- if (presetQuery.TargetSize != null)
- {
- mainWindow.radio_targetFilesize.Checked = true;
- mainWindow.text_filesize.Text = presetQuery.TargetSize.ToString();
- }
-
// Quality
if (presetQuery.Quality != null)
{
diff --git a/win/C#/Functions/QueryGenerator.cs b/win/C#/Functions/QueryGenerator.cs index 4c65ca183..a91a058c2 100644 --- a/win/C#/Functions/QueryGenerator.cs +++ b/win/C#/Functions/QueryGenerator.cs @@ -307,9 +307,6 @@ namespace Handbrake.Functions if (mainWindow.radio_avgBitrate.Checked)
query += " -b " + mainWindow.text_bitrate.Text;
- if (mainWindow.radio_targetFilesize.Checked)
- query += " -S " + mainWindow.text_filesize.Text;
-
// Video Quality Setting
if (mainWindow.radio_cq.Checked)
{
diff --git a/win/C#/HandBrake.ApplicationServices/Model/EncodeTask.cs b/win/C#/HandBrake.ApplicationServices/Model/EncodeTask.cs index 8b561f496..c3a58ac40 100644 --- a/win/C#/HandBrake.ApplicationServices/Model/EncodeTask.cs +++ b/win/C#/HandBrake.ApplicationServices/Model/EncodeTask.cs @@ -224,11 +224,6 @@ namespace HandBrake.ApplicationServices.Model public double? Quality { get; set; }
/// <summary>
- /// Gets or sets TargetSize.
- /// </summary>
- public int? TargetSize { get; set; }
-
- /// <summary>
/// Gets or sets VideoBitrate.
/// </summary>
public int? VideoBitrate { get; set; }
diff --git a/win/C#/HandBrake.ApplicationServices/Utilities/PlistUtility.cs b/win/C#/HandBrake.ApplicationServices/Utilities/PlistUtility.cs index fc44b95d4..660bc905d 100644 --- a/win/C#/HandBrake.ApplicationServices/Utilities/PlistUtility.cs +++ b/win/C#/HandBrake.ApplicationServices/Utilities/PlistUtility.cs @@ -240,9 +240,6 @@ namespace HandBrake.ApplicationServices.Utilities case "VideoQualityType": // The Type of Quality Mode used
qualityMode = value;
break;
- case "VideoTargetSize":
- parsed.TargetSize = int.Parse(value);
- break;
case "VideoTurboTwoPass":
parsed.TurboFirstPass = value == "1";
break;
@@ -294,11 +291,9 @@ namespace HandBrake.ApplicationServices.Utilities break;
case "1": // Avg Bitrate
parsed.Quality = null;
- parsed.TargetSize = null;
break;
case "2": // CQ
parsed.VideoBitrate = null;
- parsed.TargetSize = null;
break;
}
#endregion
@@ -544,12 +539,11 @@ namespace HandBrake.ApplicationServices.Utilities AddEncodeElement(xmlWriter, "VideoQualitySlider", "real", parsed.Quality.ToString());
int videoQualityType = 0;
- if (parsed.TargetSize != null) videoQualityType = 0;
- else if (parsed.VideoBitrate != null) videoQualityType = 1;
+ if (parsed.VideoBitrate != null) videoQualityType = 1;
else if (parsed.Quality != null) videoQualityType = 2;
AddEncodeElement(xmlWriter, "VideoQualityType", "integer", videoQualityType.ToString());
- AddEncodeElement(xmlWriter, "VideoTargetSize", "string", parsed.TargetSize.ToString());
+ AddEncodeElement(xmlWriter, "VideoTargetSize", "string", string.Empty);
AddEncodeElement(xmlWriter, "VideoTurboTwoPass", "integer", parsed.TurboFirstPass ? "1" : "0");
AddEncodeElement(xmlWriter, "VideoTwoPass", "integer", parsed.TwoPass ? "1" : "0");
diff --git a/win/C#/HandBrake.ApplicationServices/Utilities/QueryParserUtility.cs b/win/C#/HandBrake.ApplicationServices/Utilities/QueryParserUtility.cs index 3fb6a0e18..938eadc0f 100644 --- a/win/C#/HandBrake.ApplicationServices/Utilities/QueryParserUtility.cs +++ b/win/C#/HandBrake.ApplicationServices/Utilities/QueryParserUtility.cs @@ -83,7 +83,6 @@ namespace HandBrake.ApplicationServices.Utilities Match videoFramerate = Regex.Match(input, @"-r ([0-9.]*)");
Match videoBitrate = Regex.Match(input, @"-b ([0-9]*)");
Match videoQuality = Regex.Match(input, @"-q ([0-9.]*)");
- Match videoFilesize = Regex.Match(input, @"-S ([0-9.]*)");
Match twoPass = Regex.Match(input, @" -2");
Match turboFirstPass = Regex.Match(input, @" -T");
Match optimizeMP4 = Regex.Match(input, @" -O");
@@ -314,12 +313,6 @@ namespace HandBrake.ApplicationServices.Utilities parsed.VideoBitrate = int.Parse(videoBitrate.ToString().Replace("-b ", string.Empty));
}
- if (videoFilesize.Success)
- {
- parsed.VideoEncodeRateType = VideoEncodeRateMode.TargetSize;
- parsed.TargetSize = int.Parse(videoBitrate.ToString().Replace("-S ", string.Empty));
- }
-
if (videoQuality.Success)
{
float quality = float.Parse(videoQuality.ToString().Replace("-q ", string.Empty), Culture);
diff --git a/win/C#/frmMain.Designer.cs b/win/C#/frmMain.Designer.cs index 5476787d8..91f9fa010 100644 --- a/win/C#/frmMain.Designer.cs +++ b/win/C#/frmMain.Designer.cs @@ -49,7 +49,6 @@ namespace Handbrake this.check_turbo = new System.Windows.Forms.CheckBox();
this.drp_videoFramerate = new System.Windows.Forms.ComboBox();
this.slider_videoQuality = new System.Windows.Forms.TrackBar();
- this.text_filesize = new System.Windows.Forms.TextBox();
this.text_bitrate = new System.Windows.Forms.TextBox();
this.btn_setDefault = new System.Windows.Forms.Button();
this.check_optimiseMP4 = new System.Windows.Forms.CheckBox();
@@ -118,7 +117,6 @@ namespace Handbrake this.checkMaximumFramerate = new System.Windows.Forms.CheckBox();
this.radio_cq = new System.Windows.Forms.RadioButton();
this.radio_avgBitrate = new System.Windows.Forms.RadioButton();
- this.radio_targetFilesize = new System.Windows.Forms.RadioButton();
this.label25 = new System.Windows.Forms.Label();
this.check_2PassEncode = new System.Windows.Forms.CheckBox();
this.Label2 = new System.Windows.Forms.Label();
@@ -315,7 +313,7 @@ namespace Handbrake //
this.slider_videoQuality.BackColor = System.Drawing.SystemColors.Window;
this.slider_videoQuality.Enabled = false;
- this.slider_videoQuality.Location = new System.Drawing.Point(376, 120);
+ this.slider_videoQuality.Location = new System.Drawing.Point(376, 90);
this.slider_videoQuality.Margin = new System.Windows.Forms.Padding(0);
this.slider_videoQuality.Maximum = 100;
this.slider_videoQuality.Name = "slider_videoQuality";
@@ -325,18 +323,9 @@ namespace Handbrake this.ToolTip.SetToolTip(this.slider_videoQuality, "Set the quality level of the video. ");
this.slider_videoQuality.ValueChanged += new System.EventHandler(this.slider_videoQuality_Scroll);
//
- // text_filesize
- //
- this.text_filesize.Enabled = false;
- this.text_filesize.Location = new System.Drawing.Point(511, 36);
- this.text_filesize.Name = "text_filesize";
- this.text_filesize.Size = new System.Drawing.Size(81, 21);
- this.text_filesize.TabIndex = 12;
- this.ToolTip.SetToolTip(this.text_filesize, "Set the file size you wish the encoded file to be.");
- //
// text_bitrate
//
- this.text_bitrate.Location = new System.Drawing.Point(511, 63);
+ this.text_bitrate.Location = new System.Drawing.Point(511, 33);
this.text_bitrate.Name = "text_bitrate";
this.text_bitrate.Size = new System.Drawing.Size(81, 21);
this.text_bitrate.TabIndex = 14;
@@ -961,14 +950,12 @@ namespace Handbrake this.tab_video.Controls.Add(this.drp_videoFramerate);
this.tab_video.Controls.Add(this.radio_cq);
this.tab_video.Controls.Add(this.radio_avgBitrate);
- this.tab_video.Controls.Add(this.radio_targetFilesize);
this.tab_video.Controls.Add(this.drp_videoEncoder);
this.tab_video.Controls.Add(this.Label47);
this.tab_video.Controls.Add(this.label25);
this.tab_video.Controls.Add(this.check_turbo);
this.tab_video.Controls.Add(this.check_2PassEncode);
this.tab_video.Controls.Add(this.Label2);
- this.tab_video.Controls.Add(this.text_filesize);
this.tab_video.Controls.Add(this.slider_videoQuality);
this.tab_video.Controls.Add(this.text_bitrate);
this.tab_video.Controls.Add(this.lbl_SliderValue);
@@ -986,7 +973,7 @@ namespace Handbrake this.lbl_rfwarn.AutoSize = true;
this.lbl_rfwarn.BackColor = System.Drawing.Color.Transparent;
this.lbl_rfwarn.ForeColor = System.Drawing.Color.Red;
- this.lbl_rfwarn.Location = new System.Drawing.Point(385, 165);
+ this.lbl_rfwarn.Location = new System.Drawing.Point(385, 135);
this.lbl_rfwarn.Name = "lbl_rfwarn";
this.lbl_rfwarn.Size = new System.Drawing.Size(321, 39);
this.lbl_rfwarn.TabIndex = 0;
@@ -1009,7 +996,7 @@ namespace Handbrake //
this.radio_cq.AutoSize = true;
this.radio_cq.BackColor = System.Drawing.Color.Transparent;
- this.radio_cq.Location = new System.Drawing.Point(365, 97);
+ this.radio_cq.Location = new System.Drawing.Point(365, 67);
this.radio_cq.Name = "radio_cq";
this.radio_cq.Size = new System.Drawing.Size(105, 17);
this.radio_cq.TabIndex = 3;
@@ -1022,7 +1009,7 @@ namespace Handbrake this.radio_avgBitrate.AutoSize = true;
this.radio_avgBitrate.BackColor = System.Drawing.Color.Transparent;
this.radio_avgBitrate.Checked = true;
- this.radio_avgBitrate.Location = new System.Drawing.Point(365, 64);
+ this.radio_avgBitrate.Location = new System.Drawing.Point(365, 34);
this.radio_avgBitrate.Name = "radio_avgBitrate";
this.radio_avgBitrate.Size = new System.Drawing.Size(112, 17);
this.radio_avgBitrate.TabIndex = 4;
@@ -1031,18 +1018,6 @@ namespace Handbrake this.radio_avgBitrate.UseVisualStyleBackColor = false;
this.radio_avgBitrate.CheckedChanged += new System.EventHandler(this.radio_avgBitrate_CheckedChanged);
//
- // radio_targetFilesize
- //
- this.radio_targetFilesize.AutoSize = true;
- this.radio_targetFilesize.BackColor = System.Drawing.Color.Transparent;
- this.radio_targetFilesize.Location = new System.Drawing.Point(365, 37);
- this.radio_targetFilesize.Name = "radio_targetFilesize";
- this.radio_targetFilesize.Size = new System.Drawing.Size(107, 17);
- this.radio_targetFilesize.TabIndex = 5;
- this.radio_targetFilesize.Text = "Target Size (MB):";
- this.radio_targetFilesize.UseVisualStyleBackColor = false;
- this.radio_targetFilesize.CheckedChanged += new System.EventHandler(this.radio_targetFilesize_CheckedChanged);
- //
// label25
//
this.label25.AutoSize = true;
@@ -1082,7 +1057,7 @@ namespace Handbrake this.lbl_SliderValue.AutoSize = true;
this.lbl_SliderValue.BackColor = System.Drawing.Color.Transparent;
this.lbl_SliderValue.Font = new System.Drawing.Font("Tahoma", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
- this.lbl_SliderValue.Location = new System.Drawing.Point(509, 100);
+ this.lbl_SliderValue.Location = new System.Drawing.Point(509, 70);
this.lbl_SliderValue.Name = "lbl_SliderValue";
this.lbl_SliderValue.Size = new System.Drawing.Size(21, 13);
this.lbl_SliderValue.TabIndex = 15;
@@ -1825,7 +1800,6 @@ namespace Handbrake internal System.Windows.Forms.ComboBox drp_videoFramerate;
internal System.Windows.Forms.CheckBox check_2PassEncode;
internal System.Windows.Forms.TrackBar slider_videoQuality;
- internal System.Windows.Forms.TextBox text_filesize;
internal System.Windows.Forms.TextBox text_bitrate;
internal System.Windows.Forms.TabPage tab_picture;
internal System.Windows.Forms.CheckBox Check_ChapterMarkers;
@@ -1890,7 +1864,6 @@ namespace Handbrake private System.Windows.Forms.TabPage tab_filters;
internal System.Windows.Forms.RadioButton radio_cq;
internal System.Windows.Forms.RadioButton radio_avgBitrate;
- internal System.Windows.Forms.RadioButton radio_targetFilesize;
internal Handbrake.Controls.x264Panel x264Panel;
private System.Windows.Forms.ToolStripButton tb_preview;
private System.Diagnostics.Process hbproc;
diff --git a/win/C#/frmMain.cs b/win/C#/frmMain.cs index b9255ee48..d1b3476e8 100644 --- a/win/C#/frmMain.cs +++ b/win/C#/frmMain.cs @@ -271,7 +271,6 @@ namespace Handbrake drp_videoEncoder.SelectedIndexChanged += this.changePresetLabel;
check_2PassEncode.CheckedChanged += this.changePresetLabel;
check_turbo.CheckedChanged += this.changePresetLabel;
- text_filesize.TextChanged += this.changePresetLabel;
text_bitrate.TextChanged += this.changePresetLabel;
slider_videoQuality.ValueChanged += this.changePresetLabel;
@@ -300,7 +299,6 @@ namespace Handbrake drp_videoEncoder.SelectedIndexChanged -= this.changePresetLabel;
check_2PassEncode.CheckedChanged -= this.changePresetLabel;
check_turbo.CheckedChanged -= this.changePresetLabel;
- text_filesize.TextChanged -= this.changePresetLabel;
text_bitrate.TextChanged -= this.changePresetLabel;
slider_videoQuality.ValueChanged -= this.changePresetLabel;
@@ -2006,19 +2004,9 @@ namespace Handbrake }
}
- private void radio_targetFilesize_CheckedChanged(object sender, EventArgs e)
- {
- text_bitrate.Enabled = false;
- text_filesize.Enabled = true;
- slider_videoQuality.Enabled = false;
-
- check_2PassEncode.Enabled = true;
- }
-
private void radio_avgBitrate_CheckedChanged(object sender, EventArgs e)
{
text_bitrate.Enabled = true;
- text_filesize.Enabled = false;
slider_videoQuality.Enabled = false;
check_2PassEncode.Enabled = true;
@@ -2027,7 +2015,6 @@ namespace Handbrake private void radio_cq_CheckedChanged(object sender, EventArgs e)
{
text_bitrate.Enabled = false;
- text_filesize.Enabled = false;
slider_videoQuality.Enabled = true;
check_2PassEncode.Enabled = false;
|