OSDN Git Service

LinGui: change the top level structure that contains presets from a dictionary
[handbrake-jp/handbrake-jp-git.git] / macosx / PictureController.mm
index 34d034d..c32a120 100644 (file)
        }
        
        /* Set filters widgets according to the filters struct */
-       [fVFRCheck setState:fPictureFilterSettings.vfr];
-    [fDetelecineCheck setState:fPictureFilterSettings.detelecine];
+       [fDetelecineCheck setState:fPictureFilterSettings.detelecine];
     [fDeinterlacePopUp selectItemAtIndex: fPictureFilterSettings.deinterlace];
     [fDenoisePopUp selectItemAtIndex: fPictureFilterSettings.denoise];
     [fDeblockCheck setState: fPictureFilterSettings.deblock];
@@ -263,6 +262,14 @@ are maintained across different sources */
             /* We set job->width and call hb_set_anamorphic_size in libhb to do a "dry run" to get
              * the values to be used by libhb for loose anamorphic
              */
+            /* if the sender is the anamorphic popup, then we know that loose anamorphic has just
+             * been turned on, so snap the width to full width for the source.
+             */
+            if (sender == fAnamorphicPopUp)
+            {
+                [fWidthStepper      setIntValue: fTitle->width-fTitle->job->crop[2]-fTitle->job->crop[3]];
+                [fWidthField        setIntValue: fTitle->width-fTitle->job->crop[2]-fTitle->job->crop[3]];
+            }
             job->width       = [fWidthStepper  intValue];
             hb_set_anamorphic_size(job, &output_width, &output_height, &output_par_width, &output_par_height);
             [fHeightStepper      setIntValue: output_height];
@@ -335,16 +342,7 @@ are maintained across different sources */
         job->deinterlace  = 0;
     }
     fPictureFilterSettings.denoise     = [fDenoisePopUp indexOfSelectedItem];
-    fPictureFilterSettings.vfr  = [fVFRCheck state];
-    if (fPictureFilterSettings.vfr > 0)
-    {
-        [fDetelecineCheck setState:NSOnState];
-        [fDetelecineCheck setEnabled: NO];
-    }
-    else
-    {
-        [fDetelecineCheck setEnabled: YES];
-    }
+    
     fPictureFilterSettings.detelecine  = [fDetelecineCheck state];
     
     if ([fDeblockField stringValue] == @"Off")
@@ -474,16 +472,6 @@ are maintained across different sources */
     fPictureFilterSettings.detelecine = setting;
 }
 
-- (int) vfr
-{
-    return fPictureFilterSettings.vfr;
-}
-
-- (void) setVFR: (int) setting
-{
-    fPictureFilterSettings.vfr = setting;
-}
-
 - (int) deinterlace
 {
     return fPictureFilterSettings.deinterlace;