1 /**
2 * MltFactory.cpp - MLT Wrapper
3 * Copyright (C) 2004-2017 Meltytech, LLC
4 * Author: Charles Yates <charles.yates@gmail.com>
5 *
6 * This library is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU Lesser General Public
8 * License as published by the Free Software Foundation; either
9 * version 2.1 of the License, or (at your option) any later version.
10 *
11 * This library is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 * Lesser General Public License for more details.
15 *
16 * You should have received a copy of the GNU Lesser General Public
17 * License along with this library; if not, write to the Free Software
18 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
19 */
20
21 #include "MltFactory.h"
22 #include "MltProducer.h"
23 #include "MltFilter.h"
24 #include "MltTransition.h"
25 #include "MltConsumer.h"
26 #include "MltRepository.h"
27 using namespace Mlt;
28
init(const char * directory)29 Repository *Factory::init( const char *directory )
30 {
31 return new Repository( mlt_factory_init( directory ) );
32 }
33
event_object()34 Properties *Factory::event_object( )
35 {
36 return new Properties( mlt_factory_event_object( ) );
37 }
38
producer(Profile & profile,char * id,char * arg)39 Producer *Factory::producer( Profile& profile, char *id, char *arg )
40 {
41 return new Producer( profile, id, arg );
42 }
43
filter(Profile & profile,char * id,char * arg)44 Filter *Factory::filter( Profile& profile, char *id, char *arg )
45 {
46 return new Filter( profile, id, arg );
47 }
48
transition(Profile & profile,char * id,char * arg)49 Transition *Factory::transition( Profile& profile, char *id, char *arg )
50 {
51 return new Transition( profile, id, arg );
52 }
53
consumer(Profile & profile,char * id,char * arg)54 Consumer *Factory::consumer( Profile& profile, char *id, char *arg )
55 {
56 return new Consumer( profile, id, arg );
57 }
58
close()59 void Factory::close( )
60 {
61 mlt_factory_close( );
62 }
63
64
65