[vlmc-devel] [PATCH 03/12] MainWindow: Remove usage of WorkflowFileRenderer
Yikai Lu
luyikei.qmltu at gmail.com
Wed Apr 6 09:58:16 CEST 2016
---
src/Gui/MainWindow.cpp | 12 ++----------
src/Gui/MainWindow.h | 2 --
2 files changed, 2 insertions(+), 12 deletions(-)
diff --git a/src/Gui/MainWindow.cpp b/src/Gui/MainWindow.cpp
index 012420a..1a91087 100644
--- a/src/Gui/MainWindow.cpp
+++ b/src/Gui/MainWindow.cpp
@@ -42,7 +42,6 @@
#include "EffectsEngine/EffectsEngine.h"
#include "Backend/IBackend.h"
#include "Workflow/MainWorkflow.h"
-#include "Renderer/WorkflowFileRenderer.h"
#include "Renderer/WorkflowRenderer.h"
#include "Renderer/ClipRenderer.h"
@@ -73,7 +72,6 @@
MainWindow::MainWindow( Backend::IBackend* backend, QWidget *parent )
: QMainWindow( parent )
, m_backend( backend )
- , m_fileRenderer( nullptr )
, m_projectPreferences( nullptr )
, m_wizard( nullptr )
{
@@ -139,8 +137,6 @@ MainWindow::MainWindow( Backend::IBackend* backend, QWidget *parent )
MainWindow::~MainWindow()
{
- if ( m_fileRenderer )
- delete m_fileRenderer;
delete m_importController;
}
@@ -607,15 +603,11 @@ MainWindow::renderVideo( const QString& outputFileName, quint32 width, quint32 h
double fps, const QString& ar,
quint32 vbitrate, quint32 abitrate )
{
- if ( m_fileRenderer )
- delete m_fileRenderer;
- m_fileRenderer = new WorkflowFileRenderer( m_backend, Core::instance()->workflow() );
-
- WorkflowFileRendererDialog *dialog = new WorkflowFileRendererDialog( m_fileRenderer, width, height );
+ WorkflowFileRendererDialog *dialog = new WorkflowFileRendererDialog( width, height );
dialog->setModal( true );
dialog->setOutputFileName( outputFileName );
- m_fileRenderer->run( outputFileName, width, height, fps, ar, vbitrate, abitrate );
+ Core::instance()->workflowRenderer()->startRenderToFile( outputFileName );
if ( dialog->exec() == QDialog::Rejected )
{
diff --git a/src/Gui/MainWindow.h b/src/Gui/MainWindow.h
index 3e50a12..8f97d3a 100644
--- a/src/Gui/MainWindow.h
+++ b/src/Gui/MainWindow.h
@@ -42,7 +42,6 @@ class Project;
class ProjectWizard;
class SettingsDialog;
class Timeline;
-class WorkflowFileRenderer;
class WorkflowRenderer;
namespace Backend
@@ -133,7 +132,6 @@ private:
Backend::IBackend* m_backend;
PreviewWidget* m_clipPreview;
PreviewWidget* m_projectPreview;
- WorkflowFileRenderer* m_fileRenderer;
SettingsDialog* m_globalPreferences;
SettingsDialog* m_DefaultProjectPreferences;
SettingsDialog* m_projectPreferences;
--
1.9.1
More information about the Vlmc-devel
mailing list