summaryrefslogtreecommitdiffstats
path: root/gtk
diff options
context:
space:
mode:
authorjstebbins <[email protected]>2010-06-18 20:09:08 +0000
committerjstebbins <[email protected]>2010-06-18 20:09:08 +0000
commitdd49fbf10e64e5279567468f9fbf4870592496dd (patch)
treefcf0e2dd6aaff17f4b7d5f3c31dc4467d3314866 /gtk
parent24cc8113b9baf7d7d6dc36a6a0d260e3bd28d71b (diff)
LinGui: add peak framrate checkbox to video tab
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@3391 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'gtk')
-rw-r--r--gtk/src/ghb.ui19
-rw-r--r--gtk/src/hb-backend.c6
-rw-r--r--gtk/src/internal_defaults.xml2
-rw-r--r--gtk/src/makedeps.py1
4 files changed, 25 insertions, 3 deletions
diff --git a/gtk/src/ghb.ui b/gtk/src/ghb.ui
index a71118907..bae888a31 100644
--- a/gtk/src/ghb.ui
+++ b/gtk/src/ghb.ui
@@ -1757,6 +1757,21 @@
</packing>
</child>
<child>
+ <object class="GtkCheckButton" id="VideoFrameratePFR">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="events">GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK</property>
+ <property name="tooltip-text" translatable="yes">Enables variable framerate output with a peak rate determined by the framerate setting</property>
+ <property name="label" translatable="yes">Peak Framerate (VFR)</property>
+ <property name="draw_indicator">True</property>
+ <signal handler="setting_widget_changed_cb" name="toggled"/>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="position">2</property>
+ </packing>
+ </child>
+ <child>
<object class="GtkCheckButton" id="VideoTwoPass">
<property name="visible">True</property>
<property name="can_focus">True</property>
@@ -1768,7 +1783,7 @@
</object>
<packing>
<property name="expand">False</property>
- <property name="position">2</property>
+ <property name="position">3</property>
</packing>
</child>
<child>
@@ -1791,7 +1806,7 @@
</object>
<packing>
<property name="expand">False</property>
- <property name="position">3</property>
+ <property name="position">4</property>
</packing>
</child>
</object>
diff --git a/gtk/src/hb-backend.c b/gtk/src/hb-backend.c
index 19ae7d819..63ce0c063 100644
--- a/gtk/src/hb-backend.c
+++ b/gtk/src/hb-backend.c
@@ -4678,7 +4678,11 @@ add_job(hb_handle_t *h, GValue *js, gint unique_id, gint titleindex)
{
job->vrate = 27000000;
job->vrate_base = vrate;
- job->cfr = 1;
+ gboolean pfr = ghb_settings_get_boolean(js, "VideoFrameratePFR");
+ if (pfr)
+ job->cfr = 2;
+ else
+ job->cfr = 1;
}
const GValue *audio_list;
diff --git a/gtk/src/internal_defaults.xml b/gtk/src/internal_defaults.xml
index 2bda44783..d6474329c 100644
--- a/gtk/src/internal_defaults.xml
+++ b/gtk/src/internal_defaults.xml
@@ -271,6 +271,8 @@
<integer>0</integer>
<key>VideoFramerate</key>
<string>source</string>
+ <key>VideoFrameratePFR</key>
+ <false />
<key>VideoGrayScale</key>
<false />
<key>Mp4HttpOptimize</key>
diff --git a/gtk/src/makedeps.py b/gtk/src/makedeps.py
index f677241b0..dbc492353 100644
--- a/gtk/src/makedeps.py
+++ b/gtk/src/makedeps.py
@@ -25,6 +25,7 @@ dep_map = (
DepEntry("vquality_type_constant", "VideoQualitySlider", "TRUE", False, False),
DepEntry("vquality_type_constant", "VideoTwoPass", "TRUE", True, False),
DepEntry("vquality_type_constant", "VideoTurboTwoPass", "TRUE", True, False),
+ DepEntry("VideoFramerate", "VideoFrameratePFR", "source", True, False),
DepEntry("VideoTwoPass", "VideoTurboTwoPass", "TRUE", False, False),
DepEntry("FileFormat", "Mp4LargeFile", "mp4", False, True),
DepEntry("FileFormat", "Mp4HttpOptimize", "mp4", False, True),