[vlmc-devel] ITractor

Yikai Lu git at videolan.org
Sun Jun 26 06:01:17 CEST 2016


vlmc | branch: master | Yikai Lu <luyikei.qmltu at gmail.com> | Tue Jun 14 16:13:52 2016 +0900| [291b90318396e727d66c2cac0146cb5c0743926d] | committer: Yikai Lu

ITractor

> https://code.videolan.org/videolan/vlmc/commit/291b90318396e727d66c2cac0146cb5c0743926d
---

 src/Backend/ITractor.h | 50 ++++++++++++++++++++++++++++++++++++++++++++++++++
 src/CMakeLists.txt     |  1 +
 2 files changed, 51 insertions(+)

diff --git a/src/Backend/ITractor.h b/src/Backend/ITractor.h
new file mode 100644
index 0000000..7de16b7
--- /dev/null
+++ b/src/Backend/ITractor.h
@@ -0,0 +1,50 @@
+/*****************************************************************************
+ * ITractor.h: Defines an interface of a multitrack producer
+ *****************************************************************************
+ * Copyright (C) 2008-2016 VideoLAN
+ *
+ * Authors: Yikei Lu <luyikei.qmltu at gmail.com>
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
+ *****************************************************************************/
+
+#ifndef ITRACTOR_H
+#define ITRACTOR_H
+
+#include "IProducer.h"
+
+namespace Backend
+{
+    class IProducer;
+    class ITransition;
+    class IFilter;
+    class ITractor : virtual public IProducer
+    {
+    public:
+        virtual     ~ITractor() = default;
+
+        virtual void        refresh() = 0;
+        virtual bool        setTrack( IProducer& producer, int index ) = 0;
+        virtual bool        insertTrack( IProducer& producer, int index ) = 0;
+        virtual bool        removeTrack( int index ) = 0;
+        virtual IProducer*  track( int index ) const = 0;
+        virtual int         count() const = 0;
+        virtual void        addTransition( ITransition& transition, int aTrack = 0, int bTrack = 1 ) = 0;
+        virtual void        addFilter( IFilter& filter, int track = 0 ) = 0;
+        virtual bool        connect( IProducer& producer ) = 0;
+    };
+}
+
+#endif // ITRACTOR_H
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
index d2771a1..18700a1 100644
--- a/src/CMakeLists.txt
+++ b/src/CMakeLists.txt
@@ -63,6 +63,7 @@ SET(VLMC_SRCS
     Backend/IProducer.h
     Backend/ITrack.h
     Backend/IProfile.h
+    Backend/ITractor.h
     Backend/VLC/VLCBackend.cpp
     Backend/VLC/VLCSourceRenderer.cpp
     Backend/VLC/VLCVmemRenderer.cpp



More information about the Vlmc-devel mailing list