added UI for VBR and noise object
This commit is contained in:
@@ -515,3 +515,9 @@ void ExportDialog::on_renderCancel_clicked() {
|
||||
et->continueEncode = false;
|
||||
cancelled = true;
|
||||
}
|
||||
|
||||
void ExportDialog::on_vcodecCombobox_currentIndexChanged(int index) {
|
||||
bool vbrEnabled = (format_vcodecs.size() > 0 && format_vcodecs.at(index) == AV_CODEC_ID_H264);
|
||||
ui->compressionTypeCombobox->setEnabled(vbrEnabled);
|
||||
if (!vbrEnabled) ui->compressionTypeCombobox->setCurrentIndex(0);
|
||||
}
|
||||
|
||||
@@ -31,6 +31,8 @@ private slots:
|
||||
|
||||
void render_thread_finished();
|
||||
|
||||
void on_vcodecCombobox_currentIndexChanged(int index);
|
||||
|
||||
private:
|
||||
Ui::ExportDialog *ui;
|
||||
|
||||
|
||||
+28
-2
@@ -7,7 +7,7 @@
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>358</width>
|
||||
<height>442</height>
|
||||
<height>470</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="windowTitle">
|
||||
@@ -123,7 +123,7 @@
|
||||
<item row="5" column="0">
|
||||
<widget class="QLabel" name="label_6">
|
||||
<property name="text">
|
||||
<string>Bitrate (Mbps/CBR):</string>
|
||||
<string>Bitrate (Mbps):</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
@@ -137,6 +137,32 @@
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="4" column="0">
|
||||
<widget class="QLabel" name="label_11">
|
||||
<property name="text">
|
||||
<string>Compression Type:</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="4" column="1">
|
||||
<widget class="QComboBox" name="compressionTypeCombobox">
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>Constant Bitrate</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>Variable Bitrate (One-Pass)</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>Variable Bitrate (Two-Pass)</string>
|
||||
</property>
|
||||
</item>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</item>
|
||||
|
||||
@@ -1242,6 +1242,11 @@ void Timeline::on_addButton_clicked() {
|
||||
toneMenuItem->setData(ADD_OBJ_TONE);
|
||||
add_menu.addAction(toneMenuItem);
|
||||
|
||||
QAction* noiseMenuItem = new QAction(&add_menu);
|
||||
noiseMenuItem->setText("Noise...");
|
||||
noiseMenuItem->setData(ADD_OBJ_NOISE);
|
||||
add_menu.addAction(noiseMenuItem);
|
||||
|
||||
connect(&add_menu, SIGNAL(triggered(QAction*)), this, SLOT(addMenuItem(QAction*)));
|
||||
|
||||
add_menu.exec(QCursor::pos());
|
||||
|
||||
@@ -14,6 +14,7 @@
|
||||
#define ADD_OBJ_SOLID 1
|
||||
#define ADD_OBJ_BARS 2
|
||||
#define ADD_OBJ_TONE 3
|
||||
#define ADD_OBJ_NOISE 4
|
||||
|
||||
class QPushButton;
|
||||
class SourceTable;
|
||||
|
||||
@@ -400,6 +400,7 @@ void TimelineWidget::mousePressEvent(QMouseEvent *event) {
|
||||
comp = -1;
|
||||
break;
|
||||
case ADD_OBJ_TONE:
|
||||
case ADD_OBJ_NOISE:
|
||||
comp = 1;
|
||||
break;
|
||||
}
|
||||
@@ -591,7 +592,11 @@ void TimelineWidget::mouseReleaseEvent(QMouseEvent *event) {
|
||||
break;
|
||||
case ADD_OBJ_TONE:
|
||||
c->name = "Tone";
|
||||
c->effects.append(create_effect(VIDEO_TEXT_EFFECT, c));
|
||||
c->effects.append(create_effect(AUDIO_TONE_EFFECT, c));
|
||||
break;
|
||||
case ADD_OBJ_NOISE:
|
||||
c->name = "Noise";
|
||||
c->effects.append(create_effect(AUDIO_NOISE_EFFECT, c));
|
||||
break;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user