[vlmc-devel] GenericRenderer Implement setRenderTarget
Yikai Lu
git at videolan.org
Fri Apr 22 16:05:44 CEST 2016
vlmc | branch: master | Yikai Lu <luyikei.qmltu at gmail.com> | Mon Apr 18 17:32:24 2016 +0900| [aec6a344dc375e282a22a34f749758eaff317189] | committer: Hugo Beauzée-Luyssen
GenericRenderer Implement setRenderTarget
Signed-off-by: Hugo Beauzée-Luyssen <hugo at beauzee.fr>
> https://code.videolan.org/videolan/vlmc/commit/aec6a344dc375e282a22a34f749758eaff317189
---
src/Renderer/GenericRenderer.cpp | 6 ++++++
src/Renderer/GenericRenderer.h | 7 ++++++-
2 files changed, 12 insertions(+), 1 deletion(-)
diff --git a/src/Renderer/GenericRenderer.cpp b/src/Renderer/GenericRenderer.cpp
index c1d9341..fdfcea9 100644
--- a/src/Renderer/GenericRenderer.cpp
+++ b/src/Renderer/GenericRenderer.cpp
@@ -50,6 +50,12 @@ GenericRenderer::isRendering() const
return m_isRendering;
}
+void
+GenericRenderer::setRenderTarget( std::unique_ptr<Backend::IRenderTarget> target )
+{
+ m_renderTarget = std::move( target );
+}
+
#ifdef WITH_GUI
RendererEventWatcher*
GenericRenderer::eventWatcher()
diff --git a/src/Renderer/GenericRenderer.h b/src/Renderer/GenericRenderer.h
index 6fb326a..b63ec22 100644
--- a/src/Renderer/GenericRenderer.h
+++ b/src/Renderer/GenericRenderer.h
@@ -24,11 +24,12 @@
#define GENERICRENDERER_H
#include "config.h"
-
+#include <memory>
#include <QObject>
#include "Workflow/Types.h"
#include "Tools/RendererEventWatcher.h"
+#include "Backend/IRenderTarget.h"
class Clip;
class Media;
@@ -135,6 +136,8 @@ public:
*/
bool isRendering() const;
+ void setRenderTarget( std::unique_ptr<Backend::IRenderTarget> target );
+
RendererEventWatcher* eventWatcher();
protected:
Backend::ISourceRenderer* m_sourceRenderer;
@@ -150,6 +153,8 @@ protected:
bool m_paused;
bool m_isRendering;
+ std::unique_ptr<Backend::IRenderTarget> m_renderTarget;
+
public slots:
/**
* \brief This SLOT will be called when the time cursor has changed.
More information about the Vlmc-devel
mailing list