• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /* GStreamer openaptx audio decoder
2  *
3  * Copyright (C) 2020 Igor V. Kovalenko <igor.v.kovalenko@gmail.com>
4  * Copyright (C) 2020 Thomas Weißschuh <thomas@t-8ch.de>
5  *
6  * This library is free software; you can redistribute it and/or
7  * modify it under the terms of the GNU Lesser General Public
8  * License as published by the Free Software Foundation; either
9  * version 2.1 of the License, or (at your option) any later version.
10  *
11  * This library is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
14  * Lesser General Public License for more details.
15  *
16  * You should have received a copy of the GNU Lesser General Public
17  * License along with this library; if not, write to the Free Software
18  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
19  *
20  */
21 #ifndef __GST_OPENAPTXDEC_H__
22 #define __GST_OPENAPTXDEC_H__
23 
24 #include <gst/gst.h>
25 #include <gst/audio/audio.h>
26 
27 #ifdef USE_FREEAPTX
28 #include <freeaptx.h>
29 #else
30 #include <openaptx.h>
31 #endif
32 
33 G_BEGIN_DECLS
34 
35 #define GST_TYPE_OPENAPTX_DEC (gst_openaptx_dec_get_type())
36 G_DECLARE_FINAL_TYPE (GstOpenaptxDec, gst_openaptx_dec, GST, OPENAPTX_DEC, GstAudioEncoder)
37 
38 struct _GstOpenaptxDec {
39   GstAudioDecoder audio_decoder;
40 
41   gboolean hd;
42   gboolean autosync;
43 
44   struct aptx_context *aptx_c;
45 };
46 
47 GST_ELEMENT_REGISTER_DECLARE (openaptxdec)
48 
49 G_END_DECLS
50 
51 #endif /* __GST_OPENAPTXDEC_H__ */
52