Debian Codegraph @

gstreamer/gstreamermm/videoinfo.cc

raw symbols SCIP
1 // Generated by gmmproc 2.50.1 -- DO NOT MODIFY!
2
3
4 #include <glibmm.h>
5
6 #include <gstreamermm/videoinfo.h>
7 #include <gstreamermm/private/videoinfo_p.h>
8
9
10 /* gstreamermm - a C++ wrapper for gstreamer
11 *
12 * Copyright 2008-2015 The gstreamermm Development Team
13 *
14 * This library is free software; you can redistribute it and/or
15 * modify it under the terms of the GNU Lesser General Public
16 * License as published by the Free Software Foundation; either
17 * version 2.1 of the License, or (at your option) any later version.
18 *
19 * This library is distributed in the hope that it will be useful,
20 * but WITHOUT ANY WARRANTY; without even the implied warranty of
21 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
22 * Lesser General Public License for more details.
23 *
24 * You should have received a copy of the GNU Lesser General Public
25 * License along with this library; if not, write to the Free
26 * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
27 */
28
29 namespace Gst
30 {
31 VideoInfo::VideoInfo()
32 : take_ownership(true)
33 {
34 gobject_ = gst_video_info_new();
35 }
36
37 VideoInfo::VideoInfo(const VideoInfo& other)
38 {
39 gobject_ = gst_video_info_copy(other.gobject_);
40 take_ownership = true;
41 }
42
43 VideoInfo& VideoInfo::operator=(const VideoInfo& other)
44 {
45 if (take_ownership)
46 gst_video_info_free(gobject_);
47
48 take_ownership = true;
49 gobject_ = gst_video_info_copy(other.gobject_);
50
51 return *this;
52 }
53
54 VideoInfo::VideoInfo(GstVideoInfo* castitem, bool take_ownership)
55 : gobject_(castitem),
56 take_ownership(take_ownership)
57 {
58 }
59
60 VideoInfo::~VideoInfo()
61 {
62 if (take_ownership)
63 gst_video_info_free(gobject_);
64 }
65 }
66
67 namespace
68 {
69 } // anonymous namespace
70
71 // static
72 GType Glib::Value<Gst::VideoInterlaceMode>::value_type()
73 {
74 return gst_video_interlace_mode_get_type();
75 }
76
77 // static
78 GType Glib::Value<Gst::VideoMultiviewMode>::value_type()
79 {
80 return gst_video_multiview_mode_get_type();
81 }
82
83 // static
84 GType Glib::Value<Gst::VideoMultiviewFramePacking>::value_type()
85 {
86 return gst_video_multiview_frame_packing_get_type();
87 }
88
89 // static
90 GType Glib::Value<Gst::VideoMultiviewFlags>::value_type()
91 {
92 return gst_video_multiview_flags_get_type();
93 }
94
95 // static
96 GType Glib::Value<Gst::VideoFlags>::value_type()
97 {
98 return gst_video_flags_get_type();
99 }
100
101
102 namespace Gst
103 {
104
105
106 void VideoInfo::init()
107 {
108 gst_video_info_init(gobj());
109 }
110
111 void VideoInfo::set_format(Gst::VideoFormat format, guint width, guint height)
112 {
113 gst_video_info_set_format(gobj(), ((GstVideoFormat)(format)), width, height);
114 }
115
116 bool VideoInfo::from_caps(const Glib::RefPtr<const Gst::Caps>& caps)
117 {
118 return gst_video_info_from_caps(gobj(), Glib::unwrap(caps));
119 }
120
121 Glib::RefPtr<Gst::Caps> VideoInfo::to_caps() const
122 {
123 return Glib::wrap(gst_video_info_to_caps(const_cast<GstVideoInfo*>(gobj())));
124 }
125
126 bool VideoInfo::convert(Gst::Format src_format, gint64 src_value, Gst::Format dest_format, gint64& dest_value)
127 {
128 return gst_video_info_convert(gobj(), ((GstFormat)(src_format)), src_value, ((GstFormat)(dest_format)), &(dest_value));
129 }
130
131 bool VideoInfo::is_equal(const Gst::VideoInfo& other) const
132 {
133 return gst_video_info_is_equal(const_cast<GstVideoInfo*>(gobj()), other.gobj());
134 }
135
136 const VideoFormatInfo VideoInfo::get_finfo() const
137 {
138 return VideoFormatInfo(gobj()->finfo);
139 }
140
141 Gst::VideoInterlaceMode VideoInfo::get_interlace_mode() const
142 {
143 return ((Gst::VideoInterlaceMode)(gobj()->interlace_mode));
144 }
145
146 void VideoInfo::set_interlace_mode(const Gst::VideoInterlaceMode& value)
147 {
148 gobj()->interlace_mode = ((GstVideoInterlaceMode)(value));
149 }
150
151 Gst::VideoFlags VideoInfo::get_flags() const
152 {
153 return ((Gst::VideoFlags)(gobj()->flags));
154 }
155
156 void VideoInfo::set_flags(const Gst::VideoFlags& value)
157 {
158 gobj()->flags = ((GstVideoFlags)(value));
159 }
160
161 gint VideoInfo::get_width() const
162 {
163 return gobj()->width;
164 }
165
166 void VideoInfo::set_width(const gint& value)
167 {
168 gobj()->width = value;
169 }
170
171 gint VideoInfo::get_height() const
172 {
173 return gobj()->height;
174 }
175
176 void VideoInfo::set_height(const gint& value)
177 {
178 gobj()->height = value;
179 }
180
181 gsize VideoInfo::get_size() const
182 {
183 return gobj()->size;
184 }
185
186 void VideoInfo::set_size(const gsize& value)
187 {
188 gobj()->size = value;
189 }
190
191 gint VideoInfo::get_views() const
192 {
193 return gobj()->views;
194 }
195
196 void VideoInfo::set_views(const gint& value)
197 {
198 gobj()->views = value;
199 }
200
201 Gst::VideoChromaSite VideoInfo::get_chroma_site() const
202 {
203 return ((Gst::VideoChromaSite)(gobj()->chroma_site));
204 }
205
206 void VideoInfo::set_chroma_site(const Gst::VideoChromaSite& value)
207 {
208 gobj()->chroma_site = ((GstVideoChromaSite)(value));
209 }
210
211 gint VideoInfo::get_par_n() const
212 {
213 return gobj()->par_n;
214 }
215
216 void VideoInfo::set_par_n(const gint& value)
217 {
218 gobj()->par_n = value;
219 }
220
221 gint VideoInfo::get_par_d() const
222 {
223 return gobj()->par_d;
224 }
225
226 void VideoInfo::set_par_d(const gint& value)
227 {
228 gobj()->par_d = value;
229 }
230
231 gint VideoInfo::get_fps_n() const
232 {
233 return gobj()->fps_n;
234 }
235
236 void VideoInfo::set_fps_n(const gint& value)
237 {
238 gobj()->fps_n = value;
239 }
240
241 gint VideoInfo::get_fps_d() const
242 {
243 return gobj()->fps_d;
244 }
245
246 void VideoInfo::set_fps_d(const gint& value)
247 {
248 gobj()->fps_d = value;
249 }
250
251 Gst::VideoMultiviewMode VideoInfo::get_multiview_mode() const
252 {
253 return ((Gst::VideoMultiviewMode)(gobj()->ABI.abi.multiview_mode));
254 }
255
256 void VideoInfo::set_multiview_mode(const Gst::VideoMultiviewMode& value)
257 {
258 gobj()->ABI.abi.multiview_mode = ((GstVideoMultiviewMode)(value));
259 }
260
261 Gst::VideoMultiviewFlags VideoInfo::get_multiview_flags() const
262 {
263 return ((Gst::VideoMultiviewFlags)(gobj()->ABI.abi.multiview_flags));
264 }
265
266 void VideoInfo::set_multiview_flags(const Gst::VideoMultiviewFlags& value)
267 {
268 gobj()->ABI.abi.multiview_flags = ((GstVideoMultiviewFlags)(value));
269 }
270
271
272 } // namespace Gst
273
274