0df73dc8f1ca6e8b63c8d52ebd85bbb8b4bcb9ac
2 * MltProfile.cpp - MLT Wrapper
3 * Copyright (C) 2008 Dan Dennedy <dan@dennedy.org>
5 * This program is free software; you can redistribute it and/or modify
6 * it under the terms of the GNU Lesser General Public License as published
7 * by the Free Software Foundation; either version 2 of the License, or
8 * (at your option) any later version.
10 * This program is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
15 * You should have received a copy of the GNU General Public License
16 * along with this program; if not, write to the Free Software Foundation,
17 * Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
20 #include "MltProfile.h"
21 #include "MltProperties.h"
27 instance
= mlt_profile_init( NULL
);
30 Profile
::Profile( const char* name
) :
33 instance
= mlt_profile_init( name
);
36 Profile
::Profile( Properties
& properties
) :
39 instance
= mlt_profile_load_properties( properties
.get_properties() );
42 Profile
::Profile( mlt_profile profile
) :
50 mlt_profile_close( instance
);
54 mlt_profile Profile
::get_profile( ) const
59 char* Profile
::description() const
61 return instance
->description
;
64 int Profile
::frame_rate_num() const
66 return instance
->frame_rate_num
;
69 int Profile
::frame_rate_den() const
71 return instance
->frame_rate_den
;
74 double Profile
::fps() const
76 return mlt_profile_fps( instance
);
79 int Profile
::width() const
81 return instance
->width
;
84 int Profile
::height() const
86 return instance
->height
;
89 bool Profile
::progressive() const
91 return instance
->progressive
;
94 int Profile
::sample_aspect_num() const
96 return instance
->sample_aspect_num
;
99 int Profile
::sample_aspect_den() const
101 return instance
->sample_aspect_den
;
104 double Profile
::sar() const
106 return mlt_profile_sar( instance
);
109 int Profile
::display_aspect_num() const
111 return instance
->display_aspect_num
;
114 int Profile
::display_aspect_den() const
116 return instance
->display_aspect_den
;
119 double Profile
::dar() const
121 return mlt_profile_dar( instance
);