Tizen 2.0 Release
[framework/multimedia/gst-plugins-good0.10.git] / ext / jack / gstjackaudiosink.h
1 /* GStreamer
2  * Copyright (C) 2006 Wim Taymans <wim@fluendo.com>
3  *
4  * gstjacksink.h:
5  *
6  * This library is free software; you can redistribute it and/or
7  * modify it under the terms of the GNU Library General Public
8  * License as published by the Free Software Foundation; either
9  * version 2 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  * Library General Public License for more details.
15  *
16  * You should have received a copy of the GNU Library General Public
17  * License along with this library; if not, write to the
18  * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
19  * Boston, MA 02111-1307, USA.
20  */
21
22 #ifndef __GST_JACK_AUDIO_SINK_H__
23 #define __GST_JACK_AUDIO_SINK_H__
24
25 #include <jack/jack.h>
26
27 #include <gst/gst.h>
28 #include <gst/audio/gstbaseaudiosink.h>
29
30 #include "gstjack.h"
31 #include "gstjackaudioclient.h"
32
33 G_BEGIN_DECLS
34
35 #define GST_TYPE_JACK_AUDIO_SINK             (gst_jack_audio_sink_get_type())
36 #define GST_JACK_AUDIO_SINK(obj)             (G_TYPE_CHECK_INSTANCE_CAST((obj),GST_TYPE_JACK_AUDIO_SINK,GstJackAudioSink))
37 #define GST_JACK_AUDIO_SINK_CLASS(klass)     (G_TYPE_CHECK_CLASS_CAST((klass),GST_TYPE_JACK_AUDIO_SINK,GstJackAudioSinkClass))
38 #define GST_JACK_AUDIO_SINK_GET_CLASS(obj)   (G_TYPE_INSTANCE_GET_CLASS ((obj),GST_TYPE_JACK_AUDIO_SINK,GstJackAudioSinkClass))
39 #define GST_IS_JACK_AUDIO_SINK(obj)          (G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_JACK_AUDIO_SINK))
40 #define GST_IS_JACK_AUDIO_SINK_CLASS(klass)  (G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_JACK_AUDIO_SINK))
41
42 typedef struct _GstJackAudioSink GstJackAudioSink;
43 typedef struct _GstJackAudioSinkClass GstJackAudioSinkClass;
44
45 /**
46  * GstJackAudioSink:
47  * 
48  * Opaque #GstJackAudioSink.
49  */
50 struct _GstJackAudioSink {
51   GstBaseAudioSink element;
52
53   /*< private >*/
54   /* cached caps */
55   GstCaps         *caps;
56
57   /* properties */
58   GstJackConnect   connect;
59   gchar           *server;
60   jack_client_t   *jclient;
61   gchar           *client_name;
62
63   /* our client */
64   GstJackAudioClient *client;
65
66   /* our ports */
67   jack_port_t    **ports;
68   int              port_count;
69   sample_t       **buffers;
70 };
71
72 struct _GstJackAudioSinkClass {
73   GstBaseAudioSinkClass parent_class;
74 };
75
76 GType gst_jack_audio_sink_get_type (void);
77
78 G_END_DECLS
79
80 #endif /* __GST_JACK_AUDIO_SINK_H__ */