diff options
author | sr55 <[email protected]> | 2010-04-09 20:08:54 +0000 |
---|---|---|
committer | sr55 <[email protected]> | 2010-04-09 20:08:54 +0000 |
commit | 34d7b7d5daef1d22ab8061ebb46fea5a27a4c8fd (patch) | |
tree | 634ff18aa873df81fde8605925cc3121be63fda9 /win | |
parent | 308a8ae86210c5d680a01fc4e0336af41ef479c4 (diff) |
WinGui:
- Fix a few small issues with custom anamorphic preset loading. Thanks golgol7777
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@3216 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'win')
-rw-r--r-- | win/C#/Functions/PresetLoader.cs | 2 | ||||
-rw-r--r-- | win/C#/Functions/QueryParser.cs | 4 | ||||
-rw-r--r-- | win/C#/frmMain.cs | 23 |
3 files changed, 6 insertions, 23 deletions
diff --git a/win/C#/Functions/PresetLoader.cs b/win/C#/Functions/PresetLoader.cs index e9fd7ba9d..cab771ab1 100644 --- a/win/C#/Functions/PresetLoader.cs +++ b/win/C#/Functions/PresetLoader.cs @@ -143,7 +143,7 @@ namespace Handbrake.Functions mainWindow.PictureSettings.updownDisplayWidth.Text = presetQuery.DisplayWidthValue.ToString();
mainWindow.PictureSettings.updownParHeight.Text = presetQuery.PixelAspectWidth.ToString();
mainWindow.PictureSettings.updownParWidth.Text = presetQuery.PixelAspectHeight.ToString();
- mainWindow.PictureSettings.drp_modulus.SelectedItem = presetQuery.AnamorphicModulus;
+ mainWindow.PictureSettings.drp_modulus.SelectedItem = presetQuery.AnamorphicModulus.ToString();
#endregion
diff --git a/win/C#/Functions/QueryParser.cs b/win/C#/Functions/QueryParser.cs index 95b153aa3..4e864227e 100644 --- a/win/C#/Functions/QueryParser.cs +++ b/win/C#/Functions/QueryParser.cs @@ -126,9 +126,9 @@ namespace Handbrake.Functions Match customAnamorphic = Regex.Match(input, @"--custom-anamorphic");
Match keepDisplayAsect = Regex.Match(input, @"--keep-display-aspect");
- Match displayWidth = Regex.Match(input, @"--display-width ([0-9*])");
+ Match displayWidth = Regex.Match(input, @"--display-width ([0-9]*)");
Match pixelAspect = Regex.Match(input, @"--pixel-aspect ([0-9]*):([0-9]*)");
- Match modulus = Regex.Match(input, @"--modulus ([0-9*])");
+ Match modulus = Regex.Match(input, @"--modulus ([0-9]*)");
// Picture Settings - Filters
Match decomb = Regex.Match(input, @" --decomb");
diff --git a/win/C#/frmMain.cs b/win/C#/frmMain.cs index 7baa1fcf8..a369543a1 100644 --- a/win/C#/frmMain.cs +++ b/win/C#/frmMain.cs @@ -1324,8 +1324,7 @@ namespace Handbrake break;
case 2:
if (
- !Path.GetExtension(DVD_Save.FileName).Equals(".mkv",
- StringComparison.InvariantCultureIgnoreCase))
+ !Path.GetExtension(DVD_Save.FileName).Equals(".mkv", StringComparison.InvariantCultureIgnoreCase))
DVD_Save.FileName = DVD_Save.FileName.Replace(".mp4", ".mkv").Replace(".m4v", ".mkv");
break;
default:
@@ -1434,6 +1433,7 @@ namespace Handbrake slider_videoQuality.Minimum = 0;
slider_videoQuality.TickFrequency = 1;
+ CultureInfo culture = CultureInfo.CreateSpecificCulture("en-US");
double cqStep = Properties.Settings.Default.x264cqstep;
double multiplier = 1.0 / cqStep;
double value = slider_videoQuality.Value * multiplier;
@@ -1487,24 +1487,7 @@ namespace Handbrake double rfValue = 51.0 - slider_videoQuality.Value * cqStep;
// Change the maximum value for the slider
- switch (Properties.Settings.Default.x264cqstep.ToString(new CultureInfo("en-US")))
- {
- case "0.2":
- slider_videoQuality.Maximum = 255;
- break;
- case "0.25":
- slider_videoQuality.Maximum = 204;
- break;
- case "0.5":
- slider_videoQuality.Maximum = 102;
- break;
- case "1":
- slider_videoQuality.Maximum = 51;
- break;
- default:
- slider_videoQuality.Maximum = 51;
- break;
- }
+ slider_videoQuality.Maximum = (int)(51 / Properties.Settings.Default.x264cqstep);
// Reset the CQ slider to RF0
slider_videoQuality.Value = slider_videoQuality.Maximum;
|