commit 7cbeb04808e0b086622e707598a2ea07eceb40ad
Author: Jaroslav Kysela <perex(a)perex.cz>
Date: Thu Nov 9 11:28:45 2017 +0100
Initial version
.gitignore | 1 +
qwinff-extradefs.patch | 27 ++
qwinff-perex1.patch | 203 +++++++++
qwinff-perex2.patch | 79 ++++
qwinff-perex3.patch | 50 +++
qwinff-perex4.patch | 38 ++
qwinff-post.patch | 1105 ++++++++++++++++++++++++++++++++++++++++++++++++
qwinff.spec | 68 +++
sources | 1 +
9 files changed, 1572 insertions(+)
---
diff --git a/.gitignore b/.gitignore
index e69de29..39f9ef3 100644
--- a/.gitignore
+++ b/.gitignore
@@ -0,0 +1 @@
+/qwinff-0.2.1.tar.gz
diff --git a/qwinff-extradefs.patch b/qwinff-extradefs.patch
new file mode 100644
index 0000000..2040ffe
--- /dev/null
+++ b/qwinff-extradefs.patch
@@ -0,0 +1,27 @@
+diff --git a/Makefile b/Makefile
+index 4e6a779..c75df11 100644
+--- a/Makefile
++++ b/Makefile
+@@ -29,6 +29,13 @@ QMAKE_DEFS= DESTDIR=$(BIN_DIR) \
+ RCC_DIR=$(BUILD_DIR)/rcc \
+ UI_DIR=$(BUILD_DIR)/ui \
+ DEFINES+=QT_NO_DEBUG_OUTPUT
++QMAKE_EXTRA_DEFS= QMAKE_CFLAGS_DEBUG="$(QMAKE_CFLAGS_DEBUG)" \
++ QMAKE_CFLAGS_RELEASE="$(QMAKE_CFLAGS_RELEASE)" \
++ QMAKE_CXXFLAGS_DEBUG="$(QMAKE_CXXFLAGS_DEBUG)" \
++ QMAKE_CXXFLAGS_RELEASE="$(QMAKE_CXXFLAGS_RELEASE)" \
++ QMAKE_LFLAGS_DEBUG="$(QMAKE_LFLAGS_DEBUG)" \
++ QMAKE_LFLAGS_RELEASE="$(QMAKE_LFLAGS_RELEASE)" \
++ QMAKE_STRIP="$(QMAKE_STRIP)"
+
+ DEFS= DATA_PATH=\\\"$(DATA_PATH)\\\" \
+ VERSION_ID_STRING=\\\"$(VIDSTR)\\\"
+@@ -42,7 +49,7 @@ endif
+ all: release
+
+ release:
+- +cd $(SRC_DIR) && $(QMAKE) $(QMAKE_DEFS) qwinff.pro && $(DEFS) $(MAKE)
++ +cd $(SRC_DIR) && $(QMAKE) $(QMAKE_DEFS) $(QMAKE_EXTRA_DEFS) qwinff.pro
&& $(DEFS) $(MAKE)
+ -cd src && $(LRELEASE) qwinff.pro
+
+ check:
diff --git a/qwinff-perex1.patch b/qwinff-perex1.patch
new file mode 100644
index 0000000..55e92ed
--- /dev/null
+++ b/qwinff-perex1.patch
@@ -0,0 +1,203 @@
+From 58fd3c100883b123d7ba255ac62a36e2be1eea6d Mon Sep 17 00:00:00 2001
+From: Jaroslav Kysela <perex(a)perex.cz>
+Date: Tue, 7 Nov 2017 13:36:32 +0100
+Subject: [PATCH 1/2] add extra FFMPEG global options support to both
+ presets.xml and GUI
+
+The '-strict strict' or '-cpuflags -sse+mmx' parameters can be used
+globally. Add support for this.
+---
+ src/converter/conversionparameters.cpp | 7 ++++---
+ src/converter/conversionparameters.h | 5 +++--
+ src/converter/ffmpeginterface.cpp | 2 ++
+ src/converter/presets.cpp | 6 ++++++
+ src/converter/presets.h | 1 +
+ src/ui/addtaskwizard.cpp | 2 +-
+ src/ui/conversionparameterdialog.cpp | 4 +++-
+ src/ui/conversionparameterdialog.ui | 14 ++++++++++++++
+ 8 files changed, 34 insertions(+), 7 deletions(-)
+
+diff --git a/src/converter/conversionparameters.cpp
b/src/converter/conversionparameters.cpp
+index 8a44f6e..ee07e0c 100644
+--- a/src/converter/conversionparameters.cpp
++++ b/src/converter/conversionparameters.cpp
+@@ -132,7 +132,7 @@ void ConversionParameters::copyConfigurationFrom(const
ConversionParameters &src
+ }
+
+ ConversionParameters
+-ConversionParameters::fromFFmpegParameters(const QString ¶ms_str)
++ConversionParameters::fromFFmpegParameters(const QString &globals_str, const QString
¶ms_str)
+ {
+ ConversionParameters result;
+ QStringList args = params_str.split(" ", QString::SkipEmptyParts);
+@@ -148,13 +148,14 @@ ConversionParameters::fromFFmpegParameters(const QString
¶ms_str)
+ }
+ }
+
++ result.ffmpeg_globals = globals_str;
+ result.ffmpeg_options = args.join(" "); // unrecognized arguments
+
+ return result;
+ }
+
+ ConversionParameters
+-ConversionParameters::fromFFmpegParameters(const char *params_str)
++ConversionParameters::fromFFmpegParameters(const char *globals_str, const char
*params_str)
+ {
+- return fromFFmpegParameters(QString(params_str));
++ return fromFFmpegParameters(QString(globals_str), QString(params_str));
+ }
+diff --git a/src/converter/conversionparameters.h b/src/converter/conversionparameters.h
+index 3cd0b5b..b7d2206 100644
+--- a/src/converter/conversionparameters.h
++++ b/src/converter/conversionparameters.h
+@@ -51,6 +51,7 @@ class ConversionParameters
+ /* FFmpeg Specific Options */
+ /*! Additional options passed to the ffmpeg transcoder.
+ These options will be overriden by other specific options. */
++ QString ffmpeg_globals;
+ QString ffmpeg_options;
+
+ /* MEncoder Specific Options */
+@@ -77,8 +78,8 @@ class ConversionParameters
+
+ /*! Generate a ConversionParameters from ffmpeg command line options.
+ This function ignores input and output file options. */
+- static ConversionParameters fromFFmpegParameters(const QString& params_str);
+- static ConversionParameters fromFFmpegParameters(const char *params_str);
++ static ConversionParameters fromFFmpegParameters(const QString& globals_str,
const QString& params_str);
++ static ConversionParameters fromFFmpegParameters(const char *globals_str, const char
*params_str);
+
+ ConversionParameters()
+ : threads(0),
+diff --git a/src/converter/ffmpeginterface.cpp b/src/converter/ffmpeginterface.cpp
+index 632a1ef..724573e 100644
+--- a/src/converter/ffmpeginterface.cpp
++++ b/src/converter/ffmpeginterface.cpp
+@@ -361,6 +361,8 @@ QStringList FFmpegInterface::Private::getOptionList(const
ConversionParameters &
+ // overwrite if file exists
+ list.append("-y");
+
++ list.append(o.ffmpeg_globals);
++
+ if (!bNeedsAudioFilter) {
+ /* in this configuration, input is read from file
+ arguments: -i <infile>
+diff --git a/src/converter/presets.cpp b/src/converter/presets.cpp
+index 8449b61..66a8603 100644
+--- a/src/converter/presets.cpp
++++ b/src/converter/presets.cpp
+@@ -128,6 +128,12 @@ bool Presets::Private::readElementData(QXmlStreamReader &xml,
Preset& target)
+
+ if (property_name == "label") {
+ target.label = property_value;
++ } else if (property_name == "globals") {
++ Version ffmpegVersion(FFmpegInterface::getFFmpegVersionInfo());
++ if (versionrange_str.isEmpty()
++ || VersionRange(versionrange_str).containsVersion(ffmpegVersion)) {
++ target.globals = property_value;
++ }
+ } else if (property_name == "params") {
+ Version ffmpegVersion(FFmpegInterface::getFFmpegVersionInfo());
+ if (versionrange_str.isEmpty()
+diff --git a/src/converter/presets.h b/src/converter/presets.h
+index 4b8c488..02b12d1 100644
+--- a/src/converter/presets.h
++++ b/src/converter/presets.h
+@@ -28,6 +28,7 @@ class Preset
+ QString extension;
+ QString label;
+ QString category;
++ QString globals;
+ QString parameters;
+
+ /*! Sorting requires less-than operator.
+diff --git a/src/ui/addtaskwizard.cpp b/src/ui/addtaskwizard.cpp
+index d683093..b50f3ba 100644
+--- a/src/ui/addtaskwizard.cpp
++++ b/src/ui/addtaskwizard.cpp
+@@ -256,7 +256,7 @@ void AddTaskWizard::slotPresetSelected(int index)
+ if (!m_presets->findPresetById(id, preset)) {
+ return; // assert false
+ }
+- *m_current_param = ConversionParameters::fromFFmpegParameters(preset.parameters);
++ *m_current_param = ConversionParameters::fromFFmpegParameters(preset.globals,
preset.parameters);
+ }
+
+ // This function is executed when the users presses "Finish"
+diff --git a/src/ui/conversionparameterdialog.cpp b/src/ui/conversionparameterdialog.cpp
+index 0b0e292..3537c82 100644
+--- a/src/ui/conversionparameterdialog.cpp
++++ b/src/ui/conversionparameterdialog.cpp
+@@ -130,6 +130,7 @@ AbstractPreviewer *ConversionParameterDialog::create_previewer()
+ void ConversionParameterDialog::read_fields(const ConversionParameters& param)
+ {
+ // Additional Options
++ ui->txtFFmpegGlobals->setPlainText(param.ffmpeg_globals);
+ ui->txtFFmpegOptions->setPlainText(param.ffmpeg_options);
+
+ // Audio Options
+@@ -213,7 +214,8 @@ void ConversionParameterDialog::read_fields(const
ConversionParameters& param)
+ void ConversionParameterDialog::write_fields(ConversionParameters& param)
+ {
+ // Additional Options
+- param = param.fromFFmpegParameters(ui->txtFFmpegOptions->toPlainText());
++ param = param.fromFFmpegParameters(ui->txtFFmpegGlobals->toPlainText(),
++ ui->txtFFmpegOptions->toPlainText());
+
+ // Audio Options
+ param.disable_audio = ui->chkDisableAudio->isChecked();
+diff --git a/src/ui/conversionparameterdialog.ui b/src/ui/conversionparameterdialog.ui
+index 6432268..1f73f4f 100644
+--- a/src/ui/conversionparameterdialog.ui
++++ b/src/ui/conversionparameterdialog.ui
+@@ -520,6 +520,20 @@
+ </property>
+ <layout class="QVBoxLayout"
name="verticalLayout_5">
+ <item>
++ <layout class="QVBoxLayout"
name="verticalLayout_10">
++ <item>
++ <widget class="QLabel"
name="lblFFmpegGlobals">
++ <property name="text">
++ <string>Additional FFmpeg Global Options</string>
++ </property>
++ </widget>
++ </item>
++ <item>
++ <widget class="QPlainTextEdit"
name="txtFFmpegGlobals"/>
++ </item>
++ </layout>
++ </item>
++ <item>
+ <layout class="QVBoxLayout"
name="verticalLayout_4">
+ <item>
+ <widget class="QLabel"
name="lblFFmpegOptions">
+
+From 1f236ce3997bcaf94285ccd7ba738a31d9193e91 Mon Sep 17 00:00:00 2001
+From: Jaroslav Kysela <perex(a)perex.cz>
+Date: Tue, 7 Nov 2017 15:53:48 +0100
+Subject: [PATCH 2/2] ffmpeg interface: fix the global options passing
+
+---
+ src/converter/ffmpeginterface.cpp | 8 +++++++-
+ 1 file changed, 7 insertions(+), 1 deletion(-)
+
+diff --git a/src/converter/ffmpeginterface.cpp b/src/converter/ffmpeginterface.cpp
+index 724573e..4bdada2 100644
+--- a/src/converter/ffmpeginterface.cpp
++++ b/src/converter/ffmpeginterface.cpp
+@@ -361,7 +361,13 @@ QStringList FFmpegInterface::Private::getOptionList(const
ConversionParameters &
+ // overwrite if file exists
+ list.append("-y");
+
+- list.append(o.ffmpeg_globals);
++ /* ==== Additional Global Options ==== */
++ if (!o.ffmpeg_globals.isEmpty()) {
++ QList<QString> additional_globals =
++ o.ffmpeg_globals.split(" ", QString::SkipEmptyParts);
++ foreach (QString opt, additional_globals)
++ list.append(opt);
++ }
+
+ if (!bNeedsAudioFilter) {
+ /* in this configuration, input is read from file
diff --git a/qwinff-perex2.patch b/qwinff-perex2.patch
new file mode 100644
index 0000000..f9056f0
--- /dev/null
+++ b/qwinff-perex2.patch
@@ -0,0 +1,79 @@
+From 4d6f6c2c349bcd00bbdbf7cb0f51c9ba22eb044b Mon Sep 17 00:00:00 2001
+From: Jaroslav Kysela <perex(a)perex.cz>
+Date: Tue, 7 Nov 2017 12:43:21 +0100
+Subject: [PATCH 1/2] presets: new ffmpeg can identify codecs using -c:a or
+ -codec:a argument, fix removeUnavailablePresets()
+
+---
+ src/converter/presets.cpp | 12 ++++++------
+ 1 file changed, 6 insertions(+), 6 deletions(-)
+
+diff --git a/src/converter/presets.cpp b/src/converter/presets.cpp
+index 8449b61..545b4ef 100644
+--- a/src/converter/presets.cpp
++++ b/src/converter/presets.cpp
+@@ -154,9 +154,9 @@ void Presets::Private::removeUnavailablePresets()
+ if (!FFmpegInterface::getSubtitleEncoders(subtitle_encoders))
+ Q_ASSERT(subtitle_encoders.isEmpty());
+
+- QRegExp audio_codec_pattern("-acodec\\s+([^ ]+)");
+- QRegExp video_codec_pattern("-vcodec\\s+([^ ]+)");
+- QRegExp subtitle_codec_pattern("-scodec\\s+([^ ]+)");
++ QRegExp audio_codec_pattern("-(c:a|codec:a|acodec)\\s+([^ ]+)");
++ QRegExp video_codec_pattern("-(c:v|codec:v|vcodec)\\s+([^ ]+)");
++ QRegExp subtitle_codec_pattern("-(c:s|codec:s|scodec)\\s+([^ ]+)");
+
+ QMultiMap<QString, Preset>::iterator it = presets.begin();
+ while (it!=presets.end()) {
+@@ -165,21 +165,21 @@ void Presets::Private::removeUnavailablePresets()
+
+ // Check unavailable audio presets
+ if (audio_codec_pattern.indexIn(params) != -1) {
+- if (!audio_encoders.contains(audio_codec_pattern.cap(1))) {
++ if (!audio_encoders.contains(audio_codec_pattern.cap(2))) {
+ remove = true;
+ }
+ }
+
+ // Check unavailable video presets
+ if (!remove && video_codec_pattern.indexIn(params) != -1) {
+- if (!video_encoders.contains(video_codec_pattern.cap(1))) {
++ if (!video_encoders.contains(video_codec_pattern.cap(2))) {
+ remove = true;
+ }
+ }
+
+ // Check unavailable subtitle presets
+ if (!remove && subtitle_codec_pattern.indexIn(params) != -1) {
+- if (!subtitle_encoders.contains(subtitle_codec_pattern.cap(1))) {
++ if (!subtitle_encoders.contains(subtitle_codec_pattern.cap(2))) {
+ remove = true;
+ }
+ }
+
+From 4837d6dbb5da1a9da83717fe283d8ad69637521d Mon Sep 17 00:00:00 2001
+From: Jaroslav Kysela <perex(a)perex.cz>
+Date: Tue, 7 Nov 2017 13:40:48 +0100
+Subject: [PATCH 2/2] ffmpeg interface: always add 'copy' codecs
+
+- they are not printed by ffmpeg
+- presets.xml might use them (only cutting) and we don't want
+ to filter them out (removeUnavailablePresets)
+---
+ src/converter/ffmpeginterface.cpp | 3 +++
+ 1 file changed, 3 insertions(+)
+
+diff --git a/src/converter/ffmpeginterface.cpp b/src/converter/ffmpeginterface.cpp
+index 632a1ef..f255aff 100644
+--- a/src/converter/ffmpeginterface.cpp
++++ b/src/converter/ffmpeginterface.cpp
+@@ -130,6 +130,9 @@ namespace inner {
+ const int CODEC_DESC = 3;
+
+ ffmpeg_codec_info.clear();
++ audio_encoders.push_back("copy");
++ video_encoders.push_back("copy");
++ subtitle_encoders.push_back("copy");
+ while (ffmpeg_process.canReadLine()) {
+ QString line(ffmpeg_process.readLine());
+ ffmpeg_codec_info.append(line);
diff --git a/qwinff-perex3.patch b/qwinff-perex3.patch
new file mode 100644
index 0000000..b782087
--- /dev/null
+++ b/qwinff-perex3.patch
@@ -0,0 +1,50 @@
+From 615e5e347c8ba67562fdf939ec2bf2e9f2a835bb Mon Sep 17 00:00:00 2001
+From: Jaroslav Kysela <perex(a)perex.cz>
+Date: Tue, 7 Nov 2017 16:23:03 +0100
+Subject: [PATCH] presets: add some MKV examples
+
+---
+ src/presets.xml | 30 ++++++++++++++++++++++++++++++
+ 1 file changed, 30 insertions(+)
+
+diff --git a/src/presets.xml b/src/presets.xml
+index 2683de7..127d69a 100644
+--- a/src/presets.xml
++++ b/src/presets.xml
+@@ -1,6 +1,36 @@
+ <?xml version="1.0"?>
+ <presets>
+
++ <!-- Matroska -->
++ <MKVCopy>
++ <label>MKV Copy (cutting)</label>
++ <globals>-strict strict</globals>
++ <params>-map 0 -vcodec copy -acodec copy -scodec copy</params>
++ <extension>mkv</extension>
++ <category>Matroska</category>
++ </MKVCopy>
++ <MKVWideLR264>
++ <label>MKV H.264 Widescreen 896x504</label>
++ <globals>-strict strict</globals>
++ <params>-map 0 -q:v 2 -c:v libx264 -preset slow -s 896:504 -c:a copy -scodec
copy</params>
++ <extension>mkv</extension>
++ <category>Matroska</category>
++ </MKVWideLR264>
++ <MKVWideHD264>
++ <label>MKV H.264 Widescreen 1280x720</label>
++ <globals>-strict strict</globals>
++ <params>-map 0 -q:v 2 -c:v libx264 -preset slow -s 1280:720 -c:a copy -scodec
copy</params>
++ <extension>mkv</extension>
++ <category>Matroska</category>
++ </MKVWideHD264>
++ <MKVWideFHD264>
++ <label>MKV H.264 Widescreen 1920x1080</label>
++ <globals>-strict strict</globals>
++ <params>-map 0 -q:v 2 -c:v libx264 -preset slow -s 1920:1080 -c:a copy -scodec
copy</params>
++ <extension>mkv</extension>
++ <category>Matroska</category>
++ </MKVWideFHD264>
++
+ <!-- MPEG4 -->
+ <MPEG4Auto>
+ <label>MPEG-4 Auto</label>
diff --git a/qwinff-perex4.patch b/qwinff-perex4.patch
new file mode 100644
index 0000000..30f644e
--- /dev/null
+++ b/qwinff-perex4.patch
@@ -0,0 +1,38 @@
+From e094fc61a09b8378ebea8a81d8d45976b41022de Mon Sep 17 00:00:00 2001
+From: Jaroslav Kysela <perex(a)perex.cz>
+Date: Tue, 7 Nov 2017 17:06:24 +0100
+Subject: [PATCH] config path: use the default Qt location for .ini file (in
+ /home/perex/.config/qwinff directory)
+
+---
+ src/main.cpp | 11 +++--------
+ 1 file changed, 3 insertions(+), 8 deletions(-)
+
+diff --git a/src/main.cpp b/src/main.cpp
+index 5b704f0..363023c 100644
+--- a/src/main.cpp
++++ b/src/main.cpp
+@@ -154,20 +154,15 @@ int main(int argc, char *argv[])
+
+ // Register QSettings information.
+ app.setOrganizationName("qwinff");
++ QSettings::setDefaultFormat(QSettings::IniFormat);
+ if (Constants::getBool("Portable")) {
+ // Portable App: Save settings in <exepath>/qwinff.ini.
+- QSettings::setDefaultFormat(QSettings::IniFormat);
+ QSettings::setPath(QSettings::IniFormat, QSettings::UserScope
+ , app.applicationDirPath());
+- qDebug() << "Setting path: " + app.applicationDirPath();
+ } else {
+- // Save settings in <home>/.qwinff/qwinff.ini
+- QString settings_dir =
QDir(QDir::homePath()).absoluteFilePath(".qwinff");
+- QDir().mkpath(settings_dir);
+- QSettings::setDefaultFormat(QSettings::IniFormat);
+- QSettings::setPath(QSettings::IniFormat, QSettings::UserScope, settings_dir);
+- qDebug() << "Setting path: " + settings_dir;
++ // Save settings to the default Qt location
+ }
++ qDebug() << "Settings filename: " + QSettings().fileName();
+
+ Paths::setAppPath(app.applicationDirPath());
+
diff --git a/qwinff-post.patch b/qwinff-post.patch
new file mode 100644
index 0000000..b131356
--- /dev/null
+++ b/qwinff-post.patch
@@ -0,0 +1,1105 @@
+From 764a8b30ed1938a99f49508054037e9d0e2b9a92 Mon Sep 17 00:00:00 2001
+From: Che-Huai Lin <lzh9102(a)gmail.com>
+Date: Wed, 26 Aug 2015 23:29:58 +0800
+Subject: [PATCH 01/10] Add new translations to list in qwinff.pro
+
+---
+ src/qwinff.pro | 4 +++-
+ 1 file changed, 3 insertions(+), 1 deletion(-)
+
+diff --git a/src/qwinff.pro b/src/qwinff.pro
+index ccca83f..097643d 100644
+--- a/src/qwinff.pro
++++ b/src/qwinff.pro
+@@ -131,7 +131,9 @@ TRANSLATIONS += \
+ translations/qwinff_tr_TR.ts \
+ translations/qwinff_ar.ts \
+ translations/qwinff_hu_HU.ts \
+- translations/qwinff_pl_PL.ts
++ translations/qwinff_pl_PL.ts \
++ translations/qwinff_fr_FR.ts \
++ translations/qwinff_pt_BR.ts
+
+ INCLUDEPATH += .
+
+
+From 2257c03654df11844f78b9d2574b58b4e84d389f Mon Sep 17 00:00:00 2001
+From: Che-Huai Lin <lzh9102(a)gmail.com>
+Date: Tue, 3 Nov 2015 12:08:22 +0800
+Subject: [PATCH 02/10] Update translations
+
+---
+ src/qwinff.pro | 4 +-
+ src/translations/qwinff_es_ES.ts | 62 +++++++++++-----------
+ src/translations/{qwinff_fr_FR.ts => qwinff_fr.ts} | 18 ++++---
+ src/translations/qwinff_pl_PL.ts | 51 +++++++++---------
+ src/translations/qwinff_pt_BR.ts | 18 ++++---
+ 5 files changed, 78 insertions(+), 75 deletions(-)
+ rename src/translations/{qwinff_fr_FR.ts => qwinff_fr.ts} (98%)
+
+diff --git a/src/qwinff.pro b/src/qwinff.pro
+index 097643d..19350db 100644
+--- a/src/qwinff.pro
++++ b/src/qwinff.pro
+@@ -132,8 +132,8 @@ TRANSLATIONS += \
+ translations/qwinff_ar.ts \
+ translations/qwinff_hu_HU.ts \
+ translations/qwinff_pl_PL.ts \
+- translations/qwinff_fr_FR.ts \
+- translations/qwinff_pt_BR.ts
++ translations/qwinff_pt_BR.ts \
++ translations/qwinff_fr.ts
+
+ INCLUDEPATH += .
+
+diff --git a/src/translations/qwinff_es_ES.ts b/src/translations/qwinff_es_ES.ts
+index b3980a0..06e9bb2 100644
+--- a/src/translations/qwinff_es_ES.ts
++++ b/src/translations/qwinff_es_ES.ts
+@@ -201,7 +201,7 @@
+ </message>
+ <message>
+ <source>Select &folder</source>
+- <translation type="unfinished"></translation>
++ <translation>Seleccionar &Carpeta</translation>
+ </message>
+ <message>
+ <source>Browse</source>
+@@ -210,16 +210,16 @@
+ <message>
+ <source>Create &new folder in source folder</source>
+ <extracomment>Create a new folder (e.g. qwinff_output) in the folder
containing the input files. Put the output files in the newly created
folder.</extracomment>
+- <translation type="unfinished"></translation>
++ <translation>Crear un nuevo folder en el folder de
origen</translation>
+ </message>
+ <message>
+ <source>Folder Name</source>
+- <translation type="unfinished"></translation>
++ <translation>Nombre de la carpeta</translation>
+ </message>
+ <message>
+ <source>Output to &source folder</source>
+ <extracomment>put the output files in the same folder as the input
files</extracomment>
+- <translation type="unfinished"></translation>
++ <translation>Salida a la carpeta de origen</translation>
+ </message>
+ <message>
+ <source>Please select at least one file.</source>
+@@ -253,7 +253,7 @@
+ </message>
+ <message>
+ <source>Searching for files...</source>
+- <translation type="unfinished"></translation>
++ <translation>Buscando archivos...</translation>
+ </message>
+ <message>
+ <source>Some files could not be found.</source>
+@@ -431,7 +431,7 @@
+ </message>
+ <message>
+ <source>Drag and drop files here to add tasks.</source>
+- <translation type="unfinished"></translation>
++ <translation>Arrastre y suelte los archivos aquí para añadir
tareas.</translation>
+ </message>
+ <message>
+ <source>Hide "%1"</source>
+@@ -607,7 +607,7 @@
+ </message>
+ <message>
+ <source>%1 not found</source>
+- <translation type="unfinished"></translation>
++ <translation>%1 no encontrado</translation>
+ </message>
+ </context>
+ <context>
+@@ -699,7 +699,7 @@
+ </message>
+ <message>
+ <source>Open output folder of the selected file.</source>
+- <translation type="unfinished"></translation>
++ <translation>Abrir carpeta de salida del archivo
seleccionado.</translation>
+ </message>
+ <message>
+ <source>About &FFmpeg</source>
+@@ -801,7 +801,7 @@
+ </message>
+ <message>
+ <source>Check For &Updates</source>
+- <translation type="unfinished"></translation>
++ <translation>Buscar &actualizaciones</translation>
+ </message>
+ <message>
+ <source>Cut</source>
+@@ -849,7 +849,7 @@
+ </message>
+ <message>
+ <source>This program is going to check for updates online. Do you allow
this program to use the Internet to check for updates?</source>
+- <translation type="unfinished"></translation>
++ <translation>Este programa va a comprobar si hay actualizaciones en línea.
¿Quiere dar permite a este programa a utilizar Internet para buscar
actualizaciones?</translation>
+ </message>
+ <message>
+ <source>Failed to load preset file. The application will quit
now.</source>
+@@ -862,7 +862,7 @@
+ <message>
+ <source>Converting %1/%2</source>
+ <extracomment>Converting the %1-th file in %2 files. %2 is the number of
files.</extracomment>
+- <translation type="unfinished"></translation>
++ <translation>Convirtiendo %1/%2</translation>
+ </message>
+ </context>
+ <context>
+@@ -870,7 +870,7 @@
+ <message>
+ <source>%1 not found.</source>
+ <extracomment>%1 is a computer program</extracomment>
+- <translation type="unfinished"></translation>
++ <translation>%1 no encontrado.</translation>
+ </message>
+ </context>
+ <context>
+@@ -881,19 +881,19 @@
+ </message>
+ <message>
+ <source>General</source>
+- <translation type="unfinished"></translation>
++ <translation>General</translation>
+ </message>
+ <message>
+ <source>Check for updates on program startup</source>
+- <translation type="unfinished"></translation>
++ <translation>Buscar actualizaciones al iniciar el
programa</translation>
+ </message>
+ <message>
+ <source>Automatically start conversion after adding files to the
list.</source>
+- <translation type="unfinished"></translation>
++ <translation>Iniciar automáticamente la conversión después de añadir
archivos a la lista.</translation>
+ </message>
+ <message>
+ <source>Start conversion automatically</source>
+- <translation type="unfinished"></translation>
++ <translation>Iniciar conversión automáticamente</translation>
+ </message>
+ <message>
+ <source>FFmpeg</source>
+@@ -925,7 +925,7 @@
+ </message>
+ <message>
+ <source>Command</source>
+- <translation type="unfinished"></translation>
++ <translation>Comando</translation>
+ </message>
+ </context>
+ <context>
+@@ -989,30 +989,30 @@
+ <name>PreviewDialog</name>
+ <message>
+ <source>Dialog</source>
+- <translation type="unfinished"></translation>
++ <translation>Diálogo</translation>
+ </message>
+ <message>
+ <source>Play Selected Range</source>
+- <translation type="unfinished"></translation>
++ <translation>Reproducir Rango Seleccionado</translation>
+ </message>
+ <message>
+ <source>%1 not found</source>
+- <translation type="unfinished"></translation>
++ <translation>%1 no encontrado</translation>
+ </message>
+ <message>
+ <source>Begin</source>
+ <extracomment>noun, the beginning of the video</extracomment>
+- <translation type="unfinished"></translation>
++ <translation>Inicio</translation>
+ </message>
+ <message>
+ <source>End</source>
+ <extracomment>noun, the end of the video</extracomment>
+- <translation type="unfinished"></translation>
++ <translation>Final</translation>
+ </message>
+ <message>
+ <source>Play %1~%2</source>
+ <extracomment>play the video from time %1 to time %2. %1 and %2 are time
in hh:mm:ss format.</extracomment>
+- <translation type="unfinished"></translation>
++ <translation>Reprodución %1~%2</translation>
+ </message>
+ </context>
+ <context>
+@@ -1030,11 +1030,11 @@
+ <name>UpdateDialog</name>
+ <message>
+ <source>Show &Release Notes</source>
+- <translation type="unfinished"></translation>
++ <translation>Ver Notas del lanzamiento.</translation>
+ </message>
+ <message>
+ <source>Check for updates on program startup</source>
+- <translation type="unfinished"></translation>
++ <translation>Buscar actualizaciones al iniciar el
programa</translation>
+ </message>
+ <message>
+ <source>Downloading update information...</source>
+@@ -1042,23 +1042,23 @@
+ </message>
+ <message>
+ <source>Cannot connect to server.</source>
+- <translation type="unfinished"></translation>
++ <translation>No se puede conectar al servidor.</translation>
+ </message>
+ <message>
+ <source>Failed to parse the received data.</source>
+- <translation type="unfinished"></translation>
++ <translation>Error al analizar los datos recibidos.</translation>
+ </message>
+ <message>
+ <source>You are already using the latest version of
QWinFF.</source>
+- <translation type="unfinished"></translation>
++ <translation>Ya está usando la versión mas reciente de
QWinFF.</translation>
+ </message>
+ <message>
+ <source>An unknown error has occurred.</source>
+- <translation type="unfinished"></translation>
++ <translation>Un error desconocido ha ocurrido.</translation>
+ </message>
+ <message>
+ <source>A new version of QWinFF has been released!</source>
+- <translation type="unfinished"></translation>
++ <translation>¡Una nueva versión de QWinFF ha sido
lanzada!</translation>
+ </message>
+ <message>
+ <source>Version <b>%1</b> is available at
%2.</source>
+@@ -1067,7 +1067,7 @@
+ </message>
+ <message>
+ <source>You can download this version using the link:</source>
+- <translation type="unfinished"></translation>
++ <translation>Puede descargar esta versión usando el
enlace:</translation>
+ </message>
+ </context>
+ </TS>
+diff --git a/src/translations/qwinff_fr_FR.ts b/src/translations/qwinff_fr.ts
+similarity index 98%
+rename from src/translations/qwinff_fr_FR.ts
+rename to src/translations/qwinff_fr.ts
+index b308fc1..efa9589 100644
+--- a/src/translations/qwinff_fr_FR.ts
++++ b/src/translations/qwinff_fr.ts
+@@ -1,4 +1,6 @@
+-<?xml version="1.0" ?><!DOCTYPE TS><TS language="fr"
version="2.0">
++<?xml version="1.0" encoding="utf-8"?>
++<!DOCTYPE TS>
++<TS version="2.1" language="fr">
+ <context>
+ <name>AboutDialog</name>
+ <message>
+@@ -19,12 +21,10 @@
+ </message>
+ <message>
+ <source>Portable</source>
+- <extracomment>Portable version (no installation, no writing
registry)</extracomment>
+ <translation>Portable</translation>
+ </message>
+ <message>
+ <source>Compiled with Qt %1</source>
+- <extracomment>Qt version</extracomment>
+ <translation>Compilé avec Qt %1</translation>
+ </message>
+ <message>
+@@ -37,12 +37,10 @@
+ </message>
+ <message>
+ <source>Programming: %1</source>
+- <extracomment>%1 is the name and email of the
programmer</extracomment>
+ <translation>Programmeur : %1</translation>
+ </message>
+ <message>
+ <source>Logo Design: %1</source>
+- <extracomment>%1 is the name and email of the logo
designer</extracomment>
+ <translation>Auteur du logo : %1</translation>
+ </message>
+ <message>
+@@ -121,6 +119,11 @@
+ <extracomment>Polish Language</extracomment>
+ <translation>Polonais</translation>
+ </message>
++ <message>
++ <source>French</source>
++ <extracomment>French Language</extracomment>
++ <translation type="unfinished"></translation>
++ </message>
+ </context>
+ <context>
+ <name>AboutFFmpegDialog</name>
+@@ -147,7 +150,6 @@
+ </message>
+ <message>
+ <source>Please visit %1 for more information.</source>
+- <extracomment>visit ffmpeg website</extracomment>
+ <translation>Pour plus d'informations visitez :
%1.</translation>
+ </message>
+ </context>
+@@ -435,7 +437,7 @@
+ </message>
+ <message>
+ <source>Hide "%1"</source>
+- <extracomment>Hide a column in the list. For example, the text maybe
'Hide "Duration"'. The two " are quotation marks in
English, you may replace it with local quotation marks.</extracomment>
++ <extracomment>Hide a column in the list. For example, the text maybe
'Hide "Duration"'. The two " are quotation
marks in English, you may replace it with local quotation marks.</extracomment>
+ <translation>Cacher "%1"</translation>
+ </message>
+ <message>
+@@ -1070,4 +1072,4 @@
+ <translation>Vous pouvez télécharger cette version depuis le lien
:</translation>
+ </message>
+ </context>
+-</TS>
+\ No newline at end of file
++</TS>
+diff --git a/src/translations/qwinff_pl_PL.ts b/src/translations/qwinff_pl_PL.ts
+index a625445..fbebbff 100644
+--- a/src/translations/qwinff_pl_PL.ts
++++ b/src/translations/qwinff_pl_PL.ts
+@@ -9,7 +9,7 @@
+ </message>
+ <message>
+ <source>Information</source>
+- <translation>Informacja </translation>
++ <translation>Informacje</translation>
+ </message>
+ <message>
+ <source>Translators</source>
+@@ -57,7 +57,7 @@
+ </message>
+ <message>
+ <source>FFmpeg presets were taken from WinFF.</source>
+- <translation type="unfinished"></translation>
++ <translation>Domyślne ustawienia FFmpeg pochodzą z
WinFF.</translation>
+ </message>
+ <message>
+ <source>Japanese</source>
+@@ -197,7 +197,7 @@
+ </message>
+ <message>
+ <source>Output Path</source>
+- <translation>Ścieżka wyjścia </translation>
++ <translation>Ścieżka zapisu konwersji </translation>
+ </message>
+ <message>
+ <source>Select &folder</source>
+@@ -312,9 +312,7 @@
+ </message>
+ <message>
+ <source>Volume</source>
+- <translation>Głośność
+-
+-</translation>
++ <translation>Głośność</translation>
+ </message>
+ <message>
+ <source>%</source>
+@@ -346,7 +344,7 @@
+ </message>
+ <message>
+ <source> px</source>
+- <translation> pikseli </translation>
++ <translation> Pikseli </translation>
+ </message>
+ <message>
+ <source>Height</source>
+@@ -354,7 +352,7 @@
+ </message>
+ <message>
+ <source>Crop</source>
+- <translation>Crop</translation>
++ <translation>Przytnij</translation>
+ </message>
+ <message>
+ <source>Time</source>
+@@ -369,7 +367,7 @@
+ <message>
+ <source>Cut</source>
+ <comment>Cut video; select a range to convert</comment>
+- <translation type="unfinished"></translation>
++ <translation>Cięcie</translation>
+ </message>
+ <message>
+ <source>&Preview</source>
+@@ -430,6 +428,7 @@
+
+ </source>
+ <translation>Komunikat o błędzie z FFmpeg:
++
+ </translation>
+ </message>
+ <message>
+@@ -494,7 +493,7 @@
+ </message>
+ <message>
+ <source>Video Codec</source>
+- <translation>Video kodek</translation>
++ <translation>Wideo kodek</translation>
+ </message>
+ <message>
+ <source>Progress</source>
+@@ -519,11 +518,11 @@
+ </message>
+ <message>
+ <source>KiB</source>
+- <translation>kB </translation>
++ <translation>KB </translation>
+ </message>
+ <message>
+ <source>MiB</source>
+- <translation>MB </translation>
++ <translation>MB</translation>
+ </message>
+ <message>
+ <source>GiB</source>
+@@ -574,7 +573,7 @@
+ <name>ExtraTranslations</name>
+ <message>
+ <source>Convert between media file formats</source>
+- <translation>Konwersja plików multimedialnych, pomiędzy różnymi
formatami</translation>
++ <translation>Konwersja plików multimedialnych pomiędzy różnymi
formatami.</translation>
+ </message>
+ <message>
+ <source>Media Converter</source>
+@@ -590,27 +589,27 @@
+ </message>
+ <message>
+ <source>Mark as Begin</source>
+- <translation type="unfinished"></translation>
++ <translation>Wskaż jako nowy początek</translation>
+ </message>
+ <message>
+ <source>Seek to Begin</source>
+- <translation type="unfinished"></translation>
++ <translation>Skocz do nowego początku</translation>
+ </message>
+ <message>
+ <source>Play Selection</source>
+- <translation type="unfinished"></translation>
++ <translation>Odtwórz wybrany materiał </translation>
+ </message>
+ <message>
+ <source>Mark as End</source>
+- <translation type="unfinished"></translation>
++ <translation>Wskaż jako nowy koniec </translation>
+ </message>
+ <message>
+ <source>Seek to End</source>
+- <translation type="unfinished"></translation>
++ <translation>Skocz do nowego końca</translation>
+ </message>
+ <message>
+ <source>%1 not found</source>
+- <translation type="unfinished"></translation>
++ <translation>% 1 nie został znaleziony</translation>
+ </message>
+ </context>
+ <context>
+@@ -809,7 +808,7 @@
+ <message>
+ <source>Cut</source>
+ <extracomment>Cut video file (select a time range to
conert)</extracomment>
+- <translation type="unfinished"></translation>
++ <translation>Cięcie</translation>
+ </message>
+ <message>
+ <source>All tasks have finished.</source>
+@@ -992,30 +991,30 @@
+ <name>PreviewDialog</name>
+ <message>
+ <source>Dialog</source>
+- <translation type="unfinished"></translation>
++ <translation>Dialog</translation>
+ </message>
+ <message>
+ <source>Play Selected Range</source>
+- <translation type="unfinished"></translation>
++ <translation>Odtwórz zaznaczony materiał </translation>
+ </message>
+ <message>
+ <source>%1 not found</source>
+- <translation type="unfinished"></translation>
++ <translation>%1 nie znaleziono</translation>
+ </message>
+ <message>
+ <source>Begin</source>
+ <extracomment>noun, the beginning of the video</extracomment>
+- <translation type="unfinished"></translation>
++ <translation>Początek</translation>
+ </message>
+ <message>
+ <source>End</source>
+ <extracomment>noun, the end of the video</extracomment>
+- <translation type="unfinished"></translation>
++ <translation>Koniec</translation>
+ </message>
+ <message>
+ <source>Play %1~%2</source>
+ <extracomment>play the video from time %1 to time %2. %1 and %2 are time
in hh:mm:ss format.</extracomment>
+- <translation type="unfinished"></translation>
++ <translation>Odtwarzanie %1~%2</translation>
+ </message>
+ </context>
+ <context>
+diff --git a/src/translations/qwinff_pt_BR.ts b/src/translations/qwinff_pt_BR.ts
+index 11d5eac..49a3e74 100644
+--- a/src/translations/qwinff_pt_BR.ts
++++ b/src/translations/qwinff_pt_BR.ts
+@@ -1,4 +1,6 @@
+-<?xml version="1.0" ?><!DOCTYPE TS><TS
language="pt_BR" version="2.0">
++<?xml version="1.0" encoding="utf-8"?>
++<!DOCTYPE TS>
++<TS version="2.1" language="pt_BR">
+ <context>
+ <name>AboutDialog</name>
+ <message>
+@@ -19,12 +21,10 @@
+ </message>
+ <message>
+ <source>Portable</source>
+- <extracomment>Portable version (no installation, no writing
registry)</extracomment>
+ <translation>Portátil</translation>
+ </message>
+ <message>
+ <source>Compiled with Qt %1</source>
+- <extracomment>Qt version</extracomment>
+ <translation>Compilado com Qt %1</translation>
+ </message>
+ <message>
+@@ -37,12 +37,10 @@
+ </message>
+ <message>
+ <source>Programming: %1</source>
+- <extracomment>%1 is the name and email of the
programmer</extracomment>
+ <translation>Programação: %1</translation>
+ </message>
+ <message>
+ <source>Logo Design: %1</source>
+- <extracomment>%1 is the name and email of the logo
designer</extracomment>
+ <translation>Logo Design: %1</translation>
+ </message>
+ <message>
+@@ -121,6 +119,11 @@
+ <extracomment>Polish Language</extracomment>
+ <translation>Polonês</translation>
+ </message>
++ <message>
++ <source>French</source>
++ <extracomment>French Language</extracomment>
++ <translation type="unfinished"></translation>
++ </message>
+ </context>
+ <context>
+ <name>AboutFFmpegDialog</name>
+@@ -147,7 +150,6 @@
+ </message>
+ <message>
+ <source>Please visit %1 for more information.</source>
+- <extracomment>visit ffmpeg website</extracomment>
+ <translation>Por favor, visite %1 para mais
informações.</translation>
+ </message>
+ </context>
+@@ -435,7 +437,7 @@
+ </message>
+ <message>
+ <source>Hide "%1"</source>
+- <extracomment>Hide a column in the list. For example, the text maybe
'Hide "Duration"'. The two " are quotation marks in
English, you may replace it with local quotation marks.</extracomment>
++ <extracomment>Hide a column in the list. For example, the text maybe
'Hide "Duration"'. The two " are quotation
marks in English, you may replace it with local quotation marks.</extracomment>
+ <translation>Ocultar "%1"</translation>
+ </message>
+ <message>
+@@ -1070,4 +1072,4 @@
+ <translation>Você pode baixar essa versão usando o
link:</translation>
+ </message>
+ </context>
+-</TS>
+\ No newline at end of file
++</TS>
+
+From d7dc95a06ef7e82579a6b1f1f3e44cf9529de3f3 Mon Sep 17 00:00:00 2001
+From: leigh123linux <leigh123linux(a)fedoraproject.org>
+Date: Mon, 30 May 2016 11:30:07 +0100
+Subject: [PATCH 03/10] Fix desktop file
+
+This commit added French locale but labelled it as Italian
+
+https://github.com/qwinff/qwinff/commit/0c55ba621e5b805fb59f6389729becefa1c2e66d
+---
+ qwinff.desktop | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/qwinff.desktop b/qwinff.desktop
+index f0e7636..939d45a 100644
+--- a/qwinff.desktop
++++ b/qwinff.desktop
+@@ -21,7 +21,7 @@ GenericName[zh_CN]=影音转换器
+ GenericName[cs]=Převodník médií
+ GenericName[es]=Convertidor de Medios
+ GenericName[it]=Convertitore di file multimediali
+-GenericName[it]=Convertisseur de fichier multimédia
++GenericName[fr]=Convertisseur de fichier multimédia
+ GenericName[ja]=メディア変換
+ GenericName[ro]=Media Converter
+ GenericName[ru]=Медиа-конвертер
+
+From bccaf85fee515318bd1ec041d182d6940ded2e2b Mon Sep 17 00:00:00 2001
+From: Che-Huai Lin <lzh9102(a)gmail.com>
+Date: Fri, 11 Nov 2016 21:32:00 +0800
+Subject: [PATCH 04/10] Add simple travis.yml
+
+---
+ .travis.yml | 7 +++++++
+ 1 file changed, 7 insertions(+)
+ create mode 100644 .travis.yml
+
+diff --git a/.travis.yml b/.travis.yml
+new file mode 100644
+index 0000000..e96f8e4
+--- /dev/null
++++ b/.travis.yml
+@@ -0,0 +1,7 @@
++before_install:
++ - sudo apt-get update
++ - sudo apt-get install libqt4-dev
++
++script:
++ - make
++ - make check
+
+From 5c017b42dc5cff2fce275ce2f5a1893e2db7ceb2 Mon Sep 17 00:00:00 2001
+From: Che-Huai Lin <lzh9102(a)gmail.com>
+Date: Fri, 11 Nov 2016 21:44:09 +0800
+Subject: [PATCH 05/10] travis-ci: add xvfb to enable qt unit tests
+
+---
+ .travis.yml | 3 +++
+ 1 file changed, 3 insertions(+)
+
+diff --git a/.travis.yml b/.travis.yml
+index e96f8e4..10b6920 100644
+--- a/.travis.yml
++++ b/.travis.yml
+@@ -1,6 +1,9 @@
+ before_install:
+ - sudo apt-get update
+ - sudo apt-get install libqt4-dev
++ - export DISPLAY=:99.0
++ - sh -e /etc/init.d/xvfb start
++ - sleep 3 # give xvfb some time to start
+
+ script:
+ - make
+
+From b287fa4447e8c6014fc8882f77d593029cb03249 Mon Sep 17 00:00:00 2001
+From: Che-Huai Lin <lzh9102(a)gmail.com>
+Date: Fri, 11 Nov 2016 21:51:42 +0800
+Subject: [PATCH 06/10] travis-ci: build with and without libnotify
+
+---
+ .travis.yml | 7 ++++++-
+ 1 file changed, 6 insertions(+), 1 deletion(-)
+
+diff --git a/.travis.yml b/.travis.yml
+index 10b6920..4551b1d 100644
+--- a/.travis.yml
++++ b/.travis.yml
+@@ -5,6 +5,11 @@ before_install:
+ - sh -e /etc/init.d/xvfb start
+ - sleep 3 # give xvfb some time to start
+
++env:
++ matrix:
++ - USE_LIBNOTIFY=0
++ - USE_LIBNOTIFY=1
++
+ script:
+- - make
++ - make USE_LIBNOTIFY=$USE_LIBNOTIFY
+ - make check
+
+From efb5b0ea4e06d1c46445ea5ab17c306134976fed Mon Sep 17 00:00:00 2001
+From: Che-Huai Lin <lzh9102(a)gmail.com>
+Date: Fri, 11 Nov 2016 21:55:22 +0800
+Subject: [PATCH 07/10] travis-ci: fix libnotify dependency and set language to
+ c++
+
+---
+ .travis.yml | 3 +++
+ 1 file changed, 3 insertions(+)
+
+diff --git a/.travis.yml b/.travis.yml
+index 4551b1d..85f64b6 100644
+--- a/.travis.yml
++++ b/.travis.yml
+@@ -1,6 +1,9 @@
++language: cpp
++
+ before_install:
+ - sudo apt-get update
+ - sudo apt-get install libqt4-dev
++ - if [ "$USE_LIBNOTIFY" == 1 ]; then sudo apt-get install libnotify-dev; fi
+ - export DISPLAY=:99.0
+ - sh -e /etc/init.d/xvfb start
+ - sleep 3 # give xvfb some time to start
+
+From da70129d6806e6d12defdee516856d558af60931 Mon Sep 17 00:00:00 2001
+From: Che-Huai Lin <lzh9102(a)gmail.com>
+Date: Sun, 18 Jun 2017 15:47:19 +0800
+Subject: [PATCH 08/10] ConversionParameters: remove unused method clear()
+
+---
+ src/converter/conversionparameters.h | 50 ++++++++++++------------------------
+ 1 file changed, 17 insertions(+), 33 deletions(-)
+
+diff --git a/src/converter/conversionparameters.h b/src/converter/conversionparameters.h
+index d7ecdf4..b24b510 100644
+--- a/src/converter/conversionparameters.h
++++ b/src/converter/conversionparameters.h
+@@ -79,39 +79,23 @@ class ConversionParameters
+ static ConversionParameters fromFFmpegParameters(const char *params_str);
+
+ ConversionParameters()
+- {
+- clear();
+- }
+-
+- void clear()
+- {
+- source.clear();
+- destination.clear();
+- threads = 0;
+-
+- disable_audio = false;
+- audio_keep_sample_rate = false;
+- audio_bitrate = 0;
+- audio_sample_rate = 0;
+- audio_channels = 0;
+- audio_volume = 0;
+-
+- disable_video = false;
+- video_same_quality = false;
+- video_deinterlace = false;
+- video_bitrate = 0;
+- video_crop_top = video_crop_bottom = video_crop_left = video_crop_right = 0;
+-
+- video_width = video_height = 0;
+-
+- time_begin = time_end = 0;
+-
+- ffmpeg_options.clear();
+-
+- speed_scaling = false;
+- speed_scaling_factor = 1.0;
+- }
+-
++ : threads(0),
++ disable_audio(false),
++ audio_bitrate(0),
++ audio_sample_rate(0),
++ audio_keep_sample_rate(false),
++ audio_channels(0),
++ audio_volume(0),
++ disable_video(false),
++ video_same_quality(false),
++ video_deinterlace(false),
++ video_bitrate(0),
++ video_width(0), video_height(0),
++ video_crop_top(0), video_crop_bottom(0),
++ video_crop_left(0), video_crop_right(0),
++ time_begin(0), time_end(0),
++ speed_scaling(false), speed_scaling_factor(1.0)
++ { }
+ };
+
+ #endif // CONVERSIONPARAMETERS_H
+
+From ccd1e5336bf1e6ffbc5be3cf5f67d6e7702e4f19 Mon Sep 17 00:00:00 2001
+From: Che-Huai Lin <lzh9102(a)gmail.com>
+Date: Sun, 18 Jun 2017 16:06:41 +0800
+Subject: [PATCH 09/10] Add conversion options to allow copying audio/video
+ data without re-encoding
+
+---
+ src/converter/conversionparameters.h | 4 ++
+ src/converter/ffmpeginterface.cpp | 6 +++
+ src/ui/conversionparameterdialog.cpp | 26 ++++++++++++
+ src/ui/conversionparameterdialog.h | 2 +
+ src/ui/conversionparameterdialog.ui | 76 +++++++++++++++---------------------
+ 5 files changed, 70 insertions(+), 44 deletions(-)
+
+diff --git a/src/converter/conversionparameters.h b/src/converter/conversionparameters.h
+index b24b510..3cd0b5b 100644
+--- a/src/converter/conversionparameters.h
++++ b/src/converter/conversionparameters.h
+@@ -30,6 +30,7 @@ class ConversionParameters
+ int threads; ///< how many threads to use in conversion
+
+ bool disable_audio;
++ bool copy_audio;
+ int audio_bitrate;
+ int audio_sample_rate;
+ bool audio_keep_sample_rate; ///< whether to keep original audio sample rate
+@@ -37,6 +38,7 @@ class ConversionParameters
+ int audio_volume; ///< output volume in binary percent (256 is normal, 512 is
double)
+
+ bool disable_video;
++ bool copy_video;
+ bool video_same_quality; ///< whether to keep all video quality (-sameq option in
ffmpeg)
+ bool video_deinterlace;
+ int video_bitrate;
+@@ -81,12 +83,14 @@ class ConversionParameters
+ ConversionParameters()
+ : threads(0),
+ disable_audio(false),
++ copy_audio(false),
+ audio_bitrate(0),
+ audio_sample_rate(0),
+ audio_keep_sample_rate(false),
+ audio_channels(0),
+ audio_volume(0),
+ disable_video(false),
++ copy_video(false),
+ video_same_quality(false),
+ video_deinterlace(false),
+ video_bitrate(0),
+diff --git a/src/converter/ffmpeginterface.cpp b/src/converter/ffmpeginterface.cpp
+index 395e379..632a1ef 100644
+--- a/src/converter/ffmpeginterface.cpp
++++ b/src/converter/ffmpeginterface.cpp
+@@ -403,6 +403,9 @@ QStringList FFmpegInterface::Private::getOptionList(const
ConversionParameters &
+ // Audio Options
+ if (o.disable_audio) {
+ list.append("-an"); // no audio
++ } else if (o.copy_audio) { // copy audio data (no re-encode)
++ list.append("-acodec");
++ list.append("copy");
+ } else { // audio enabled
+
+ // audio bitrate in kb/s
+@@ -444,6 +447,9 @@ QStringList FFmpegInterface::Private::getOptionList(const
ConversionParameters &
+ // Video Options
+ if (o.disable_video || !probe.hasVideo()) {
+ list.append("-vn"); // no video
++ } else if (o.copy_video) { // copy video data (no re-encode)
++ list.append("-vcodec");
++ list.append("copy");
+ } else { // video enabled
+
+ // same video quality as source
+diff --git a/src/ui/conversionparameterdialog.cpp b/src/ui/conversionparameterdialog.cpp
+index d58561d..2d1b5ca 100644
+--- a/src/ui/conversionparameterdialog.cpp
++++ b/src/ui/conversionparameterdialog.cpp
+@@ -59,6 +59,10 @@ ConversionParameterDialog::ConversionParameterDialog(QWidget *parent)
:
+ connect(ui->btnPreview, SIGNAL(clicked()),
+ this, SLOT(preview_time_selection()));
+ connect(ui->btnInteractiveCutting, SIGNAL(clicked()),
SLOT(interactive_cutting()));
++ connect(ui->chkDisableAudio, SIGNAL(toggled(bool)),
SLOT(audio_tab_update_enabled_widgets()));
++ connect(ui->chkCopyAudio, SIGNAL(toggled(bool)),
SLOT(audio_tab_update_enabled_widgets()));
++ connect(ui->chkDisableVideo, SIGNAL(toggled(bool)),
SLOT(video_tab_update_enabled_widgets()));
++ connect(ui->chkCopyVideo, SIGNAL(toggled(bool)),
SLOT(video_tab_update_enabled_widgets()));
+
+ // Hide speed-changing options if sox is not available.
+ m_enableAudioProcessing = AudioFilter::available();
+@@ -211,6 +215,7 @@ void
ConversionParameterDialog::write_fields(ConversionParameters& param)
+
+ // Audio Options
+ param.disable_audio = ui->chkDisableAudio->isChecked();
++ param.copy_audio = ui->chkCopyAudio->isChecked();
+ param.audio_sample_rate = ui->cbAudioSampleRate->currentText().toInt();
+ param.audio_bitrate = ui->spinAudioBitrate->value();
+ param.audio_channels = ui->spinChannels->value();
+@@ -218,6 +223,7 @@ void
ConversionParameterDialog::write_fields(ConversionParameters& param)
+
+ // Video Options
+ param.disable_video = ui->chkDisableVideo->isChecked();
++ param.copy_video = ui->chkCopyVideo->isChecked();
+ param.video_bitrate = ui->spinVideoBitrate->value();
+ param.video_same_quality = ui->chkVideoSameQuality->isChecked();
+ param.video_deinterlace = ui->chkDeinterlace->isChecked();
+@@ -249,3 +255,23 @@ void
ConversionParameterDialog::write_fields(ConversionParameters& param)
+ }
+
+ }
++
++void ConversionParameterDialog::audio_tab_update_enabled_widgets()
++{
++ bool disable_audio = ui->chkDisableAudio->isChecked();
++ bool copy_audio = ui->chkCopyAudio->isChecked();
++
++ ui->chkDisableAudio->setEnabled(true); // always enabled
++ ui->chkCopyAudio->setEnabled(!disable_audio);
++ ui->groupAudioOptions->setEnabled(!disable_audio && !copy_audio);
++}
++
++void ConversionParameterDialog::video_tab_update_enabled_widgets()
++{
++ bool disable_video= ui->chkDisableVideo->isChecked();
++ bool copy_video = ui->chkCopyVideo->isChecked();
++
++ ui->chkDisableVideo->setEnabled(true); // always enabled
++ ui->chkCopyVideo->setEnabled(!disable_video);
++ ui->groupVideoOptions->setEnabled(!disable_video && !copy_video);
++}
+diff --git a/src/ui/conversionparameterdialog.h b/src/ui/conversionparameterdialog.h
+index ca44e59..4e88f1a 100644
+--- a/src/ui/conversionparameterdialog.h
++++ b/src/ui/conversionparameterdialog.h
+@@ -51,6 +51,8 @@ private slots:
+ void preview_time_selection();
+ void interactive_cutting();
+ AbstractPreviewer *create_previewer();
++ void audio_tab_update_enabled_widgets();
++ void video_tab_update_enabled_widgets();
+
+ private:
+ Ui::ConversionParameterDialog *ui;
+diff --git a/src/ui/conversionparameterdialog.ui b/src/ui/conversionparameterdialog.ui
+index da88f88..6432268 100644
+--- a/src/ui/conversionparameterdialog.ui
++++ b/src/ui/conversionparameterdialog.ui
+@@ -33,11 +33,22 @@
+ </attribute>
+ <layout class="QVBoxLayout" name="verticalLayout_2">
+ <item>
+- <widget class="QCheckBox" name="chkDisableAudio">
+- <property name="text">
+- <string>Disable Audio</string>
+- </property>
+- </widget>
++ <layout class="QHBoxLayout"
name="horizontalLayout_11">
++ <item>
++ <widget class="QCheckBox" name="chkDisableAudio">
++ <property name="text">
++ <string>Disable Audio</string>
++ </property>
++ </widget>
++ </item>
++ <item>
++ <widget class="QCheckBox" name="chkCopyAudio">
++ <property name="text">
++ <string>Copy Audio (Do not re-encode)</string>
++ </property>
++ </widget>
++ </item>
++ </layout>
+ </item>
+ <item>
+ <widget class="QGroupBox" name="groupAudioOptions">
+@@ -173,11 +184,22 @@
+ </attribute>
+ <layout class="QVBoxLayout" name="verticalLayout_3">
+ <item>
+- <widget class="QCheckBox" name="chkDisableVideo">
+- <property name="text">
+- <string>Disable Video</string>
+- </property>
+- </widget>
++ <layout class="QHBoxLayout"
name="horizontalLayout_13">
++ <item>
++ <widget class="QCheckBox" name="chkDisableVideo">
++ <property name="text">
++ <string>Disable Video</string>
++ </property>
++ </widget>
++ </item>
++ <item>
++ <widget class="QCheckBox" name="chkCopyVideo">
++ <property name="text">
++ <string>Copy Video (Do not re-encode)</string>
++ </property>
++ </widget>
++ </item>
++ </layout>
+ </item>
+ <item>
+ <widget class="QGroupBox" name="groupVideoOptions">
+@@ -533,7 +555,6 @@
+ </layout>
+ </widget>
+ <tabstops>
+- <tabstop>chkDisableAudio</tabstop>
+ <tabstop>cbAudioSampleRate</tabstop>
+ <tabstop>spinAudioBitrate</tabstop>
+ <tabstop>spinChannels</tabstop>
+@@ -547,7 +568,6 @@
+ <tabstop>spinCropBottom</tabstop>
+ <tabstop>txtFFmpegOptions</tabstop>
+ <tabstop>buttonBox</tabstop>
+- <tabstop>chkDisableVideo</tabstop>
+ </tabstops>
+ <resources>
+ <include location="../images.qrc"/>
+@@ -585,37 +605,5 @@
+ </hint>
+ </hints>
+ </connection>
+- <connection>
+- <sender>chkDisableAudio</sender>
+- <signal>toggled(bool)</signal>
+- <receiver>groupAudioOptions</receiver>
+- <slot>setDisabled(bool)</slot>
+- <hints>
+- <hint type="sourcelabel">
+- <x>113</x>
+- <y>56</y>
+- </hint>
+- <hint type="destinationlabel">
+- <x>229</x>
+- <y>266</y>
+- </hint>
+- </hints>
+- </connection>
+- <connection>
+- <sender>chkDisableVideo</sender>
+- <signal>toggled(bool)</signal>
+- <receiver>groupVideoOptions</receiver>
+- <slot>setDisabled(bool)</slot>
+- <hints>
+- <hint type="sourcelabel">
+- <x>236</x>
+- <y>56</y>
+- </hint>
+- <hint type="destinationlabel">
+- <x>227</x>
+- <y>270</y>
+- </hint>
+- </hints>
+- </connection>
+ </connections>
+ </ui>
+
+From 3420e8ed6c569da4ddd45c72cd261fb6235c4b33 Mon Sep 17 00:00:00 2001
+From: Che-Huai Lin <lzh9102(a)gmail.com>
+Date: Sun, 18 Jun 2017 16:19:53 +0800
+Subject: [PATCH 10/10] ConversionParameterDialog: correctly read audio/video
+ copy option
+
+---
+ src/ui/conversionparameterdialog.cpp | 2 ++
+ 1 file changed, 2 insertions(+)
+
+diff --git a/src/ui/conversionparameterdialog.cpp b/src/ui/conversionparameterdialog.cpp
+index 2d1b5ca..0b0e292 100644
+--- a/src/ui/conversionparameterdialog.cpp
++++ b/src/ui/conversionparameterdialog.cpp
+@@ -134,6 +134,7 @@ void ConversionParameterDialog::read_fields(const
ConversionParameters& param)
+
+ // Audio Options
+ ui->chkDisableAudio->setChecked(param.disable_audio);
++ ui->chkCopyAudio->setChecked(param.copy_audio);
+
+ ui->spinAudioBitrate->setValue(param.audio_bitrate);
+
+@@ -148,6 +149,7 @@ void ConversionParameterDialog::read_fields(const
ConversionParameters& param)
+
+ // Video Options
+ ui->chkDisableVideo->setChecked(param.disable_video);
++ ui->chkCopyVideo->setChecked(param.copy_video);
+
+ ui->spinVideoBitrate->setValue(param.video_bitrate);
+
diff --git a/qwinff.spec b/qwinff.spec
new file mode 100644
index 0000000..aa5634d
--- /dev/null
+++ b/qwinff.spec
@@ -0,0 +1,68 @@
+# defines for the specific github commit
+%global gitdate 20171107
+%global p1version 0.2.1
+%global commit 3420e8ed6c569da4ddd45c72cd261fb6235c4b33
+%global shortcommit %(c=%{commit}; echo ${c:0:7})
+%global gver .%{gitdate}git%{shortcommit}
+%global vidstr :%{gitdate}git%{shortcommit}
+
+Summary: An intuitive media converter GUI for ffmpeg
+Name: qwinff
+Version: 0.2.2
+Release: 0.1%{?gver}%{?dist}
+License: GPLv3
+URL:
http://qwinff.github.io/
+Source:
https://github.com/qwinff/%{name}/archive/v%{p1version}/%{name}-%{p1versi...
+Patch1:
https://github.com/qwinff/%{name}/compare/v%{p1version}...%{commit}.patch...
+Patch2: qwinff-extradefs.patch
+Patch3:
https://github.com/qwinff/%{name}/pull/21.patch#/qwinff-perex1.patch
+Patch4:
https://github.com/qwinff/%{name}/pull/22.patch#/qwinff-perex2.patch
+Patch5:
https://github.com/qwinff/%{name}/pull/23.patch#/qwinff-perex3.patch
+Patch6:
https://github.com/qwinff/%{name}/pull/24.patch#/qwinff-perex4.patch
+BuildRequires: qt5-devel
+#BuildRequires: gtk2-devel
+BuildRequires: pkgconfig(libnotify)
+BuildRequires: desktop-file-utils
+Requires: ffmpeg
+Requires: sox
+
+%description
+QWinFF is a cross-platform, easy-to-use media converter front-end to FFmpeg.
+FFmpeg is a powerful command-line utility to convert audio and video file
+into numerous formats. QWinFF features a rich set of presets to help users
+use FFmpeg easily without having to manually input command-line flags.
+Average users can convert multiple media files in just a few clicks,
+while advanced users can still adjust conversion parameters in detail.
+
+%prep
+%setup -q -n %{name}-%{p1version}
+%patch1 -p1 -b .post
+%patch2 -p1 -b .extradefs
+%patch3 -p1 -b .perex1
+%patch4 -p1 -b .perex2
+%patch5 -p1 -b .perex3
+%patch6 -p1 -b .perex4
+
+%build
+%make_build QMAKE=qmake-qt5 %{?_qt5_qmake_flags} \
+ LRELEASE=lrelease-qt5 \
+ USE_LIBNOTIFY=1 \
+ VIDSTR="%{?vidstr}"
+
+%install
+%make_install
+desktop-file-validate %{buildroot}/%{_datadir}/applications/qwinff.desktop
+
+%files
+%{!?_licensedir:%global license %%doc}
+%license COPYING.txt
+%doc CHANGELOG.txt README.md
+%{_bindir}/qwinff
+%{_datadir}/applications/qwinff.desktop
+%{_datadir}/pixmaps/qwinff.png
+%{_datadir}/qwinff
+%{_mandir}/man1/qwinff.1.*
+
+%changelog
+* Tue Nov 7 2017 Jaroslav Kysela <perex(a)perex.cz> - 0.2.2-0.1.20171107git3420e8e
+- Initial version
diff --git a/sources b/sources
index e69de29..6495a94 100644
--- a/sources
+++ b/sources
@@ -0,0 +1 @@
+38ec02aecea2a7cc2ef51d5d7ed9205a qwinff-0.2.1.tar.gz