2 using System.Drawing;
\r
3 using System.Globalization;
\r
4 using System.Windows.Forms;
\r
5 using Handbrake.Parsing;
\r
7 namespace Handbrake.Controls
\r
10 // - Tie in the cropping controls.
\r
12 public partial class PictureSettings : UserControl
\r
14 private static readonly CultureInfo Culture = new CultureInfo("en-US", false);
\r
17 public int maxWidth, maxHeight;
\r
18 int widthVal, heightVal;
\r
19 private double darValue;
\r
20 private double storageAspect; // Storage Aspect Cache for current source and title
\r
21 public Title selectedTitle { private get; set; }
\r
22 private Boolean heightChangeGuard;
\r
23 private Boolean looseAnamorphicHeightGuard;
\r
24 private Boolean heightModJumpGaurd;
\r
27 public PictureSettings()
\r
29 InitializeComponent();
\r
31 drop_modulus.SelectedIndex = 0;
\r
34 public void setComponentsAfterScan(Title st)
\r
38 // Set the Aspect Ratio
\r
39 lbl_Aspect.Text = selectedTitle.AspectRatio.ToString(Culture);
\r
40 lbl_src_res.Text = selectedTitle.Resolution.Width + " x " + selectedTitle.Resolution.Height;
\r
42 // Set the Recommended Cropping values
\r
43 crop_top.Text = selectedTitle.AutoCropDimensions[0].ToString();
\r
44 crop_bottom.Text = selectedTitle.AutoCropDimensions[1].ToString();
\r
45 crop_left.Text = selectedTitle.AutoCropDimensions[2].ToString();
\r
46 crop_right.Text = selectedTitle.AutoCropDimensions[3].ToString();
\r
49 // Set the Resolution Boxes
\r
50 text_width.Value = selectedTitle.Resolution.Width;
\r
52 if (drp_anamorphic.SelectedIndex == 0)
\r
53 text_height.Value = cacluateHeight(selectedTitle.Resolution.Width);
\r
54 else if (drp_anamorphic.SelectedIndex == 1 || drp_anamorphic.SelectedIndex == 3)
\r
56 heightModJumpGaurd = true;
\r
57 text_height.Value = selectedTitle.Resolution.Height - (int) crop_top.Value - (int) crop_bottom.Value;
\r
59 else if (drp_anamorphic.SelectedIndex == 2)
\r
61 heightModJumpGaurd = false;
\r
62 text_height.Value = selectedTitle.Resolution.Height - (int)crop_top.Value - (int)crop_bottom.Value;
\r
65 if (drp_anamorphic.SelectedIndex == 3)
\r
67 txt_parWidth.Text = selectedTitle.ParVal.Width.ToString();
\r
68 txt_parHeight.Text = selectedTitle.ParVal.Height.ToString();
\r
69 txt_displayWidth.Text = displayWidth().ToString();
\r
74 public void setMax()
\r
76 if (maxWidth != 0 && maxHeight != 0)
\r
77 lbl_max.Text = "Max Width / Height";
\r
78 else if (maxWidth != 0)
\r
79 lbl_max.Text = "Max Width";
\r
84 // Basic Picture Setting Controls
\r
85 private void text_width_ValueChanged(object sender, EventArgs e)
\r
92 int.TryParse(drop_modulus.SelectedItem.ToString(), out mod);
\r
94 // Increase or decrease value by the correct mod.
\r
95 text_width.Value = widthChangeMod(mod);
\r
98 switch (drp_anamorphic.SelectedIndex)
\r
101 if (calculateUnchangeValue(true) != -1 && check_KeepAR.Checked)
\r
102 text_height.Value = calculateUnchangeValue(true);
\r
105 lbl_anamorphic.Text = strictAnamorphic();
\r
108 lbl_anamorphic.Text = looseAnamorphic();
\r
111 customAnamorphic(text_width);
\r
116 private void text_height_ValueChanged(object sender, EventArgs e)
\r
123 int.TryParse(drop_modulus.SelectedItem.ToString(), out mod);
\r
125 // Increase or decrease value by the correct mod.
\r
126 if (drp_anamorphic.SelectedIndex != 2 && !heightModJumpGaurd)
\r
128 decimal val = heightChangeMod(mod);
\r
129 heightChangeGuard = true;
\r
130 if (text_height.Value != val)
\r
132 heightChangeGuard = false;
\r
133 text_height.Value = val;
\r
138 switch (drp_anamorphic.SelectedIndex)
\r
141 if (drp_anamorphic.SelectedIndex != 3)
\r
143 if (calculateUnchangeValue(false) != -1)
\r
144 text_width.Value = calculateUnchangeValue(false);
\r
148 lbl_anamorphic.Text = strictAnamorphic();
\r
151 if (!looseAnamorphicHeightGuard)
\r
152 lbl_anamorphic.Text = looseAnamorphic();
\r
155 if (!heightChangeGuard)
\r
156 customAnamorphic(text_height);
\r
159 heightChangeGuard = false;
\r
160 looseAnamorphicHeightGuard = false;
\r
161 heightModJumpGaurd = false;
\r
163 private void check_KeepAR_CheckedChanged(object sender, EventArgs e)
\r
165 // Recalculate Height based on width when enabled
\r
166 if (drp_anamorphic.SelectedIndex != 3 && check_KeepAR.Checked && selectedTitle != null)
\r
167 text_height.Value = cacluateHeight(widthVal);
\r
169 // Enable Par Width/Height Check boxes if Keep AR is enabled, otherwise disable them
\r
170 if (check_KeepAR.Checked)
\r
172 txt_parWidth.Enabled = false;
\r
173 txt_parHeight.Enabled = false;
\r
177 txt_parWidth.Enabled = true;
\r
178 txt_parHeight.Enabled = true;
\r
181 private void drp_anamorphic_SelectedIndexChanged(object sender, EventArgs e)
\r
183 switch (drp_anamorphic.SelectedIndex)
\r
186 text_height.Enabled = true;
\r
187 text_width.Enabled = true;
\r
188 check_KeepAR.CheckState = CheckState.Checked;
\r
189 check_KeepAR.Enabled = true;
\r
190 disableCustomAnaControls();
\r
191 if (selectedTitle != null)
\r
193 text_width.Value = selectedTitle.Resolution.Width;
\r
194 text_height.Value = selectedTitle.Resolution.Height;
\r
196 check_KeepAR.Enabled = true;
\r
197 lbl_anamorphic.Text = "";
\r
198 lbl_anamprohicLbl.Visible = false;
\r
201 if (selectedTitle != null)
\r
203 heightModJumpGaurd = true;
\r
204 text_width.Value = selectedTitle.Resolution.Width - (int)crop_left.Value - (int)crop_right.Value;
\r
205 text_height.Value = selectedTitle.Resolution.Height - (int)crop_top.Value - (int)crop_bottom.Value;
\r
207 text_height.Enabled = false;
\r
208 text_width.Enabled = false;
\r
209 check_KeepAR.CheckState = CheckState.Unchecked;
\r
210 check_KeepAR.Enabled = false;
\r
211 disableCustomAnaControls();
\r
212 lbl_anamorphic.Text = strictAnamorphic();
\r
213 lbl_anamprohicLbl.Visible = true;
\r
216 disableCustomAnaControls();
\r
218 text_height.Enabled = false;
\r
219 text_width.Enabled = true;
\r
220 if (selectedTitle != null)
\r
222 heightModJumpGaurd = true;
\r
223 text_width.Value = selectedTitle.Resolution.Width;
\r
224 text_height.Value = selectedTitle.Resolution.Height - (int) crop_top.Value - (int) crop_bottom.Value;
\r
226 lbl_anamorphic.Text = looseAnamorphic();
\r
227 lbl_anamprohicLbl.Visible = true;
\r
231 // Display Elements
\r
232 enableCustomAnaControls();
\r
233 text_height.Enabled = true;
\r
234 text_width.Enabled = true;
\r
237 if (selectedTitle != null)
\r
239 heightModJumpGaurd = true;
\r
240 widthVal = selectedTitle.Resolution.Width;
\r
241 text_width.Value = selectedTitle.Resolution.Width - (int)crop_left.Value - (int)crop_right.Value;
\r
242 text_height.Value = selectedTitle.Resolution.Height - (int)crop_top.Value - (int)crop_bottom.Value;
\r
243 txt_parWidth.Text = selectedTitle.ParVal.Width.ToString();
\r
244 txt_parHeight.Text = selectedTitle.ParVal.Height.ToString();
\r
245 txt_displayWidth.Text = displayWidth().ToString();
\r
248 darValue = calculateDar();
\r
250 check_KeepAR.CheckState = CheckState.Checked;
\r
251 check_KeepAR.Enabled = true;
\r
252 lbl_anamprohicLbl.Visible = true;
\r
258 // Custom Anamorphic Controls
\r
259 private void txt_displayWidth_Keyup(object sender, KeyEventArgs e)
\r
261 if (e.KeyCode == Keys.Enter)
\r
262 customAnamorphic(txt_displayWidth);
\r
264 private void txt_parHeight_Keyup(object sender, KeyEventArgs e)
\r
266 if (e.KeyCode == Keys.Enter)
\r
267 customAnamorphic(txt_parHeight);
\r
269 private void txt_parWidth_Keyup(object sender, KeyEventArgs e)
\r
271 if (e.KeyCode == Keys.Enter)
\r
272 customAnamorphic(txt_parWidth);
\r
275 // Cropping Controls
\r
276 private void check_autoCrop_CheckedChanged(object sender, EventArgs e)
\r
278 crop_left.Enabled = false;
\r
279 crop_right.Enabled = false;
\r
280 crop_top.Enabled = false;
\r
281 crop_bottom.Enabled = false;
\r
283 private void check_customCrop_CheckedChanged(object sender, EventArgs e)
\r
285 crop_left.Enabled = true;
\r
286 crop_right.Enabled = true;
\r
287 crop_top.Enabled = true;
\r
288 crop_bottom.Enabled = true;
\r
289 if (selectedTitle != null)
\r
291 crop_top.Text = selectedTitle.AutoCropDimensions[0].ToString();
\r
292 crop_bottom.Text = selectedTitle.AutoCropDimensions[1].ToString();
\r
293 crop_left.Text = selectedTitle.AutoCropDimensions[2].ToString();
\r
294 crop_right.Text = selectedTitle.AutoCropDimensions[3].ToString();
\r
298 crop_left.Text = "0";
\r
299 crop_right.Text = "0";
\r
300 crop_top.Text = "0";
\r
301 crop_bottom.Text = "0";
\r
304 private void crop_left_ValueChanged(object sender, EventArgs e)
\r
306 if (crop_left.Value % 2 != 0)
\r
309 private void crop_right_ValueChanged(object sender, EventArgs e)
\r
311 if (crop_right.Value % 2 != 0)
\r
312 crop_right.Value++;
\r
314 private void crop_top_ValueChanged(object sender, EventArgs e)
\r
316 if (crop_top.Value % 2 != 0)
\r
319 private void crop_bottom_ValueChanged(object sender, EventArgs e)
\r
321 if (crop_bottom.Value % 2 != 0)
\r
322 crop_bottom.Value++;
\r
325 // Custom Anamorphic Code
\r
326 private void customAnamorphic(Control control)
\r
328 // Get and parse all the required values
\r
329 int cropLeft = (int)crop_left.Value;
\r
330 int cropRight = (int)crop_right.Value;
\r
332 int width = (int)text_width.Value;
\r
333 int cropped_width = width - cropLeft - cropRight;
\r
336 int.TryParse(drop_modulus.SelectedItem.ToString(), out mod);
\r
339 double displayWidth;
\r
340 int.TryParse(txt_parWidth.Text, out parW);
\r
341 int.TryParse(txt_parHeight.Text, out parH);
\r
342 double.TryParse(txt_displayWidth.Text, out displayWidth);
\r
344 /* NOT KEEPING DISPLAY ASPECT
\r
345 * Changing STORAGE WIDTH changes DISPLAY WIDTH to STORAGE WIDTH * PIXEL WIDTH / PIXEL HEIGHT
\r
346 * Changing PIXEL dimensions changes DISPLAY WIDTH to STORAGE WIDTH * PIXEL WIDTH / PIXEL HEIGHT
\r
347 * Changing DISPLAY WIDTH changes PIXEL WIDTH to DISPLAY WIDTH and PIXEL HEIGHT to STORAGE WIDTH
\r
348 * Changing HEIGHT just....changes the height.
\r
350 if (!check_KeepAR.Checked)
\r
352 switch (control.Name)
\r
355 double dw = (double)cropped_width * parW / parH;
\r
356 dw = Math.Round(dw, 2);
\r
357 txt_displayWidth.Text = dw.ToString();
\r
359 case "txt_parWidth":
\r
360 double dwpw = (double)cropped_width * parW / parH;
\r
361 dwpw = Math.Round(dwpw, 2);
\r
362 txt_displayWidth.Text = dwpw.ToString();
\r
364 case "txt_parHeight":
\r
365 double dwph = (double)cropped_width * parW / parH;
\r
366 dwph = Math.Round(dwph, 2);
\r
367 txt_displayWidth.Text = dwph.ToString();
\r
369 case "txt_displayWidth":
\r
370 txt_parWidth.Text = Math.Round(displayWidth, 0).ToString();
\r
371 txt_parHeight.Text = text_width.Text;
\r
377 * KEEPING DISPLAY ASPECT RATIO
\r
378 * DAR = DISPLAY WIDTH / DISPLAY HEIGHT (cache after every modification)
\r
379 * Disable editing: PIXEL WIDTH, PIXEL HEIGHT
\r
380 * Changing DISPLAY WIDTH:
\r
381 * Changes HEIGHT to keep DAR
\r
382 * Changes PIXEL WIDTH to new DISPLAY WIDTH
\r
383 * Changes PIXEL HEIGHT to STORAGE WIDTH
\r
385 * Changes DISPLAY WIDTH to keep DAR
\r
386 * Changes PIXEL WIDTH to new DISPLAY WIDTH
\r
387 * Changes PIXEL HEIGHT to STORAGE WIDTH
\r
388 * Changing STORAGE_WIDTH:
\r
389 * Changes PIXEL WIDTH to DISPLAY WIDTH
\r
390 * Changes PIXEL HEIGHT to new STORAGE WIDTH
\r
393 if (check_KeepAR.Checked)
\r
395 switch (control.Name)
\r
397 case "txt_displayWidth":
\r
398 heightChangeGuard = true;
\r
399 text_height.Value = (decimal)getHeightKeepDar(); //Changes HEIGHT to keep DAR
\r
400 //darValue = calculateDar(); // Cache the dar value
\r
401 txt_parWidth.Text = txt_displayWidth.Text;
\r
402 txt_parHeight.Text = cropped_width.ToString();
\r
404 case "text_height":
\r
405 heightChangeGuard = true;
\r
406 txt_displayWidth.Text = getDisplayWidthKeepDar().ToString(); //Changes DISPLAY WIDTH to keep DAR
\r
407 txt_parWidth.Text = txt_displayWidth.Text;
\r
408 txt_parHeight.Text = cropped_width.ToString();
\r
411 txt_parWidth.Text = txt_displayWidth.Text;
\r
412 txt_parHeight.Text = cropped_width.ToString();
\r
417 private double getDisplayWidthKeepDar()
\r
419 double displayWidth;
\r
420 double.TryParse(txt_displayWidth.Text, out displayWidth);
\r
421 double currentDar = calculateDar();
\r
422 double newDwValue = displayWidth;
\r
424 // Correct display width up or down to correct for dar.
\r
425 if (currentDar > darValue)
\r
427 while (currentDar > darValue)
\r
430 newDwValue = displayWidth;
\r
431 currentDar = calculateDarByVal(text_height.Value, displayWidth);
\r
436 while (currentDar < darValue)
\r
439 newDwValue = displayWidth;
\r
440 currentDar = calculateDarByVal(text_height.Value, displayWidth);
\r
444 return Math.Round(newDwValue, 2);
\r
446 private double getHeightKeepDar()
\r
448 double displayWidth;
\r
449 double.TryParse(txt_displayWidth.Text, out displayWidth);
\r
450 double currentDar = calculateDar();
\r
451 double newHeightVal = heightVal;
\r
453 // Correct display width up or down.
\r
454 if (currentDar > darValue)
\r
456 while (currentDar > darValue)
\r
459 newHeightVal = heightVal;
\r
460 currentDar = calculateDarByVal(heightVal, displayWidth);
\r
465 while (currentDar < darValue)
\r
468 newHeightVal = heightVal;
\r
469 currentDar = calculateDarByVal(heightVal, displayWidth);
\r
473 return newHeightVal;
\r
475 private double calculateDar()
\r
477 // DAR = DISPLAY WIDTH / DISPLAY HEIGHT (cache after every modification)
\r
478 double displayWidth;
\r
479 double.TryParse(txt_displayWidth.Text, out displayWidth);
\r
481 double calculatedDar = displayWidth / (int)text_height.Value;
\r
483 return calculatedDar;
\r
485 private double calculateDarByVal(decimal croppedHeight, double displayWidth)
\r
487 // DAR = DISPLAY WIDTH / DISPLAY HEIGHT (cache after every modification)
\r
488 double calculatedDar = darValue;
\r
489 if (croppedHeight > 0)
\r
490 calculatedDar = displayWidth / (double)croppedHeight;
\r
492 return calculatedDar;
\r
494 private int displayWidth()
\r
496 if (selectedTitle != null)
\r
498 int actualWidth = (int)text_width.Value;
\r
499 int displayWidth = 0;
\r
502 int.TryParse(txt_parWidth.Text, out parW);
\r
503 int.TryParse(txt_parHeight.Text, out parH);
\r
505 if (drp_anamorphic.SelectedIndex != 3)
\r
506 displayWidth = (actualWidth * selectedTitle.ParVal.Width / selectedTitle.ParVal.Height);
\r
507 else if (parW > 0 && parH > 0)
\r
508 displayWidth = (actualWidth * parW / parH);
\r
510 return displayWidth;
\r
515 // Resolution calculation and controls
\r
516 private decimal widthChangeMod(int mod)
\r
518 // Increase or decrease the height based on the users input.
\r
519 decimal returnVal = text_width.Value > widthVal ? getResolutionJump(mod, text_width.Value, true) : getResolutionJump(mod, text_width.Value, false);
\r
521 // Make sure we don't go above source value
\r
522 if (selectedTitle != null)
\r
523 if (selectedTitle.Resolution.Width < returnVal)
\r
524 returnVal = selectedTitle.Resolution.Width;
\r
526 if (returnVal < 64)
\r
529 // Set the global tracker
\r
530 widthVal = (int)returnVal;
\r
534 private decimal heightChangeMod(int mod)
\r
536 // Increase or decrease the height based on the users input.
\r
537 decimal returnVal = text_height.Value > heightVal ? getResolutionJump(mod, text_height.Value, true) : getResolutionJump(mod, text_height.Value, false);
\r
539 // Make sure we don't go above source value
\r
540 if (selectedTitle != null)
\r
541 if (selectedTitle.Resolution.Height < returnVal)
\r
542 returnVal = selectedTitle.Resolution.Height;
\r
544 if (returnVal < 64)
\r
547 // Set the global tracker
\r
548 heightVal = (int)returnVal;
\r
552 private decimal calculateUnchangeValue(Boolean widthChangeFromControl)
\r
554 decimal newValue = -1;
\r
555 if (selectedTitle != null && drp_anamorphic.SelectedIndex != 3 && drp_anamorphic.SelectedIndex != 2)
\r
556 if (widthChangeFromControl)
\r
557 newValue = cacluateHeight(widthVal);
\r
560 if (check_KeepAR.Checked)
\r
561 newValue = cacluateWidth(heightVal);
\r
566 private int getResolutionJump(int mod, decimal value, Boolean up)
\r
569 while ((value % mod) != 0)
\r
572 while ((value % mod) != 0)
\r
577 private double getModulusAuto(int mod, double value)
\r
579 int modDiv2 = mod / 2;
\r
581 if ((value % mod) != 0)
\r
583 double modVal = (int)value % mod;
\r
584 if (modVal >= modDiv2)
\r
586 modVal = 16 - modVal;
\r
587 value = (int)value + (int)modVal;
\r
591 value = (int)value - (int)modVal;
\r
596 private int cacluateHeight(int width)
\r
598 if (selectedTitle != null)
\r
602 if (selectedTitle.AspectRatio == 1.78F)
\r
607 if (selectedTitle.AspectRatio == 1.33F)
\r
615 // Crop_Width = Title->Width - crop_Left - crop_right
\r
616 // Crop_Height = Title->Height - crop_top - crop_bottom
\r
617 double crop_width = selectedTitle.Resolution.Width - (double) crop_left.Value -
\r
618 (double) crop_right.Value;
\r
619 double crop_height = selectedTitle.Resolution.Height - (double) crop_top.Value -
\r
620 (double) crop_bottom.Value;
\r
622 double new_height = (width*selectedTitle.Resolution.Width*ah*crop_height)/
\r
623 (selectedTitle.Resolution.Height*aw*crop_width);
\r
625 if (drp_anamorphic.SelectedIndex == 3)
\r
626 new_height = getModulusAuto(int.Parse(drop_modulus.SelectedItem.ToString()), new_height);
\r
628 new_height = getModulusAuto(16, new_height);
\r
631 //double z = ( 16 * (( y + 8 ) / 16 ) );
\r
632 int x = int.Parse(new_height.ToString());
\r
640 private int cacluateWidth(int height)
\r
644 if (selectedTitle.AspectRatio == 1.78F)
\r
649 if (selectedTitle.AspectRatio == 1.33F)
\r
658 double crop_width = selectedTitle.Resolution.Width - (double)crop_left.Value - (double)crop_right.Value;
\r
659 double crop_height = selectedTitle.Resolution.Height - (double)crop_top.Value - (double)crop_bottom.Value;
\r
661 double new_width = (height * selectedTitle.Resolution.Height * aw * crop_width) /
\r
662 (selectedTitle.Resolution.Width * ah * crop_height);
\r
664 if (drp_anamorphic.SelectedIndex == 3)
\r
665 new_width = getModulusAuto(int.Parse(drop_modulus.SelectedItem.ToString()), new_width);
\r
667 new_width = getModulusAuto(16, new_width);
\r
670 int x = int.Parse(new_width.ToString());
\r
680 // Calculate Resolution for Anamorphic functions
\r
681 private string strictAnamorphic()
\r
683 // TODO Make sure cropping is Mod2
\r
684 if (selectedTitle != null)
\r
686 // Calculate the Actual Height
\r
687 int actualWidth = (int)text_width.Value - (int)crop_left.Value - (int)crop_right.Value; ;
\r
688 int actualHeight = selectedTitle.Resolution.Height - (int)crop_top.Value - (int)crop_bottom.Value;
\r
690 // Calculate Actual Width
\r
691 double displayWidth = ((double)actualWidth * selectedTitle.ParVal.Width / selectedTitle.ParVal.Height);
\r
692 return Math.Round(displayWidth, 0) + "x" + actualHeight;
\r
694 return "Select a Title";
\r
696 private string looseAnamorphic()
\r
698 if (selectedTitle != null)
\r
701 int actualWidth = (int)text_width.Value - (int)crop_left.Value - (int)crop_right.Value;
\r
703 int source_display_width = selectedTitle.Resolution.Width * selectedTitle.ParVal.Width / selectedTitle.ParVal.Height;
\r
704 int source_cropped_height = selectedTitle.Resolution.Height - (int)crop_top.Value - (int)crop_bottom.Value;
\r
706 // Calculate storage Aspect and cache it for reuse
\r
707 if (storageAspect == 0)
\r
708 storageAspect = (double)actualWidth / source_cropped_height;
\r
710 // Calculate the new height based on the input cropped width
\r
711 double hcalc = (actualWidth / storageAspect) + 0.5;
\r
712 double newHeight = getModulusAuto(16, hcalc);
\r
713 looseAnamorphicHeightGuard = true;
\r
715 if (newHeight < 64)
\r
717 text_height.Value = (decimal)newHeight; // BUG Out of Range Exception with Width too low here.
\r
719 // Calculate the anamorphic width
\r
720 double parW = newHeight * source_display_width / source_cropped_height;
\r
721 double parH = actualWidth;
\r
722 double displayWidth = (actualWidth * parW / parH);
\r
724 // Now correct DisplayWidth to maintain Aspect ratio. ActualHeight was mod16'd and thus AR is slightly different than the worked out displayWidths
\r
725 return Math.Truncate(displayWidth) + "x" + newHeight;
\r
727 return "Select a Title";
\r
732 private void disableCustomAnaControls()
\r
734 // Disable Custom Anamorphic Stuff
\r
735 lbl_modulus.Visible = false;
\r
736 lbl_displayWidth.Visible = false;
\r
737 lbl_parWidth.Visible = false;
\r
738 lbl_parHeight.Visible = false;
\r
739 drop_modulus.Visible = false;
\r
740 txt_displayWidth.Visible = false;
\r
741 txt_parWidth.Visible = false;
\r
742 txt_parHeight.Visible = false;
\r
743 check_KeepAR.Enabled = false;
\r
745 private void enableCustomAnaControls()
\r
747 // Disable Custom Anamorphic Stuff
\r
748 lbl_modulus.Visible = true;
\r
749 lbl_displayWidth.Visible = true;
\r
750 lbl_parWidth.Visible = true;
\r
751 lbl_parHeight.Visible = true;
\r
752 drop_modulus.Visible = true;
\r
753 txt_displayWidth.Visible = true;
\r
754 txt_parWidth.Visible = true;
\r
755 txt_parHeight.Visible = true;
\r
756 check_KeepAR.Enabled = true;
\r