Commit 0d344b4a authored by luyikei's avatar luyikei Committed by Hugo Beauzée-Luyssen

Rename GenericRenderer to AbstractRenderer

Signed-off-by: 's avatarHugo Beauzée-Luyssen <hugo@beauzee.fr>
parent 41bfd082
......@@ -65,7 +65,7 @@ SET(VLMC_SRCS
Project/Workspace.cpp
Project/WorkspaceWorker.cpp
Project/RecentProjects.cpp
Renderer/GenericRenderer.cpp
Renderer/AbstractRenderer.cpp
Renderer/WorkflowRenderer.cpp
Services/AbstractSharingService.h
Services/UploaderIODevice.cpp
......
......@@ -119,7 +119,7 @@ MainWindow::MainWindow( Backend::IBackend* backend, QWidget *parent )
//Connecting Library stuff:
const ClipRenderer* clipRenderer = qobject_cast<const ClipRenderer*>( m_clipPreview->getGenericRenderer() );
const ClipRenderer* clipRenderer = qobject_cast<const ClipRenderer*>( m_clipPreview->getAbstractRenderer() );
Q_ASSERT( clipRenderer != nullptr );
connect( m_mediaLibrary, SIGNAL( clipSelected( Clip* ) ),
clipRenderer, SLOT( setClip( Clip* ) ) );
......@@ -610,7 +610,7 @@ MainWindow::renderVideo( const QString& outputFileName, quint32 width, quint32 h
WorkflowFileRendererDialog dialog( width, height );
dialog.setModal( true );
dialog.setOutputFileName( outputFileName );
if ( m_projectPreview->getGenericRenderer()->isRendering() == true )
if ( m_projectPreview->getAbstractRenderer()->isRendering() == true )
m_projectPreview->stop();
Core::instance()->workflowRenderer()->startRenderToFile( outputFileName, width, height,
fps, ar, vbitrate, abitrate );
......
......@@ -38,7 +38,7 @@ PreviewRuler::PreviewRuler( QWidget* parent ) :
}
void
PreviewRuler::setRenderer( GenericRenderer* renderer )
PreviewRuler::setRenderer( AbstractRenderer* renderer )
{
if ( m_renderer )
m_renderer->disconnect( this );
......
......@@ -25,7 +25,7 @@
#include <QWidget>
#include <QPaintEvent>
#include "Renderer/GenericRenderer.h"
#include "Renderer/AbstractRenderer.h"
#define MARK_XSMALL 3
#define MARK_SMALL 5
......@@ -46,7 +46,7 @@ public:
PreviewRuler( QWidget* parent = 0 );
virtual ~PreviewRuler() { }
void setRenderer( GenericRenderer* renderer );
void setRenderer( AbstractRenderer* renderer );
void setMarker( Marker m );
void hideMarker( Marker m );
qint64 getMarker( Marker m ) const;
......@@ -65,7 +65,7 @@ private slots:
void clear();
private:
GenericRenderer* m_renderer;
AbstractRenderer* m_renderer;
qint64 m_frame;
qint64 m_markerStart;
qint64 m_markerStop;
......
......@@ -66,7 +66,7 @@ PreviewWidget::~PreviewWidget()
}
void
PreviewWidget::setRenderer(GenericRenderer *renderer)
PreviewWidget::setRenderer(AbstractRenderer *renderer)
{
delete m_renderer;
m_renderer = renderer;
......@@ -179,8 +179,8 @@ PreviewWidget::on_pushButtonPreviousFrame_clicked()
m_renderer->previousFrame();
}
const GenericRenderer*
PreviewWidget::getGenericRenderer() const
const AbstractRenderer*
PreviewWidget::getAbstractRenderer() const
{
return m_renderer;
}
......
......@@ -27,7 +27,7 @@
#include <QWidget>
#include "Workflow/MainWorkflow.h"
class GenericRenderer;
class AbstractRenderer;
class RendererEventWatcher;
namespace Ui {
......@@ -42,8 +42,8 @@ class PreviewWidget : public QWidget
public:
explicit PreviewWidget( QWidget* parent = nullptr );
virtual ~PreviewWidget();
const GenericRenderer* getGenericRenderer() const;
void setRenderer( GenericRenderer *renderer );
const AbstractRenderer* getAbstractRenderer() const;
void setRenderer( AbstractRenderer *renderer );
/**
* @brief setClipEdition Allows to enable/disable markers & create clip buttons
*/
......@@ -51,7 +51,7 @@ public:
private:
Ui::PreviewWidget* m_ui;
GenericRenderer* m_renderer;
AbstractRenderer* m_renderer;
bool m_previewStopped;
protected:
......
/*****************************************************************************
* GenericRenderer.cpp: Describe a common behavior for every renderers
* AbstractRenderer.cpp: Describe a common behavior for every renderers
*****************************************************************************
* Copyright (C) 2008-2016 VideoLAN
*
......@@ -20,11 +20,11 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
*****************************************************************************/
#include "GenericRenderer.h"
#include "AbstractRenderer.h"
#include "preview/RenderWidget.h"
#include <QtGlobal>
GenericRenderer::GenericRenderer()
AbstractRenderer::AbstractRenderer()
: m_sourceRenderer( nullptr )
, m_paused( false )
, m_isRendering( false )
......@@ -32,33 +32,33 @@ GenericRenderer::GenericRenderer()
m_eventWatcher = new RendererEventWatcher;
}
GenericRenderer::~GenericRenderer()
AbstractRenderer::~AbstractRenderer()
{
delete m_sourceRenderer;
delete m_eventWatcher;
}
bool
GenericRenderer::isPaused() const
AbstractRenderer::isPaused() const
{
return m_paused;
}
bool
GenericRenderer::isRendering() const
AbstractRenderer::isRendering() const
{
return m_isRendering;
}
void
GenericRenderer::setRenderTarget( std::unique_ptr<Backend::IRenderTarget> target )
AbstractRenderer::setRenderTarget( std::unique_ptr<Backend::IRenderTarget> target )
{
m_renderTarget = std::move( target );
}
#ifdef WITH_GUI
RendererEventWatcher*
GenericRenderer::eventWatcher()
AbstractRenderer::eventWatcher()
{
return m_eventWatcher;
}
......
/*****************************************************************************
* GenericRenderer.h: Describe a common behavior for every renderers
* AbstractRenderer.h: Describe a common behavior for every renderers
*****************************************************************************
* Copyright (C) 2008-2016 VideoLAN
*
......@@ -20,8 +20,8 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
*****************************************************************************/
#ifndef GENERICRENDERER_H
#define GENERICRENDERER_H
#ifndef ABSTRACTRENDERER_H
#define ABSTRACTRENDERER_H
#include "config.h"
#include <memory>
......@@ -37,16 +37,16 @@ class Media;
/**
* \class Common base for every renderer.
*/
class GenericRenderer : public QObject
class AbstractRenderer : public QObject
{
Q_OBJECT
Q_DISABLE_COPY( GenericRenderer )
Q_DISABLE_COPY( AbstractRenderer )
protected:
explicit GenericRenderer();
explicit AbstractRenderer();
public:
virtual ~GenericRenderer();
virtual ~AbstractRenderer();
/**
* \brief Set the output volume.
......@@ -170,4 +170,4 @@ signals:
Vlmc::FrameChangedReason reason );
};
#endif // GENERICRENDERER_H
#endif // ABSTRACTRENDERER_H
......@@ -34,7 +34,7 @@
#include "Gui/preview/RenderWidget.h"
ClipRenderer::ClipRenderer() :
GenericRenderer(),
AbstractRenderer(),
m_clipLoaded( false ),
m_selectedClip( nullptr ),
m_begin( 0 ),
......
......@@ -23,14 +23,14 @@
#ifndef CLIPRENDERER_H
#define CLIPRENDERER_H
#include "GenericRenderer.h"
#include "AbstractRenderer.h"
#include <QObject>
class Clip;
class Media;
class ClipRenderer : public GenericRenderer
class ClipRenderer : public AbstractRenderer
{
Q_OBJECT
Q_DISABLE_COPY( ClipRenderer )
......
......@@ -32,7 +32,7 @@
#include "Project/Project.h"
#include "Media/Clip.h"
#include "EffectsEngine/EffectInstance.h"
#include "GenericRenderer.h"
#include "AbstractRenderer.h"
#include "Backend/IBackend.h"
#include "Backend/ISource.h"
#include "Backend/Target/FileTarget.h"
......
......@@ -23,7 +23,7 @@
#ifndef WORKFLOWRENDERER_H
#define WORKFLOWRENDERER_H
#include "GenericRenderer.h"
#include "AbstractRenderer.h"
#include "Backend/ISourceRenderer.h"
#include "Workflow/MainWorkflow.h"
......@@ -42,7 +42,7 @@ class QWidget;
class QWaitCondition;
class QMutex;
class WorkflowRenderer : public GenericRenderer
class WorkflowRenderer : public AbstractRenderer
{
Q_OBJECT
Q_DISABLE_COPY( WorkflowRenderer )
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment