| 1 | // Generated by gmmproc 2.50.1 -- DO NOT MODIFY!cxx . . $ `<file>/gstreamer/gstreamermm/audioinfo.h`/ |
| 2 | #ifndef _GSTREAMERMM_AUDIOINFO_H |
| 3 | #define _GSTREAMERMM_AUDIOINFO_Hcxx . . $ `gstreamer/gstreamermm/audioinfo.h:3:9`! |
| 4 | |
| 5 | |
| 6 | #include <glibmm/ustring.h> |
| 7 | #include <sigc++/sigc++.h> |
| 8 | |
| 9 | /* gstreamermm - a C++ wrapper for gstreamer |
| 10 | * |
| 11 | * Copyright 2008-2016 The gstreamermm Development Team |
| 12 | * |
| 13 | * This library is free software; you can redistribute it and/or |
| 14 | * modify it under the terms of the GNU Lesser General Public |
| 15 | * License as published by the Free Software Foundation; either |
| 16 | * version 2.1 of the License, or (at your option) any later version. |
| 17 | * |
| 18 | * This library is distributed in the hope that it will be useful, |
| 19 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 20 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
| 21 | * Lesser General Public License for more details. |
| 22 | * |
| 23 | * You should have received a copy of the GNU Lesser General Public |
| 24 | * License along with this library; if not, write to the Free |
| 25 | * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. |
| 26 | */ |
| 27 | |
| 28 | #include <gst/audio/audio-info.h> |
| 29 | #include <gstreamermm/audioformat.h>cxx . . $ `<file>/gstreamer/gstreamermm/audioformat.h`/ |
| 30 | #include <gstreamermm/audioringbuffer.h>cxx . . $ `<file>/gstreamer/gstreamermm/audioringbuffer.h`/ |
| 31 | |
| 32 | |
| 33 | #ifndef DOXYGEN_SHOULD_SKIP_THIS |
| 34 | extern "C" { typedef struct _GstAudioInfocxx . . $ _GstAudioInfo# GstAudioInfo; } |
| 35 | #endif |
| 36 | |
| 37 | namespace Gstcxx . . $ Gst/ |
| 38 | { |
| 39 | |
| 40 | /** @addtogroup gstreamermmEnums gstreamermm Enums and Flags */ |
| 41 | |
| 42 | /** |
| 43 | * @var AudioFlags AUDIO_FLAG_NONE |
| 44 | * No valid flag. |
| 45 | * |
| 46 | * @var AudioFlags AUDIO_FLAG_UNPOSITIONED |
| 47 | * The position array explicitly |
| 48 | * contains unpositioned channels. |
| 49 | * |
| 50 | * @enum AudioFlags |
| 51 | * |
| 52 | * Extra audio flags |
| 53 | * |
| 54 | * @ingroup gstreamermmEnums |
| 55 | * @par Bitwise operators: |
| 56 | * <tt>%AudioFlags operator|(AudioFlags, AudioFlags)</tt><br> |
| 57 | * <tt>%AudioFlags operator&(AudioFlags, AudioFlags)</tt><br> |
| 58 | * <tt>%AudioFlags operator^(AudioFlags, AudioFlags)</tt><br> |
| 59 | * <tt>%AudioFlags operator~(AudioFlags)</tt><br> |
| 60 | * <tt>%AudioFlags& operator|=(AudioFlags&, AudioFlags)</tt><br> |
| 61 | * <tt>%AudioFlags& operator&=(AudioFlags&, AudioFlags)</tt><br> |
| 62 | * <tt>%AudioFlags& operator^=(AudioFlags&, AudioFlags)</tt><br> |
| 63 | */ |
| 64 | enum AudioFlagscxx . . $ Gst/AudioFlags# |
| 65 | { |
| 66 | AUDIO_FLAG_NONEcxx . . $ Gst/AUDIO_FLAG_NONE. = 0x0, |
| 67 | AUDIO_FLAG_UNPOSITIONEDcxx . . $ Gst/AUDIO_FLAG_UNPOSITIONED. = (1 << 0) |
| 68 | }; |
| 69 | |
| 70 | /** @ingroup gstreamermmEnums */ |
| 71 | inline AudioFlagscxx . . $ Gst/AudioFlags# operatorcxx . . $ Gst/`operator|`(b22c0b981fdc5411).|(AudioFlagscxx . . $ Gst/AudioFlags# lhs, AudioFlagscxx . . $ Gst/AudioFlags# rhs) |
| 72 | { return static_cast<AudioFlagscxx . . $ Gst/AudioFlags#>(static_cast<unsigned>(lhs) | static_cast<unsigned>(rhs)); } |
| 73 | |
| 74 | /** @ingroup gstreamermmEnums */ |
| 75 | inline AudioFlagscxx . . $ Gst/AudioFlags# operatorcxx . . $ Gst/`operator&`(b22c0b981fdc5411).&(AudioFlagscxx . . $ Gst/AudioFlags# lhs, AudioFlagscxx . . $ Gst/AudioFlags# rhs) |
| 76 | { return static_cast<AudioFlagscxx . . $ Gst/AudioFlags#>(static_cast<unsigned>(lhs) & static_cast<unsigned>(rhs)); } |
| 77 | |
| 78 | /** @ingroup gstreamermmEnums */ |
| 79 | inline AudioFlagscxx . . $ Gst/AudioFlags# operatorcxx . . $ Gst/`operator^`(b22c0b981fdc5411).^(AudioFlagscxx . . $ Gst/AudioFlags# lhs, AudioFlagscxx . . $ Gst/AudioFlags# rhs) |
| 80 | { return static_cast<AudioFlagscxx . . $ Gst/AudioFlags#>(static_cast<unsigned>(lhs) ^ static_cast<unsigned>(rhs)); } |
| 81 | |
| 82 | /** @ingroup gstreamermmEnums */ |
| 83 | inline AudioFlagscxx . . $ Gst/AudioFlags# operatorcxx . . $ Gst/`operator~`(fd92c286fd840f40).~(AudioFlagscxx . . $ Gst/AudioFlags# flags) |
| 84 | { return static_cast<AudioFlagscxx . . $ Gst/AudioFlags#>(~static_cast<unsigned>(flags)); } |
| 85 | |
| 86 | /** @ingroup gstreamermmEnums */ |
| 87 | inline AudioFlagscxx . . $ Gst/AudioFlags#& operatorcxx . . $ Gst/`operator|=`(b80056a1cb9ea939).|=(AudioFlagscxx . . $ Gst/AudioFlags#& lhs, AudioFlagscxx . . $ Gst/AudioFlags# rhs) |
| 88 | { return (lhs = static_cast<AudioFlagscxx . . $ Gst/AudioFlags#>(static_cast<unsigned>(lhs) | static_cast<unsigned>(rhs))); } |
| 89 | |
| 90 | /** @ingroup gstreamermmEnums */ |
| 91 | inline AudioFlagscxx . . $ Gst/AudioFlags#& operatorcxx . . $ Gst/`operator&=`(b80056a1cb9ea939).&=(AudioFlagscxx . . $ Gst/AudioFlags#& lhs, AudioFlagscxx . . $ Gst/AudioFlags# rhs) |
| 92 | { return (lhs = static_cast<AudioFlagscxx . . $ Gst/AudioFlags#>(static_cast<unsigned>(lhs) & static_cast<unsigned>(rhs))); } |
| 93 | |
| 94 | /** @ingroup gstreamermmEnums */ |
| 95 | inline AudioFlagscxx . . $ Gst/AudioFlags#& operatorcxx . . $ Gst/`operator^=`(b80056a1cb9ea939).^=(AudioFlagscxx . . $ Gst/AudioFlags#& lhs, AudioFlagscxx . . $ Gst/AudioFlags# rhs) |
| 96 | { return (lhs = static_cast<AudioFlagscxx . . $ Gst/AudioFlags#>(static_cast<unsigned>(lhs) ^ static_cast<unsigned>(rhs))); } |
| 97 | |
| 98 | } // namespace Gst |
| 99 | |
| 100 | #ifndef DOXYGEN_SHOULD_SKIP_THIS |
| 101 | namespace Glibcxx . . $ Glib/ |
| 102 | { |
| 103 | |
| 104 | template <> |
| 105 | class Valuecxx . . $ Glib/Value#<Gstcxx . . $ Gst/::AudioFlagscxx . . $ Gst/AudioFlags#> : public Glibcxx . . $ Glib/::Value_Flagscxx . . $ Glib/Value_Flags#<Gstcxx . . $ Gst/::AudioFlagscxx . . $ Gst/AudioFlags#> |
| 106 | { |
| 107 | public: |
| 108 | static GType value_typecxx . . $ Glib/Value#value_type(f708dce9a8856c70).() G_GNUC_CONSTcxx . . $ `<external>/12741050725406041920/gmacros.h:640:9`!; |
| 109 | }; |
| 110 | |
| 111 | } // namespace Glib |
| 112 | #endif /* DOXYGEN_SHOULD_SKIP_THIS */ |
| 113 | |
| 114 | namespace Gstcxx . . $ Gst/ |
| 115 | { |
| 116 | |
| 117 | /** |
| 118 | * @var AudioLayout AUDIO_LAYOUT_INTERLEAVED |
| 119 | * Interleaved audio. |
| 120 | * |
| 121 | * @var AudioLayout AUDIO_LAYOUT_NON_INTERLEAVED |
| 122 | * Non-interleaved audio. |
| 123 | * |
| 124 | * @enum AudioLayout |
| 125 | * |
| 126 | * Layout of the audio samples for the different channels. |
| 127 | * |
| 128 | * @ingroup gstreamermmEnums |
| 129 | */ |
| 130 | enum AudioLayoutcxx . . $ Gst/AudioLayout# |
| 131 | { |
| 132 | AUDIO_LAYOUT_INTERLEAVEDcxx . . $ Gst/AUDIO_LAYOUT_INTERLEAVED., |
| 133 | AUDIO_LAYOUT_NON_INTERLEAVEDcxx . . $ Gst/AUDIO_LAYOUT_NON_INTERLEAVED. |
| 134 | }; |
| 135 | |
| 136 | } // namespace Gst |
| 137 | |
| 138 | #ifndef DOXYGEN_SHOULD_SKIP_THIS |
| 139 | namespace Glibcxx . . $ Glib/ |
| 140 | { |
| 141 | |
| 142 | template <> |
| 143 | class Valuecxx . . $ Glib/Value#<Gstcxx . . $ Gst/::AudioLayoutcxx . . $ Gst/AudioLayout#> : public Glibcxx . . $ Glib/::Value_Enumcxx . . $ Glib/Value_Enum#<Gstcxx . . $ Gst/::AudioLayoutcxx . . $ Gst/AudioLayout#> |
| 144 | { |
| 145 | public: |
| 146 | static GType value_typecxx . . $ Glib/Value#value_type(f708dce9a8856c70).() G_GNUC_CONSTcxx . . $ `<external>/12741050725406041920/gmacros.h:640:9`!; |
| 147 | }; |
| 148 | |
| 149 | } // namespace Glib |
| 150 | #endif /* DOXYGEN_SHOULD_SKIP_THIS */ |
| 151 | |
| 152 | namespace Gstcxx . . $ Gst/ |
| 153 | { |
| 154 | |
| 155 | |
| 156 | class Capscxx . . $ Gst/Caps#; |
| 157 | |
| 158 | /** Information describing audio properties. This information can be filled |
| 159 | * in from Gst::Caps with from_caps() or Gst::AudioInfo() constructor. |
| 160 | * |
| 161 | * Last reviewed on 2016-04-23 (1.8.0). |
| 162 | */ |
| 163 | class AudioInfocxx . . $ Gst/AudioInfo# |
| 164 | { |
| 165 | public: |
| 166 | #ifndef DOXYGEN_SHOULD_SKIP_THIS |
| 167 | using CppObjectTypecxx . . $ Gst/AudioInfo#CppObjectType# = AudioInfocxx . . $ Gst/AudioInfo#; |
| 168 | using BaseObjectTypecxx . . $ Gst/AudioInfo#BaseObjectType# = GstAudioInfo; |
| 169 | #endif /* DOXYGEN_SHOULD_SKIP_THIS */ |
| 170 | |
| 171 | /** Get the GType for this class, for use with the underlying GObject type system. |
| 172 | */ |
| 173 | static GType get_typecxx . . $ Gst/AudioInfo#get_type(f708dce9a8856c70).() G_GNUC_CONSTcxx . . $ `gstreamer/gstreamermm/wrap_init.cc:9:9`!; |
| 174 | |
| 175 | AudioInfocxx . . $ Gst/AudioInfo#AudioInfo(49f6e7a06ebc5aa8).(); |
| 176 | |
| 177 | explicit AudioInfocxx . . $ Gst/AudioInfo#AudioInfo(8df71ef4af0f0172).(GstAudioInfo* gobject, bool make_a_copy = true); |
| 178 | |
| 179 | AudioInfocxx . . $ Gst/AudioInfo#AudioInfo(f99e2ce961b44cfb).(const AudioInfocxx . . $ Gst/AudioInfo#& other); |
| 180 | AudioInfocxx . . $ Gst/AudioInfo#& operatorcxx . . $ Gst/AudioInfo#`operator=`(418a46c186823bb8).=(const AudioInfocxx . . $ Gst/AudioInfo#& other); |
| 181 | |
| 182 | AudioInfocxx . . $ Gst/AudioInfo#AudioInfo(9c39e361e4e6c2dd).(AudioInfocxx . . $ Gst/AudioInfo#&& other) noexcept; |
| 183 | AudioInfocxx . . $ Gst/AudioInfo#& operatorcxx . . $ Gst/AudioInfo#`operator=`(1a071e740c2f7f00).=(AudioInfocxx . . $ Gst/AudioInfo#&& other) noexcept; |
| 184 | |
| 185 | ~cxx . . $ Gst/AudioInfo#`~AudioInfo`(ced63f7c635d850d).AudioInfocxx . . $ Gst/AudioInfo#() noexcept; |
| 186 | |
| 187 | void swapcxx . . $ Gst/AudioInfo#swap(c0402145d015f630).(AudioInfocxx . . $ Gst/AudioInfo#& other) noexcept; |
| 188 | |
| 189 | ///Provides access to the underlying C instance. |
| 190 | GstAudioInfo* gobjcxx . . $ Gst/AudioInfo#gobj(eb03a130b2781152).() { return gobject_cxx . . $ Gst/AudioInfo#gobject_.; } |
| 191 | |
| 192 | ///Provides access to the underlying C instance. |
| 193 | const GstAudioInfo* gobjcxx . . $ Gst/AudioInfo#gobj(f15a4bc4e44e9e33).() const { return gobject_cxx . . $ Gst/AudioInfo#gobject_.; } |
| 194 | |
| 195 | ///Provides access to the underlying C instance. The caller is responsible for freeing it. Use when directly setting fields in structs. |
| 196 | GstAudioInfo* gobj_copycxx . . $ Gst/AudioInfo#gobj_copy(d46f0615a1796e79).() const; |
| 197 | |
| 198 | protected: |
| 199 | GstAudioInfo* gobject_cxx . . $ Gst/AudioInfo#gobject_.; |
| 200 | |
| 201 | private: |
| 202 | |
| 203 | |
| 204 | public: |
| 205 | |
| 206 | /** Create AudioInfo from @a caps. |
| 207 | * |
| 208 | * @param caps A Gst::Caps. |
| 209 | * |
| 210 | * @throw std::runtime_error if @a caps could not be parsed. |
| 211 | */ |
| 212 | AudioInfocxx . . $ Gst/AudioInfo#AudioInfo(67154a57170ef2a4).(const Glibcxx . . $ Glib/::RefPtrcxx . . $ Glib/RefPtr#<const Gstcxx . . $ Gst/::Capscxx . . $ Gst/Caps#>& caps); |
| 213 | |
| 214 | |
| 215 | /** Compares two Gst::AudioInfo and returns whether they are equal or not |
| 216 | * |
| 217 | * @param other A Gst::AudioInfo. |
| 218 | * @return <tt>true</tt> if @a info and @a other are equal, else <tt>false</tt>. |
| 219 | */ |
| 220 | bool is_equalcxx . . $ Gst/AudioInfo#is_equal(80854666e73ab84b).(const Gstcxx . . $ Gst/::AudioInfocxx . . $ Gst/AudioInfo#& other) const; |
| 221 | |
| 222 | |
| 223 | /** Initialize @a info with default values. |
| 224 | */ |
| 225 | void initcxx . . $ Gst/AudioInfo#init(49f6e7a06ebc5aa8).(); |
| 226 | |
| 227 | |
| 228 | /** Parse @a caps and update @a info. |
| 229 | * |
| 230 | * @param caps A Gst::Caps. |
| 231 | * @return <tt>true</tt> if @a caps could be parsed. |
| 232 | */ |
| 233 | bool from_capscxx . . $ Gst/AudioInfo#from_caps(f64280a2813dcce4).(const Glibcxx . . $ Glib/::RefPtrcxx . . $ Glib/RefPtr#<const Gstcxx . . $ Gst/::Capscxx . . $ Gst/Caps#>& caps); |
| 234 | |
| 235 | /** Convert the values of @a info into a Gst::Caps. |
| 236 | * |
| 237 | * @return The new Gst::Caps containing the |
| 238 | * info of @a info. |
| 239 | */ |
| 240 | Glibcxx . . $ Glib/::RefPtrcxx . . $ Glib/RefPtr#<Gstcxx . . $ Gst/::Capscxx . . $ Gst/Caps#> to_capscxx . . $ Gst/AudioInfo#to_caps(4265aad93b8ec881).() const; |
| 241 | |
| 242 | |
| 243 | /** Converts among various Gst::Format types. This function handles |
| 244 | * GST_FORMAT_BYTES, GST_FORMAT_TIME, and GST_FORMAT_DEFAULT. For |
| 245 | * raw audio, GST_FORMAT_DEFAULT corresponds to audio frames. This |
| 246 | * function can be used to handle pad queries of the type GST_QUERY_CONVERT. |
| 247 | * |
| 248 | * @newin{1,8} |
| 249 | * |
| 250 | * @param fmt Gst::Format of the @a src_val. |
| 251 | * @param src_val Value to convert. |
| 252 | * @param dest_fmt Gst::Format of the @a dest_val. |
| 253 | * @param dest_val Pointer to destination value. |
| 254 | * @return <tt>true</tt> if the conversion was successful. |
| 255 | */ |
| 256 | bool convertcxx . . $ Gst/AudioInfo#convert(71f0eba8c39f35a9).(Gstcxx . . $ Gst/::Formatcxx . . $ Gst/Format# fmt, gint64 src_val, Gstcxx . . $ Gst/::Formatcxx . . $ Gst/Format# dest_fmt, gint64& dest_val) const; |
| 257 | |
| 258 | |
| 259 | /** Set the default info for the audio info of @a format and @a rate and @a channels. |
| 260 | * |
| 261 | * @note This initializes @a info first, no values are preserved. |
| 262 | * |
| 263 | * @newin{1,8} |
| 264 | * |
| 265 | * @param format The format. |
| 266 | * @param rate The samplerate. |
| 267 | * @param channels The number of channels. |
| 268 | * @param position The channel positions. |
| 269 | */ |
| 270 | void set_formatcxx . . $ Gst/AudioInfo#set_format(c94051293b5e185f).(Gstcxx . . $ Gst/::AudioFormatcxx . . $ Gst/AudioFormat# format, int rate, int channels, const Gstcxx . . $ Gst/::AudioChannelPositioncxx . . $ Gst/AudioChannelPosition# * position); |
| 271 | |
| 272 | Gstcxx . . $ Gst/::AudioFlagscxx . . $ Gst/AudioFlags# get_flagscxx . . $ Gst/AudioInfo#get_flags(8c3a0a5a27fb980e).() const; |
| 273 | void set_flagscxx . . $ Gst/AudioInfo#set_flags(4b65f5203191b97a).(const Gstcxx . . $ Gst/::AudioFlagscxx . . $ Gst/AudioFlags#& value); |
| 274 | |
| 275 | Gstcxx . . $ Gst/::AudioLayoutcxx . . $ Gst/AudioLayout# get_layoutcxx . . $ Gst/AudioInfo#get_layout(5f96b242a7563e27).() const; |
| 276 | void set_layoutcxx . . $ Gst/AudioInfo#set_layout(730f3f4f087702).(const Gstcxx . . $ Gst/::AudioLayoutcxx . . $ Gst/AudioLayout#& value); |
| 277 | |
| 278 | int get_ratecxx . . $ Gst/AudioInfo#get_rate(455f465bc33b4cdf).() const; |
| 279 | void set_ratecxx . . $ Gst/AudioInfo#set_rate(794bbbca577513a2).(const int& value); |
| 280 | |
| 281 | int get_channelscxx . . $ Gst/AudioInfo#get_channels(455f465bc33b4cdf).() const; |
| 282 | void set_channelscxx . . $ Gst/AudioInfo#set_channels(794bbbca577513a2).(const int& value); |
| 283 | |
| 284 | int get_bpfcxx . . $ Gst/AudioInfo#get_bpf(455f465bc33b4cdf).() const; |
| 285 | void set_bpfcxx . . $ Gst/AudioInfo#set_bpf(794bbbca577513a2).(const int& value); |
| 286 | |
| 287 | const Gstcxx . . $ Gst/::AudioFormatInfocxx . . $ Gst/AudioFormatInfo# get_finfocxx . . $ Gst/AudioInfo#get_finfo(927a07c7471951ed).() const; |
| 288 | |
| 289 | |
| 290 | }; |
| 291 | |
| 292 | } |
| 293 | |
| 294 | |
| 295 | namespace Gstcxx . . $ Gst/ |
| 296 | { |
| 297 | |
| 298 | /** @relates Gst::AudioInfo |
| 299 | * @param lhs The left-hand side |
| 300 | * @param rhs The right-hand side |
| 301 | */ |
| 302 | inline void swapcxx . . $ Gst/swap(c2d34088d9b3c590).(AudioInfocxx . . $ Gst/AudioInfo#& lhs, AudioInfocxx . . $ Gst/AudioInfo#& rhs) noexcept |
| 303 | { lhs.swapcxx . . $ Gst/AudioInfo#swap(c0402145d015f630).(rhs); } |
| 304 | |
| 305 | } // namespace Gst |
| 306 | |
| 307 | namespace Glibcxx . . $ Glib/ |
| 308 | { |
| 309 | |
| 310 | /** A Glib::wrap() method for this object. |
| 311 | * |
| 312 | * @param object The C instance. |
| 313 | * @param take_copy False if the result should take ownership of the C instance. True if it should take a new copy or ref. |
| 314 | * @result A C++ instance that wraps this C instance. |
| 315 | * |
| 316 | * @relates Gst::AudioInfo |
| 317 | */ |
| 318 | Gstcxx . . $ Gst/::AudioInfocxx . . $ Gst/AudioInfo# wrapcxx . . $ Glib/wrap(186b8a918d30436a).(GstAudioInfo* object, bool take_copy = false); |
| 319 | |
| 320 | #ifndef DOXYGEN_SHOULD_SKIP_THIS |
| 321 | template <> |
| 322 | class Valuecxx . . $ Glib/Value#<Gstcxx . . $ Gst/::AudioInfocxx . . $ Gst/AudioInfo#> : public Glibcxx . . $ Glib/::Value_Boxedcxx . . $ Glib/Value_Boxed#<Gstcxx . . $ Gst/::AudioInfocxx . . $ Gst/AudioInfo#> |
| 323 | {}; |
| 324 | #endif /* DOXYGEN_SHOULD_SKIP_THIS */ |
| 325 | |
| 326 | } // namespace Glib |
| 327 | |
| 328 | |
| 329 | #endif /* _GSTREAMERMM_AUDIOINFO_H */ |
| 330 |