1 /* GStreamer AC3 parser 2 * Copyright (C) 2009 Tim-Philipp Müller <tim centricular net> 3 * Copyright (C) 2009 Mark Nauwelaerts <mnauw users sf net> 4 * Copyright (C) 2009 Nokia Corporation. All rights reserved. 5 * Contact: Stefan Kost <stefan.kost@nokia.com> 6 * 7 * This library is free software; you can redistribute it and/or 8 * modify it under the terms of the GNU Library General Public 9 * License as published by the Free Software Foundation; either 10 * version 2 of the License, or (at your option) any later version. 11 * 12 * This library is distributed in the hope that it will be useful, 13 * but WITHOUT ANY WARRANTY; without even the implied warranty of 14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 15 * Library General Public License for more details. 16 * 17 * You should have received a copy of the GNU Library General Public 18 * License along with this library; if not, write to the 19 * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, 20 * Boston, MA 02110-1301, USA. 21 */ 22 23 #ifndef __GST_AC3_PARSE_H__ 24 #define __GST_AC3_PARSE_H__ 25 26 #include <gst/gst.h> 27 #include <gst/base/gstbaseparse.h> 28 29 G_BEGIN_DECLS 30 31 #define GST_TYPE_AC3_PARSE \ 32 (gst_ac3_parse_get_type()) 33 #define GST_AC3_PARSE(obj) \ 34 (G_TYPE_CHECK_INSTANCE_CAST((obj), GST_TYPE_AC3_PARSE, GstAc3Parse)) 35 #define GST_AC3_PARSE_CLASS(klass) \ 36 (G_TYPE_CHECK_CLASS_CAST((klass), GST_TYPE_AC3_PARSE, GstAc3ParseClass)) 37 #define GST_IS_AC3_PARSE(obj) \ 38 (G_TYPE_CHECK_INSTANCE_TYPE((obj), GST_TYPE_AC3_PARSE)) 39 #define GST_IS_AC3_PARSE_CLASS(klass) \ 40 (G_TYPE_CHECK_CLASS_TYPE((klass), GST_TYPE_AC3_PARSE)) 41 42 typedef struct _GstAc3Parse GstAc3Parse; 43 typedef struct _GstAc3ParseClass GstAc3ParseClass; 44 45 enum { 46 GST_AC3_PARSE_ALIGN_NONE, 47 GST_AC3_PARSE_ALIGN_FRAME, 48 GST_AC3_PARSE_ALIGN_IEC61937, 49 }; 50 51 /** 52 * GstAc3Parse: 53 * 54 * The opaque GstAc3Parse object 55 */ 56 struct _GstAc3Parse { 57 GstBaseParse baseparse; 58 59 /*< private >*/ 60 gint sample_rate; 61 gint channels; 62 gint blocks; 63 gboolean eac; 64 gboolean sent_codec_tag; 65 gint align; 66 GstPadChainFunction baseparse_chainfunc; 67 }; 68 69 /** 70 * GstAc3ParseClass: 71 * @parent_class: Element parent class. 72 * 73 * The opaque GstAc3ParseClass data structure. 74 */ 75 struct _GstAc3ParseClass { 76 GstBaseParseClass baseparse_class; 77 }; 78 79 GType gst_ac3_parse_get_type (void); 80 81 G_END_DECLS 82 83 #endif /* __GST_AC3_PARSE_H__ */ 84