Merging gst-editing-services
[platform/upstream/gstreamer.git] / subprojects / gst-plugins-good / ext / lame / gstlamemp3enc.h
1 /* GStreamer
2  * Copyright (C) <1999> Erik Walthinsen <omega@cse.ogi.edu>
3  * Copyright (C) <2009> Sebastian Dröge <sebastian.droege@collabora.co.uk>
4  *
5  * This library is free software; you can redistribute it and/or
6  * modify it under the terms of the GNU Library General Public
7  * License as published by the Free Software Foundation; either
8  * version 2 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  * Library General Public License for more details.
14  *
15  * You should have received a copy of the GNU Library General Public
16  * License along with this library; if not, write to the
17  * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
18  * Boston, MA 02110-1301, USA.
19  */
20
21
22 #ifndef __GST_LAMEMP3ENC_H__
23 #define __GST_LAMEMP3ENC_H__
24
25
26 #include <gst/gst.h>
27 #include <gst/audio/gstaudioencoder.h>
28 #include <gst/base/gstadapter.h>
29
30 G_BEGIN_DECLS
31
32 #include <lame/lame.h>
33
34 #define GST_TYPE_LAMEMP3ENC (gst_lamemp3enc_get_type())
35 G_DECLARE_FINAL_TYPE (GstLameMP3Enc, gst_lamemp3enc, GST, LAMEMP3ENC,
36     GstAudioEncoder)
37
38 /**
39  * GstLameMP3Enc:
40  *
41  * Opaque data structure.
42  */
43 struct _GstLameMP3Enc {
44   GstAudioEncoder element;
45
46   /*< private >*/
47   gint samplerate;
48   gint out_samplerate;
49   gint num_channels;
50
51   /* properties */
52   gint target;
53   gint bitrate;
54   gboolean cbr;
55   gfloat quality;
56   gint encoding_engine_quality;
57   gboolean mono;
58
59   lame_global_flags *lgf;
60
61   GstAdapter *adapter;
62 };
63
64 GST_ELEMENT_REGISTER_DECLARE (lamemp3enc);
65
66 G_END_DECLS
67
68 #endif /* __GST_LAMEMP3ENC_H__ */