| 1 |
/* gstreamermm - a C++ wrapper for gstreamer |
| 2 |
* |
| 3 |
* Copyright 2008-2016 The gstreamermm Development Team |
| 4 |
* |
| 5 |
* This library is free software; you can redistribute it and/or |
| 6 |
* modify it under the terms of the GNU Lesser General Public |
| 7 |
* License as published by the Free Software Foundation; either |
| 8 |
* version 2.1 of the License, or (at your option) any later version. |
| 9 |
* |
| 10 |
* This library 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 GNU |
| 13 |
* Lesser General Public License for more details. |
| 14 |
* |
| 15 |
* You should have received a copy of the GNU Lesser General Public |
| 16 |
* License along with this library; if not, write to the Free |
| 17 |
* Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. |
| 18 |
*/ |
| 19 |
|
| 20 |
#include <gst/audio/audio-format.h> |
| 21 |
|
| 22 |
_DEFS(gstreamermm,gst) |
| 23 |
|
| 24 |
namespace Gst |
| 25 |
{ |
| 26 |
|
| 27 |
_WRAP_ENUM(AudioFormat, GstAudioFormat) |
| 28 |
_WRAP_ENUM(AudioFormatFlags, GstAudioFormatFlags) |
| 29 |
_WRAP_ENUM(AudioPackFlags, GstAudioPackFlags) |
| 30 |
|
| 31 |
/** |
| 32 |
* Information for an audio format. |
| 33 |
* |
| 34 |
* Last reviewed on 2016-04-23 (1.8.0). |
| 35 |
*/ |
| 36 |
class AudioFormatInfo |
| 37 |
{ |
| 38 |
_CLASS_GENERIC(AudioFormatInfo, GstAudioFormatInfo) |
| 39 |
public: |
| 40 |
AudioFormatInfo(const GstAudioFormatInfo *m_info); |
| 41 |
|
| 42 |
/// Gets the underlying gobject. |
| 43 |
GstAudioFormatInfo* gobj() { return &m_info; }; |
| 44 |
|
| 45 |
/// Gets the underlying gobject. |
| 46 |
const GstAudioFormatInfo* gobj() const { return &m_info; }; |
| 47 |
|
| 48 |
_MEMBER_GET(format, format, AudioFormat, GstAudioFormat) |
| 49 |
_MEMBER_SET(format, format, AudioFormat, GstAudioFormat) |
| 50 |
|
| 51 |
_MEMBER_GET(name, name, std::string, const char*) |
| 52 |
_MEMBER_SET(name, name, std::string, const char*) |
| 53 |
|
| 54 |
_MEMBER_GET(description, description, std::string, const char*) |
| 55 |
_MEMBER_SET(description, description, std::string, const char*) |
| 56 |
|
| 57 |
_MEMBER_GET(flags, flags, AudioFormatFlags, GstAudioFormatFlags) |
| 58 |
_MEMBER_SET(flags, flags, AudioFormatFlags, GstAudioFormatFlags) |
| 59 |
|
| 60 |
_MEMBER_GET(endianness, endianness, int, gint) |
| 61 |
_MEMBER_SET(endianness, endianness, int, gint) |
| 62 |
|
| 63 |
_MEMBER_GET(width, width, int, gint) |
| 64 |
_MEMBER_SET(width, width, int, gint) |
| 65 |
|
| 66 |
_MEMBER_GET(depth, depth, int, gint) |
| 67 |
_MEMBER_SET(depth, depth, int, gint) |
| 68 |
|
| 69 |
_MEMBER_GET(unpack_format, unpack_format, AudioFormat, GstAudioFormat) |
| 70 |
_MEMBER_SET(unpack_format, unpack_format, AudioFormat, GstAudioFormat) |
| 71 |
|
| 72 |
protected: |
| 73 |
#ifndef DOXYGEN_SHOULD_SKIP_THIS |
| 74 |
GstAudioFormatInfo m_info; |
| 75 |
#endif |
| 76 |
}; |
| 77 |
} //namespace Gst |