diff options
author | sr55 <[email protected]> | 2014-12-26 22:00:54 +0000 |
---|---|---|
committer | sr55 <[email protected]> | 2014-12-26 22:00:54 +0000 |
commit | c98c0a9cca5953e12d17d17f8c1ea6afc55b4386 (patch) | |
tree | 9c4c8b0b0e18ecd07e1b4333d4db01ef352fbc96 /win | |
parent | 4bde18f29b47ca39da7fba416c3c912d7c46ad2c (diff) |
[Merge] Picture Size and PList Import bug fixes
git-svn-id: svn://svn.handbrake.fr/HandBrake/branches/0.10.x@6653 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'win')
-rw-r--r-- | win/CS/HandBrake.ApplicationServices/Utilities/PlistUtility.cs | 4 | ||||
-rw-r--r-- | win/CS/HandBrakeWPF/Helpers/PictureSize.cs | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/win/CS/HandBrake.ApplicationServices/Utilities/PlistUtility.cs b/win/CS/HandBrake.ApplicationServices/Utilities/PlistUtility.cs index 9f3ba9991..1b01669c0 100644 --- a/win/CS/HandBrake.ApplicationServices/Utilities/PlistUtility.cs +++ b/win/CS/HandBrake.ApplicationServices/Utilities/PlistUtility.cs @@ -167,7 +167,7 @@ namespace HandBrake.ApplicationServices.Utilities AddEncodeElement(xmlWriter, "PictureDetelecineCustom", "string", parsed.Detelecine == Detelecine.Custom ? parsed.CustomDecomb : string.Empty);
// Picture Settings
- AddEncodeElement(xmlWriter, "PictureHeight", "integer", parsed.Height.ToString());
+ AddEncodeElement(xmlWriter, "PictureHeight", "integer", parsed.MaxHeight.HasValue ? parsed.MaxHeight.Value.ToString() : parsed.Height.HasValue ? parsed.Height.Value.ToString() : "0");
AddEncodeElement(xmlWriter, "PictureKeepRatio", "integer", parsed.KeepDisplayAspect ? "1" : "0");
AddEncodeElement(xmlWriter, "PictureModulus", "integer", parsed.Modulus.ToString());
AddEncodeElement(xmlWriter, "PicturePAR", "integer", ((int)parsed.Anamorphic).ToString());
@@ -175,7 +175,7 @@ namespace HandBrake.ApplicationServices.Utilities AddEncodeElement(xmlWriter, "PictureRightCrop", "integer", parsed.Cropping.Right.ToString());
AddEncodeElement(xmlWriter, "PictureTopCrop", "integer", parsed.Cropping.Top.ToString());
AddEncodeElement(xmlWriter, "PictureBottomCrop", "integer", parsed.Cropping.Bottom.ToString());
- AddEncodeElement(xmlWriter, "PictureWidth", "integer", parsed.Width.ToString());
+ AddEncodeElement(xmlWriter, "PictureWidth", "integer", parsed.MaxWidth.HasValue ? parsed.MaxWidth.Value.ToString() : parsed.Width.HasValue ? parsed.Width.Value.ToString() : "0");
// Preset Information
AddEncodeElement(xmlWriter, "PresetBuildNumber", "string", build);
diff --git a/win/CS/HandBrakeWPF/Helpers/PictureSize.cs b/win/CS/HandBrakeWPF/Helpers/PictureSize.cs index f790c5a15..9e268b76c 100644 --- a/win/CS/HandBrakeWPF/Helpers/PictureSize.cs +++ b/win/CS/HandBrakeWPF/Helpers/PictureSize.cs @@ -212,8 +212,8 @@ namespace HandBrakeWPF.Helpers outputWidth = result.width;
outputHeight = result.height;
- outputParWidth = result.par.den;
- outputParHeight = result.par.num;
+ outputParWidth = result.par.num;
+ outputParHeight = result.par.den;
Debug.WriteLine("hb_set_anamorphic_size2: {0}x{1}", outputWidth, outputHeight);
return new AnamorphicResult { OutputWidth = outputWidth, OutputHeight = outputHeight, OutputParWidth = outputParWidth, OutputParHeight = outputParHeight };
}
|