1 // Generated by gmmproc 2.50.1 -- DO NOT MODIFY!
2 
3 
4 #include <glibmm.h>
5 
6 #include <gstreamermm/discovererinfo.h>
7 #include <gstreamermm/private/discovererinfo_p.h>
8 
9 
10 /* gstreamermm - a C++ wrapper for gstreamer
11  *
12  * Copyright 2011-2016 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 #include <gstreamermm/caps.h>
30 #include <gstreamermm/structure.h>
31 #include <gstreamermm/taglist.h>
32 #include <gstreamermm/toc.h>
33 #include <gobject/gobject.h>
34 #include <gst/pbutils/pbutils.h>
35 
36 
37 namespace Gst
38 {
39 
40 static GstDiscovererInfo *
gst_discoverer_info_new(void)41 gst_discoverer_info_new (void)
42 {
43   return (GstDiscovererInfo *) g_object_new (GST_TYPE_DISCOVERER_INFO, nullptr);
44 }
45 }
46 
47 namespace
48 {
49 } // anonymous namespace
50 
51 // static
value_type()52 GType Glib::Value<Gst::DiscovererResult>::value_type()
53 {
54   return gst_discoverer_result_get_type();
55 }
56 
57 // static
value_type()58 GType Glib::Value<Gst::DiscovererSerializeFlags>::value_type()
59 {
60   return gst_discoverer_serialize_flags_get_type();
61 }
62 
63 
64 /* Why reinterpret_cast<DiscovererInfo*>(gobject) is needed:
65  *
66  * A DiscovererInfo instance is in fact always a GstDiscovererInfo instance.
67  * Unfortunately, GstDiscovererInfo cannot be a member of DiscovererInfo,
68  * because it is an opaque struct.  Also, the C interface does not provide
69  * any hooks to install a destroy notification handler, thus we cannot
70  * wrap it dynamically either.
71  *
72  * The cast works because DiscovererInfo does not have any member data, and
73  * it is impossible to derive from it.  This is ensured by using final on the
74  * class and by using = delete on the default constructor.
75  */
76 
77 namespace Glib
78 {
79 
wrap(GstDiscovererInfo * object,bool take_copy)80 Glib::RefPtr<Gst::DiscovererInfo> wrap(GstDiscovererInfo* object, bool take_copy)
81 {
82   if(take_copy && object)
83     g_object_ref(object);
84 
85   // See the comment at the top of this file, if you want to know why the cast works.
86   return Glib::RefPtr<Gst::DiscovererInfo>(reinterpret_cast<Gst::DiscovererInfo*>(object));
87 }
88 
89 } // namespace Glib
90 
91 
92 namespace Gst
93 {
94 
95 
96 // static
create()97 Glib::RefPtr<DiscovererInfo> DiscovererInfo::create()
98 {
99   // See the comment at the top of this file, if you want to know why the cast works.
100   return Glib::RefPtr<DiscovererInfo>(reinterpret_cast<DiscovererInfo*>(gst_discoverer_info_new()));
101 }
102 
reference() const103 void DiscovererInfo::reference() const
104 {
105   // See the comment at the top of this file, if you want to know why the cast works.
106   g_object_ref(reinterpret_cast<GstDiscovererInfo*>(const_cast<DiscovererInfo*>(this)));
107 }
108 
unreference() const109 void DiscovererInfo::unreference() const
110 {
111   // See the comment at the top of this file, if you want to know why the cast works.
112   gst_discoverer_info_unref(reinterpret_cast<GstDiscovererInfo*>(const_cast<DiscovererInfo*>(this)));
113 }
114 
gobj()115 GstDiscovererInfo* DiscovererInfo::gobj()
116 {
117   // See the comment at the top of this file, if you want to know why the cast works.
118   return reinterpret_cast<GstDiscovererInfo*>(this);
119 }
120 
gobj() const121 const GstDiscovererInfo* DiscovererInfo::gobj() const
122 {
123   // See the comment at the top of this file, if you want to know why the cast works.
124   return reinterpret_cast<const GstDiscovererInfo*>(this);
125 }
126 
gobj_copy() const127 GstDiscovererInfo* DiscovererInfo::gobj_copy() const
128 {
129   // See the comment at the top of this file, if you want to know why the cast works.
130   const auto gobject = reinterpret_cast<GstDiscovererInfo*>(const_cast<DiscovererInfo*>(this));
131   g_object_ref(gobject);
132   return gobject;
133 }
134 
135 
copy() const136 Glib::RefPtr<Gst::DiscovererInfo> DiscovererInfo::copy() const
137 {
138   return Glib::wrap(gst_discoverer_info_copy(const_cast<GstDiscovererInfo*>(gobj())));
139 }
140 
get_duration() const141 ClockTime DiscovererInfo::get_duration() const
142 {
143   return ((ClockTime)(gst_discoverer_info_get_duration(const_cast<GstDiscovererInfo*>(gobj()))));
144 }
145 
get_misc() const146 Structure DiscovererInfo::get_misc() const
147 {
148   return Glib::wrap(const_cast<GstStructure*>(gst_discoverer_info_get_misc(const_cast<GstDiscovererInfo*>(gobj()))), true);
149 }
150 
get_result() const151 DiscovererResult DiscovererInfo::get_result() const
152 {
153   return ((DiscovererResult)(gst_discoverer_info_get_result(const_cast<GstDiscovererInfo*>(gobj()))));
154 }
155 
get_stream_info()156 Glib::RefPtr<Gst::DiscovererStreamInfo> DiscovererInfo::get_stream_info()
157 {
158   return Glib::wrap(gst_discoverer_info_get_stream_info(gobj()));
159 }
160 
get_stream_info() const161 Glib::RefPtr<const Gst::DiscovererStreamInfo> DiscovererInfo::get_stream_info() const
162 {
163   return const_cast<DiscovererInfo*>(this)->get_stream_info();
164 }
165 
get_stream_list()166 std::vector< Glib::RefPtr<Gst::DiscovererStreamInfo> > DiscovererInfo::get_stream_list()
167 {
168   return Glib::ListHandler< Glib::RefPtr<Gst::DiscovererStreamInfo> >::list_to_vector(const_cast<GList*>(gst_discoverer_info_get_stream_list(gobj())), Glib::OWNERSHIP_DEEP);
169 }
170 
get_stream_list() const171 std::vector< Glib::RefPtr<const Gst::DiscovererStreamInfo> > DiscovererInfo::get_stream_list() const
172 {
173   return Glib::ListHandler< Glib::RefPtr<const Gst::DiscovererStreamInfo> >::list_to_vector(const_cast<GList*>(gst_discoverer_info_get_stream_list(const_cast<GstDiscovererInfo*>(gobj()))), Glib::OWNERSHIP_DEEP);
174 }
175 
get_tags() const176 Gst::TagList DiscovererInfo::get_tags() const
177 {
178   return Glib::wrap_taglist(const_cast<GstTagList*>(gst_discoverer_info_get_tags(const_cast<GstDiscovererInfo*>(gobj()))), true);
179 }
180 
get_uri() const181 Glib::ustring DiscovererInfo::get_uri() const
182 {
183   return Glib::convert_const_gchar_ptr_to_ustring(gst_discoverer_info_get_uri(const_cast<GstDiscovererInfo*>(gobj())));
184 }
185 
get_seekable() const186 bool DiscovererInfo::get_seekable() const
187 {
188   return gst_discoverer_info_get_seekable(const_cast<GstDiscovererInfo*>(gobj()));
189 }
190 
get_audio_streams()191 std::vector< Glib::RefPtr<Gst::DiscovererStreamInfo> > DiscovererInfo::get_audio_streams()
192 {
193   return Glib::ListHandler< Glib::RefPtr<Gst::DiscovererStreamInfo> >::list_to_vector(const_cast<GList*>(gst_discoverer_info_get_audio_streams(gobj())), Glib::OWNERSHIP_DEEP);
194 }
195 
get_audio_streams() const196 std::vector< Glib::RefPtr<const Gst::DiscovererStreamInfo> > DiscovererInfo::get_audio_streams() const
197 {
198   return Glib::ListHandler< Glib::RefPtr<const Gst::DiscovererStreamInfo> >::list_to_vector(const_cast<GList*>(gst_discoverer_info_get_audio_streams(const_cast<GstDiscovererInfo*>(gobj()))), Glib::OWNERSHIP_DEEP);
199 }
200 
get_container_streams()201 std::vector< Glib::RefPtr<Gst::DiscovererStreamInfo> > DiscovererInfo::get_container_streams()
202 {
203   return Glib::ListHandler< Glib::RefPtr<Gst::DiscovererStreamInfo> >::list_to_vector(const_cast<GList*>(gst_discoverer_info_get_container_streams(gobj())), Glib::OWNERSHIP_DEEP);
204 }
205 
get_container_streams() const206 std::vector< Glib::RefPtr<const Gst::DiscovererStreamInfo> > DiscovererInfo::get_container_streams() const
207 {
208   return Glib::ListHandler< Glib::RefPtr<const Gst::DiscovererStreamInfo> >::list_to_vector(const_cast<GList*>(gst_discoverer_info_get_container_streams(const_cast<GstDiscovererInfo*>(gobj()))), Glib::OWNERSHIP_DEEP);
209 }
210 
get_streams(GType streamtype)211 std::vector< Glib::RefPtr<Gst::DiscovererStreamInfo> > DiscovererInfo::get_streams(GType streamtype)
212 {
213   return Glib::ListHandler< Glib::RefPtr<Gst::DiscovererStreamInfo> >::list_to_vector(const_cast<GList*>(gst_discoverer_info_get_streams(gobj(), streamtype)), Glib::OWNERSHIP_DEEP);
214 }
215 
get_streams(GType streamtype) const216 std::vector< Glib::RefPtr<const Gst::DiscovererStreamInfo> > DiscovererInfo::get_streams(GType streamtype) const
217 {
218   return Glib::ListHandler< Glib::RefPtr<const Gst::DiscovererStreamInfo> >::list_to_vector(const_cast<GList*>(gst_discoverer_info_get_streams(const_cast<GstDiscovererInfo*>(gobj()), streamtype)), Glib::OWNERSHIP_DEEP);
219 }
220 
get_video_streams()221 std::vector< Glib::RefPtr<Gst::DiscovererStreamInfo> > DiscovererInfo::get_video_streams()
222 {
223   return Glib::ListHandler< Glib::RefPtr<Gst::DiscovererStreamInfo> >::list_to_vector(const_cast<GList*>(gst_discoverer_info_get_video_streams(gobj())), Glib::OWNERSHIP_DEEP);
224 }
225 
get_video_streams() const226 std::vector< Glib::RefPtr<const Gst::DiscovererStreamInfo> > DiscovererInfo::get_video_streams() const
227 {
228   return Glib::ListHandler< Glib::RefPtr<const Gst::DiscovererStreamInfo> >::list_to_vector(const_cast<GList*>(gst_discoverer_info_get_video_streams(const_cast<GstDiscovererInfo*>(gobj()))), Glib::OWNERSHIP_DEEP);
229 }
230 
get_subtitle_streams()231 std::vector< Glib::RefPtr<Gst::DiscovererStreamInfo> > DiscovererInfo::get_subtitle_streams()
232 {
233   return Glib::ListHandler< Glib::RefPtr<Gst::DiscovererStreamInfo> >::list_to_vector(const_cast<GList*>(gst_discoverer_info_get_subtitle_streams(gobj())), Glib::OWNERSHIP_DEEP);
234 }
235 
get_subtitle_streams() const236 std::vector< Glib::RefPtr<const Gst::DiscovererStreamInfo> > DiscovererInfo::get_subtitle_streams() const
237 {
238   return Glib::ListHandler< Glib::RefPtr<const Gst::DiscovererStreamInfo> >::list_to_vector(const_cast<GList*>(gst_discoverer_info_get_subtitle_streams(const_cast<GstDiscovererInfo*>(gobj()))), Glib::OWNERSHIP_DEEP);
239 }
240 
get_missing_elements_installer_details() const241 std::vector<Glib::ustring> DiscovererInfo::get_missing_elements_installer_details() const
242 {
243   return Glib::ArrayHandler<Glib::ustring>::array_to_vector(gst_discoverer_info_get_missing_elements_installer_details(const_cast<GstDiscovererInfo*>(gobj())), Glib::OWNERSHIP_DEEP);
244 }
245 
get_toc() const246 Glib::RefPtr<const Gst::Toc> DiscovererInfo::get_toc() const
247 {
248   return Glib::wrap(const_cast<GstToc*>(gst_discoverer_info_get_toc(const_cast<GstDiscovererInfo*>(gobj()))));
249 }
250 
251 
252 } // namespace Gst
253 
254 
255 /* Why reinterpret_cast<DiscovererStreamInfo*>(gobject) is needed:
256  *
257  * A DiscovererStreamInfo instance is in fact always a GstDiscovererStreamInfo instance.
258  * Unfortunately, GstDiscovererStreamInfo cannot be a member of DiscovererStreamInfo,
259  * because it is an opaque struct.  Also, the C interface does not provide
260  * any hooks to install a destroy notification handler, thus we cannot
261  * wrap it dynamically either.
262  *
263  * The cast works because DiscovererStreamInfo does not have any member data, and
264  * it is impossible to derive from it.  This is ensured by using final on the
265  * class and by using = delete on the default constructor.
266  */
267 
268 namespace Glib
269 {
270 
wrap(GstDiscovererStreamInfo * object,bool take_copy)271 Glib::RefPtr<Gst::DiscovererStreamInfo> wrap(GstDiscovererStreamInfo* object, bool take_copy)
272 {
273   if(take_copy && object)
274     gst_discoverer_stream_info_ref(object);
275 
276   // See the comment at the top of this file, if you want to know why the cast works.
277   return Glib::RefPtr<Gst::DiscovererStreamInfo>(reinterpret_cast<Gst::DiscovererStreamInfo*>(object));
278 }
279 
280 } // namespace Glib
281 
282 
283 namespace Gst
284 {
285 
286 
reference() const287 void DiscovererStreamInfo::reference() const
288 {
289   // See the comment at the top of this file, if you want to know why the cast works.
290   gst_discoverer_stream_info_ref(reinterpret_cast<GstDiscovererStreamInfo*>(const_cast<DiscovererStreamInfo*>(this)));
291 }
292 
unreference() const293 void DiscovererStreamInfo::unreference() const
294 {
295   // See the comment at the top of this file, if you want to know why the cast works.
296   gst_discoverer_stream_info_unref(reinterpret_cast<GstDiscovererStreamInfo*>(const_cast<DiscovererStreamInfo*>(this)));
297 }
298 
gobj()299 GstDiscovererStreamInfo* DiscovererStreamInfo::gobj()
300 {
301   // See the comment at the top of this file, if you want to know why the cast works.
302   return reinterpret_cast<GstDiscovererStreamInfo*>(this);
303 }
304 
gobj() const305 const GstDiscovererStreamInfo* DiscovererStreamInfo::gobj() const
306 {
307   // See the comment at the top of this file, if you want to know why the cast works.
308   return reinterpret_cast<const GstDiscovererStreamInfo*>(this);
309 }
310 
gobj_copy() const311 GstDiscovererStreamInfo* DiscovererStreamInfo::gobj_copy() const
312 {
313   // See the comment at the top of this file, if you want to know why the cast works.
314   const auto gobject = reinterpret_cast<GstDiscovererStreamInfo*>(const_cast<DiscovererStreamInfo*>(this));
315   gst_discoverer_stream_info_ref(gobject);
316   return gobject;
317 }
318 
get_caps()319 Glib::RefPtr<Gst::Caps> DiscovererStreamInfo::get_caps()
320 {
321   return Glib::wrap(gst_discoverer_stream_info_get_caps(gobj()));
322 }
323 
get_caps() const324 Glib::RefPtr<const Gst::Caps> DiscovererStreamInfo::get_caps() const
325 {
326   return const_cast<DiscovererStreamInfo*>(this)->get_caps();
327 }
328 
get_misc() const329 Structure DiscovererStreamInfo::get_misc() const
330 {
331   return Glib::wrap(const_cast<GstStructure*>(gst_discoverer_stream_info_get_misc(const_cast<GstDiscovererStreamInfo*>(gobj()))), true);
332 }
333 
get_next()334 Glib::RefPtr<Gst::DiscovererStreamInfo> DiscovererStreamInfo::get_next()
335 {
336   return Glib::wrap(gst_discoverer_stream_info_get_next(gobj()));
337 }
338 
get_next() const339 Glib::RefPtr<const Gst::DiscovererStreamInfo> DiscovererStreamInfo::get_next() const
340 {
341   return const_cast<DiscovererStreamInfo*>(this)->get_next();
342 }
343 
get_previous()344 Glib::RefPtr<Gst::DiscovererStreamInfo> DiscovererStreamInfo::get_previous()
345 {
346   return Glib::wrap(gst_discoverer_stream_info_get_previous(gobj()));
347 }
348 
get_previous() const349 Glib::RefPtr<Gst::DiscovererStreamInfo> DiscovererStreamInfo::get_previous() const
350 {
351   return const_cast<DiscovererStreamInfo*>(this)->get_previous();
352 }
353 
get_tags() const354 Gst::TagList DiscovererStreamInfo::get_tags() const
355 {
356   return Glib::wrap_taglist(const_cast<GstTagList*>(gst_discoverer_stream_info_get_tags(const_cast<GstDiscovererStreamInfo*>(gobj()))), true);
357 }
358 
get_stream_type_nick() const359 Glib::ustring DiscovererStreamInfo::get_stream_type_nick() const
360 {
361   return Glib::convert_const_gchar_ptr_to_ustring(gst_discoverer_stream_info_get_stream_type_nick(const_cast<GstDiscovererStreamInfo*>(gobj())));
362 }
363 
get_stream_id() const364 Glib::ustring DiscovererStreamInfo::get_stream_id() const
365 {
366   return Glib::convert_const_gchar_ptr_to_ustring(gst_discoverer_stream_info_get_stream_id(const_cast<GstDiscovererStreamInfo*>(gobj())));
367 }
368 
get_toc() const369 Glib::RefPtr<const Gst::Toc> DiscovererStreamInfo::get_toc() const
370 {
371   return Glib::wrap(const_cast<GstToc*>(gst_discoverer_stream_info_get_toc(const_cast<GstDiscovererStreamInfo*>(gobj()))));
372 }
373 
374 
375 } // namespace Gst
376 
377 
378 /* Why reinterpret_cast<DiscovererContainerInfo*>(gobject) is needed:
379  *
380  * A DiscovererContainerInfo instance is in fact always a GstDiscovererContainerInfo instance.
381  * Unfortunately, GstDiscovererContainerInfo cannot be a member of DiscovererContainerInfo,
382  * because it is an opaque struct.  Also, the C interface does not provide
383  * any hooks to install a destroy notification handler, thus we cannot
384  * wrap it dynamically either.
385  *
386  * The cast works because DiscovererContainerInfo does not have any member data, and
387  * it is impossible to derive from it.  This is ensured by using final on the
388  * class and by using = delete on the default constructor.
389  */
390 
391 namespace Glib
392 {
393 
wrap(GstDiscovererContainerInfo * object,bool take_copy)394 Glib::RefPtr<Gst::DiscovererContainerInfo> wrap(GstDiscovererContainerInfo* object, bool take_copy)
395 {
396   if(take_copy && object)
397     gst_discoverer_stream_info_ref(object);
398 
399   // See the comment at the top of this file, if you want to know why the cast works.
400   return Glib::RefPtr<Gst::DiscovererContainerInfo>(reinterpret_cast<Gst::DiscovererContainerInfo*>(object));
401 }
402 
403 } // namespace Glib
404 
405 
406 namespace Gst
407 {
408 
409 
reference() const410 void DiscovererContainerInfo::reference() const
411 {
412   // See the comment at the top of this file, if you want to know why the cast works.
413   gst_discoverer_stream_info_ref(reinterpret_cast<GstDiscovererContainerInfo*>(const_cast<DiscovererContainerInfo*>(this)));
414 }
415 
unreference() const416 void DiscovererContainerInfo::unreference() const
417 {
418   // See the comment at the top of this file, if you want to know why the cast works.
419   gst_discoverer_stream_info_unref(reinterpret_cast<GstDiscovererContainerInfo*>(const_cast<DiscovererContainerInfo*>(this)));
420 }
421 
gobj()422 GstDiscovererContainerInfo* DiscovererContainerInfo::gobj()
423 {
424   // See the comment at the top of this file, if you want to know why the cast works.
425   return reinterpret_cast<GstDiscovererContainerInfo*>(this);
426 }
427 
gobj() const428 const GstDiscovererContainerInfo* DiscovererContainerInfo::gobj() const
429 {
430   // See the comment at the top of this file, if you want to know why the cast works.
431   return reinterpret_cast<const GstDiscovererContainerInfo*>(this);
432 }
433 
gobj_copy() const434 GstDiscovererContainerInfo* DiscovererContainerInfo::gobj_copy() const
435 {
436   // See the comment at the top of this file, if you want to know why the cast works.
437   const auto gobject = reinterpret_cast<GstDiscovererContainerInfo*>(const_cast<DiscovererContainerInfo*>(this));
438   gst_discoverer_stream_info_ref(gobject);
439   return gobject;
440 }
441 
get_streams()442 std::vector< Glib::RefPtr<Gst::DiscovererStreamInfo> > DiscovererContainerInfo::get_streams()
443 {
444   return Glib::ListHandler< Glib::RefPtr<Gst::DiscovererStreamInfo> >::list_to_vector(const_cast<GList*>(gst_discoverer_container_info_get_streams(gobj())), Glib::OWNERSHIP_DEEP);
445 }
446 
get_streams() const447 std::vector< Glib::RefPtr<const Gst::DiscovererStreamInfo> > DiscovererContainerInfo::get_streams() const
448 {
449   return Glib::ListHandler< Glib::RefPtr<const Gst::DiscovererStreamInfo> >::list_to_vector(const_cast<GList*>(gst_discoverer_container_info_get_streams(const_cast<GstDiscovererContainerInfo*>(gobj()))), Glib::OWNERSHIP_DEEP);
450 }
451 
452 
453 } // namespace Gst
454 
455 
456 /* Why reinterpret_cast<DiscovererAudioInfo*>(gobject) is needed:
457  *
458  * A DiscovererAudioInfo instance is in fact always a GstDiscovererAudioInfo instance.
459  * Unfortunately, GstDiscovererAudioInfo cannot be a member of DiscovererAudioInfo,
460  * because it is an opaque struct.  Also, the C interface does not provide
461  * any hooks to install a destroy notification handler, thus we cannot
462  * wrap it dynamically either.
463  *
464  * The cast works because DiscovererAudioInfo does not have any member data, and
465  * it is impossible to derive from it.  This is ensured by using final on the
466  * class and by using = delete on the default constructor.
467  */
468 
469 namespace Glib
470 {
471 
wrap(GstDiscovererAudioInfo * object,bool take_copy)472 Glib::RefPtr<Gst::DiscovererAudioInfo> wrap(GstDiscovererAudioInfo* object, bool take_copy)
473 {
474   if(take_copy && object)
475     gst_discoverer_stream_info_ref(object);
476 
477   // See the comment at the top of this file, if you want to know why the cast works.
478   return Glib::RefPtr<Gst::DiscovererAudioInfo>(reinterpret_cast<Gst::DiscovererAudioInfo*>(object));
479 }
480 
481 } // namespace Glib
482 
483 
484 namespace Gst
485 {
486 
487 
reference() const488 void DiscovererAudioInfo::reference() const
489 {
490   // See the comment at the top of this file, if you want to know why the cast works.
491   gst_discoverer_stream_info_ref(reinterpret_cast<GstDiscovererAudioInfo*>(const_cast<DiscovererAudioInfo*>(this)));
492 }
493 
unreference() const494 void DiscovererAudioInfo::unreference() const
495 {
496   // See the comment at the top of this file, if you want to know why the cast works.
497   gst_discoverer_stream_info_unref(reinterpret_cast<GstDiscovererAudioInfo*>(const_cast<DiscovererAudioInfo*>(this)));
498 }
499 
gobj()500 GstDiscovererAudioInfo* DiscovererAudioInfo::gobj()
501 {
502   // See the comment at the top of this file, if you want to know why the cast works.
503   return reinterpret_cast<GstDiscovererAudioInfo*>(this);
504 }
505 
gobj() const506 const GstDiscovererAudioInfo* DiscovererAudioInfo::gobj() const
507 {
508   // See the comment at the top of this file, if you want to know why the cast works.
509   return reinterpret_cast<const GstDiscovererAudioInfo*>(this);
510 }
511 
gobj_copy() const512 GstDiscovererAudioInfo* DiscovererAudioInfo::gobj_copy() const
513 {
514   // See the comment at the top of this file, if you want to know why the cast works.
515   const auto gobject = reinterpret_cast<GstDiscovererAudioInfo*>(const_cast<DiscovererAudioInfo*>(this));
516   gst_discoverer_stream_info_ref(gobject);
517   return gobject;
518 }
519 
get_bitrate() const520 guint DiscovererAudioInfo::get_bitrate() const
521 {
522   return gst_discoverer_audio_info_get_bitrate(const_cast<GstDiscovererAudioInfo*>(gobj()));
523 }
524 
get_channels() const525 guint DiscovererAudioInfo::get_channels() const
526 {
527   return gst_discoverer_audio_info_get_channels(const_cast<GstDiscovererAudioInfo*>(gobj()));
528 }
529 
get_depth() const530 guint DiscovererAudioInfo::get_depth() const
531 {
532   return gst_discoverer_audio_info_get_depth(const_cast<GstDiscovererAudioInfo*>(gobj()));
533 }
534 
get_max_bitrate() const535 guint DiscovererAudioInfo::get_max_bitrate() const
536 {
537   return gst_discoverer_audio_info_get_max_bitrate(const_cast<GstDiscovererAudioInfo*>(gobj()));
538 }
539 
get_sample_rate() const540 guint DiscovererAudioInfo::get_sample_rate() const
541 {
542   return gst_discoverer_audio_info_get_sample_rate(const_cast<GstDiscovererAudioInfo*>(gobj()));
543 }
544 
get_language() const545 Glib::ustring DiscovererAudioInfo::get_language() const
546 {
547   return Glib::convert_const_gchar_ptr_to_ustring(gst_discoverer_audio_info_get_language(const_cast<GstDiscovererAudioInfo*>(gobj())));
548 }
549 
550 
551 } // namespace Gst
552 
553 
554 /* Why reinterpret_cast<DiscovererVideoInfo*>(gobject) is needed:
555  *
556  * A DiscovererVideoInfo instance is in fact always a GstDiscovererVideoInfo instance.
557  * Unfortunately, GstDiscovererVideoInfo cannot be a member of DiscovererVideoInfo,
558  * because it is an opaque struct.  Also, the C interface does not provide
559  * any hooks to install a destroy notification handler, thus we cannot
560  * wrap it dynamically either.
561  *
562  * The cast works because DiscovererVideoInfo does not have any member data, and
563  * it is impossible to derive from it.  This is ensured by using final on the
564  * class and by using = delete on the default constructor.
565  */
566 
567 namespace Glib
568 {
569 
wrap(GstDiscovererVideoInfo * object,bool take_copy)570 Glib::RefPtr<Gst::DiscovererVideoInfo> wrap(GstDiscovererVideoInfo* object, bool take_copy)
571 {
572   if(take_copy && object)
573     gst_discoverer_stream_info_ref(object);
574 
575   // See the comment at the top of this file, if you want to know why the cast works.
576   return Glib::RefPtr<Gst::DiscovererVideoInfo>(reinterpret_cast<Gst::DiscovererVideoInfo*>(object));
577 }
578 
579 } // namespace Glib
580 
581 
582 namespace Gst
583 {
584 
585 
reference() const586 void DiscovererVideoInfo::reference() const
587 {
588   // See the comment at the top of this file, if you want to know why the cast works.
589   gst_discoverer_stream_info_ref(reinterpret_cast<GstDiscovererVideoInfo*>(const_cast<DiscovererVideoInfo*>(this)));
590 }
591 
unreference() const592 void DiscovererVideoInfo::unreference() const
593 {
594   // See the comment at the top of this file, if you want to know why the cast works.
595   gst_discoverer_stream_info_unref(reinterpret_cast<GstDiscovererVideoInfo*>(const_cast<DiscovererVideoInfo*>(this)));
596 }
597 
gobj()598 GstDiscovererVideoInfo* DiscovererVideoInfo::gobj()
599 {
600   // See the comment at the top of this file, if you want to know why the cast works.
601   return reinterpret_cast<GstDiscovererVideoInfo*>(this);
602 }
603 
gobj() const604 const GstDiscovererVideoInfo* DiscovererVideoInfo::gobj() const
605 {
606   // See the comment at the top of this file, if you want to know why the cast works.
607   return reinterpret_cast<const GstDiscovererVideoInfo*>(this);
608 }
609 
gobj_copy() const610 GstDiscovererVideoInfo* DiscovererVideoInfo::gobj_copy() const
611 {
612   // See the comment at the top of this file, if you want to know why the cast works.
613   const auto gobject = reinterpret_cast<GstDiscovererVideoInfo*>(const_cast<DiscovererVideoInfo*>(this));
614   gst_discoverer_stream_info_ref(gobject);
615   return gobject;
616 }
617 
get_bitrate() const618 guint DiscovererVideoInfo::get_bitrate() const
619 {
620   return gst_discoverer_video_info_get_bitrate(const_cast<GstDiscovererVideoInfo*>(gobj()));
621 }
622 
get_depth() const623 guint DiscovererVideoInfo::get_depth() const
624 {
625   return gst_discoverer_video_info_get_depth(const_cast<GstDiscovererVideoInfo*>(gobj()));
626 }
627 
get_framerate_denom() const628 guint DiscovererVideoInfo::get_framerate_denom() const
629 {
630   return gst_discoverer_video_info_get_framerate_denom(const_cast<GstDiscovererVideoInfo*>(gobj()));
631 }
632 
get_framerate_num() const633 guint DiscovererVideoInfo::get_framerate_num() const
634 {
635   return gst_discoverer_video_info_get_framerate_num(const_cast<GstDiscovererVideoInfo*>(gobj()));
636 }
637 
get_height() const638 guint DiscovererVideoInfo::get_height() const
639 {
640   return gst_discoverer_video_info_get_height(const_cast<GstDiscovererVideoInfo*>(gobj()));
641 }
642 
is_interlaced() const643 bool DiscovererVideoInfo::is_interlaced() const
644 {
645   return gst_discoverer_video_info_is_interlaced(const_cast<GstDiscovererVideoInfo*>(gobj()));
646 }
647 
is_image() const648 bool DiscovererVideoInfo::is_image() const
649 {
650   return gst_discoverer_video_info_is_image(const_cast<GstDiscovererVideoInfo*>(gobj()));
651 }
652 
get_max_bitrate() const653 guint DiscovererVideoInfo::get_max_bitrate() const
654 {
655   return gst_discoverer_video_info_get_max_bitrate(const_cast<GstDiscovererVideoInfo*>(gobj()));
656 }
657 
get_par_denom() const658 guint DiscovererVideoInfo::get_par_denom() const
659 {
660   return gst_discoverer_video_info_get_par_denom(const_cast<GstDiscovererVideoInfo*>(gobj()));
661 }
662 
get_par_num() const663 guint DiscovererVideoInfo::get_par_num() const
664 {
665   return gst_discoverer_video_info_get_par_num(const_cast<GstDiscovererVideoInfo*>(gobj()));
666 }
667 
get_width() const668 guint DiscovererVideoInfo::get_width() const
669 {
670   return gst_discoverer_video_info_get_width(const_cast<GstDiscovererVideoInfo*>(gobj()));
671 }
672 
673 
674 } // namespace Gst
675 
676 
677