Mercurial > pidgin
annotate libpurple/media.h @ 26019:5a3d1a3ae9f3
merge of 'a617f86bc9f9f151daef5b0980c124f94f277f9a'
and 'dca923f5c49ff1a1638b3ac1529f82d846737578'
author | Mike Ruprecht <maiku@soc.pidgin.im> |
---|---|
date | Sat, 10 Jan 2009 01:29:40 +0000 |
parents | b6457b2a8e14 |
children | f7cf50180e1d |
rev | line source |
---|---|
23760 | 1 /** |
23766 | 2 * @file media.h Media API |
23760 | 3 * @ingroup core |
23865
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
4 */ |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
5 |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
6 /* purple |
23760 | 7 * |
8 * Purple is the legal property of its developers, whose names are too numerous | |
9 * to list here. Please refer to the COPYRIGHT file distributed with this | |
10 * source distribution. | |
11 * | |
12 * This program is free software; you can redistribute it and/or modify | |
13 * it under the terms of the GNU General Public License as published by | |
14 * the Free Software Foundation; either version 2 of the License, or | |
15 * (at your option) any later version. | |
16 * | |
17 * This program is distributed in the hope that it will be useful, | |
18 * but WITHOUT ANY WARRANTY; without even the implied warranty of | |
19 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
20 * GNU General Public License for more details. | |
21 * | |
22 * You should have received a copy of the GNU General Public License | |
23 * along with this program; if not, write to the Free Software | |
24 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | |
25 */ | |
26 | |
27 #ifndef __MEDIA_H_ | |
28 #define __MEDIA_H_ | |
29 | |
23804
cbe97caec684
Use USE_VV instead of USE_FARSIGHT.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23801
diff
changeset
|
30 #ifdef USE_VV |
23760 | 31 |
23797
e1c8ec1259de
Updates voice and video to use Farsight 2, gets XMPP voice conferences
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23793
diff
changeset
|
32 #include <gst/gst.h> |
e1c8ec1259de
Updates voice and video to use Farsight 2, gets XMPP voice conferences
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23793
diff
changeset
|
33 #include <gst/farsight/fs-stream.h> |
23760 | 34 #include <glib.h> |
35 #include <glib-object.h> | |
36 | |
37 G_BEGIN_DECLS | |
38 | |
39 #define PURPLE_TYPE_MEDIA (purple_media_get_type()) | |
40 #define PURPLE_MEDIA(obj) (G_TYPE_CHECK_INSTANCE_CAST((obj), PURPLE_TYPE_MEDIA, PurpleMedia)) | |
41 #define PURPLE_MEDIA_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST((klass), PURPLE_TYPE_MEDIA, PurpleMediaClass)) | |
42 #define PURPLE_IS_MEDIA(obj) (G_TYPE_CHECK_INSTANCE_TYPE((obj), PURPLE_TYPE_MEDIA)) | |
43 #define PURPLE_IS_MEDIA_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE((klass), PURPLE_TYPE_MEDIA)) | |
44 #define PURPLE_MEDIA_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS((obj), PURPLE_TYPE_MEDIA, PurpleMediaClass)) | |
45 | |
24993
7d2e06b29f88
Add state-changed signal to PurpleMedia.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24984
diff
changeset
|
46 #define PURPLE_MEDIA_TYPE_STATE_CHANGED (purple_media_state_changed_get_type()) |
7d2e06b29f88
Add state-changed signal to PurpleMedia.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24984
diff
changeset
|
47 |
23865
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
48 /** @copydoc _PurpleMedia */ |
23760 | 49 typedef struct _PurpleMedia PurpleMedia; |
23865
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
50 /** @copydoc _PurpleMediaClass */ |
23760 | 51 typedef struct _PurpleMediaClass PurpleMediaClass; |
23865
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
52 /** @copydoc _PurpleMediaPrivate */ |
23760 | 53 typedef struct _PurpleMediaPrivate PurpleMediaPrivate; |
54 | |
23859
eb8c8a926589
Convert serv_* media functions to purple_prpl_* functions.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23845
diff
changeset
|
55 #else |
eb8c8a926589
Convert serv_* media functions to purple_prpl_* functions.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23845
diff
changeset
|
56 |
eb8c8a926589
Convert serv_* media functions to purple_prpl_* functions.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23845
diff
changeset
|
57 typedef void PurpleMedia; |
eb8c8a926589
Convert serv_* media functions to purple_prpl_* functions.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23845
diff
changeset
|
58 |
eb8c8a926589
Convert serv_* media functions to purple_prpl_* functions.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23845
diff
changeset
|
59 #endif /* USE_VV */ |
eb8c8a926589
Convert serv_* media functions to purple_prpl_* functions.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23845
diff
changeset
|
60 |
23865
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
61 /** Media session types */ |
23760 | 62 typedef enum { |
23824
bfaad8393463
Added some utility functions to convert PurpleMediaStreamType
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23821
diff
changeset
|
63 PURPLE_MEDIA_NONE = 0, |
23760 | 64 PURPLE_MEDIA_RECV_AUDIO = 1 << 0, |
65 PURPLE_MEDIA_SEND_AUDIO = 1 << 1, | |
66 PURPLE_MEDIA_RECV_VIDEO = 1 << 2, | |
67 PURPLE_MEDIA_SEND_VIDEO = 1 << 3, | |
23797
e1c8ec1259de
Updates voice and video to use Farsight 2, gets XMPP voice conferences
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23793
diff
changeset
|
68 PURPLE_MEDIA_AUDIO = PURPLE_MEDIA_RECV_AUDIO | PURPLE_MEDIA_SEND_AUDIO, |
e1c8ec1259de
Updates voice and video to use Farsight 2, gets XMPP voice conferences
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23793
diff
changeset
|
69 PURPLE_MEDIA_VIDEO = PURPLE_MEDIA_RECV_VIDEO | PURPLE_MEDIA_SEND_VIDEO |
23869
551a462b346a
Changed PurpleMediaStreamType to PurpleMediaSessionType.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23865
diff
changeset
|
70 } PurpleMediaSessionType; |
23760 | 71 |
24993
7d2e06b29f88
Add state-changed signal to PurpleMedia.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24984
diff
changeset
|
72 /** Media state-changed types */ |
7d2e06b29f88
Add state-changed signal to PurpleMedia.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24984
diff
changeset
|
73 typedef enum { |
7d2e06b29f88
Add state-changed signal to PurpleMedia.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24984
diff
changeset
|
74 PURPLE_MEDIA_STATE_CHANGED_NEW = 0, |
7d2e06b29f88
Add state-changed signal to PurpleMedia.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24984
diff
changeset
|
75 PURPLE_MEDIA_STATE_CHANGED_CONNECTED, |
7d2e06b29f88
Add state-changed signal to PurpleMedia.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24984
diff
changeset
|
76 PURPLE_MEDIA_STATE_CHANGED_END, |
7d2e06b29f88
Add state-changed signal to PurpleMedia.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24984
diff
changeset
|
77 } PurpleMediaStateChangedType; |
7d2e06b29f88
Add state-changed signal to PurpleMedia.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24984
diff
changeset
|
78 |
23859
eb8c8a926589
Convert serv_* media functions to purple_prpl_* functions.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23845
diff
changeset
|
79 #ifdef USE_VV |
eb8c8a926589
Convert serv_* media functions to purple_prpl_* functions.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23845
diff
changeset
|
80 |
23865
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
81 /** The media class */ |
23760 | 82 struct _PurpleMediaClass |
83 { | |
23865
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
84 GObjectClass parent_class; /**< The parent class. */ |
23760 | 85 }; |
86 | |
23865
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
87 /** The media class's private data */ |
23760 | 88 struct _PurpleMedia |
89 { | |
23865
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
90 GObject parent; /**< The parent of this object. */ |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
91 PurpleMediaPrivate *priv; /**< The private data of this object. */ |
23760 | 92 }; |
93 | |
23865
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
94 #ifdef __cplusplus |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
95 extern "C" { |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
96 #endif |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
97 |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
98 /** |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
99 * Gets the media class's GType |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
100 * |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
101 * @return The media class's GType. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
102 */ |
23772
750d700098c1
Fix the prplinfo structs and get rid of some compile warnings.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents:
23766
diff
changeset
|
103 GType purple_media_get_type(void); |
23760 | 104 |
24993
7d2e06b29f88
Add state-changed signal to PurpleMedia.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24984
diff
changeset
|
105 /** |
7d2e06b29f88
Add state-changed signal to PurpleMedia.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24984
diff
changeset
|
106 * Gets the type of the state-changed enum |
7d2e06b29f88
Add state-changed signal to PurpleMedia.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24984
diff
changeset
|
107 * |
7d2e06b29f88
Add state-changed signal to PurpleMedia.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24984
diff
changeset
|
108 * @return The state-changed enum's GType |
7d2e06b29f88
Add state-changed signal to PurpleMedia.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24984
diff
changeset
|
109 */ |
7d2e06b29f88
Add state-changed signal to PurpleMedia.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24984
diff
changeset
|
110 GType purple_media_state_changed_get_type(void); |
7d2e06b29f88
Add state-changed signal to PurpleMedia.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24984
diff
changeset
|
111 |
23865
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
112 /** |
23869
551a462b346a
Changed PurpleMediaStreamType to PurpleMediaSessionType.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23865
diff
changeset
|
113 * Combines all the separate session types into a single PurpleMediaSessionType. |
23865
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
114 * |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
115 * @param media The media session to retrieve session types from. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
116 * |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
117 * @return Combined type. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
118 */ |
23869
551a462b346a
Changed PurpleMediaStreamType to PurpleMediaSessionType.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23865
diff
changeset
|
119 PurpleMediaSessionType purple_media_get_overall_type(PurpleMedia *media); |
23837
ddbea813862e
Notify the user which type of media session the remote user wants to initiate.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23830
diff
changeset
|
120 |
23865
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
121 /** |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
122 * Gets a list of session names. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
123 * |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
124 * @param media The media session to retrieve session names from. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
125 * |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
126 * @return GList of session names. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
127 */ |
23821
12a16471f94e
Refactored PurpleMedia to make creating audio or video sessions virtually identical. Audio, video, and audio/video sessions now work. Also added videotestsrc to the video plugin preference.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23804
diff
changeset
|
128 GList *purple_media_get_session_names(PurpleMedia *media); |
12a16471f94e
Refactored PurpleMedia to make creating audio or video sessions virtually identical. Audio, video, and audio/video sessions now work. Also added videotestsrc to the video plugin preference.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23804
diff
changeset
|
129 |
23865
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
130 /** |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
131 * Gets an audio and video source and sink from the media session. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
132 * |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
133 * Retrieves the first of each element in the media session. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
134 * |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
135 * @param media The media session to retreive the sources and sinks from. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
136 * @param audio_src Set to the audio source. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
137 * @param audio_sink Set to the audio sink. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
138 * @param video_src Set to the video source. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
139 * @param video_sink Set to the video sink. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
140 */ |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
141 void purple_media_get_elements(PurpleMedia *media, |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
142 GstElement **audio_src, GstElement **audio_sink, |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
143 GstElement **video_src, GstElement **video_sink); |
23762
70cdff43ec76
You can actually receive Google Talk voice calls with crappy UI now
Sean Egan <seanegan@gmail.com>
parents:
23760
diff
changeset
|
144 |
23865
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
145 /** |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
146 * Sets the source on a session. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
147 * |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
148 * @param media The media object the session is in. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
149 * @param sess_id The session id of the session to set the source on. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
150 * @param src The source to set the session source to. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
151 */ |
23821
12a16471f94e
Refactored PurpleMedia to make creating audio or video sessions virtually identical. Audio, video, and audio/video sessions now work. Also added videotestsrc to the video plugin preference.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23804
diff
changeset
|
152 void purple_media_set_src(PurpleMedia *media, const gchar *sess_id, GstElement *src); |
23865
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
153 |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
154 /** |
24976
01df0829f054
Move sink from PurpleMediaSession to PurpleMediaStream.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24971
diff
changeset
|
155 * Sets the sink on a stream. |
23865
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
156 * |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
157 * @param media The media object the session is in. |
24976
01df0829f054
Move sink from PurpleMediaSession to PurpleMediaStream.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24971
diff
changeset
|
158 * @param sess_id The session id the stream belongs to. |
01df0829f054
Move sink from PurpleMediaSession to PurpleMediaStream.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24971
diff
changeset
|
159 * @param sess_id The participant the stream is associated with. |
23865
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
160 * @param sink The source to set the session sink to. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
161 */ |
24976
01df0829f054
Move sink from PurpleMediaSession to PurpleMediaStream.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24971
diff
changeset
|
162 void purple_media_set_sink(PurpleMedia *media, const gchar *sess_id, |
01df0829f054
Move sink from PurpleMediaSession to PurpleMediaStream.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24971
diff
changeset
|
163 const gchar *participant, GstElement *sink); |
23762
70cdff43ec76
You can actually receive Google Talk voice calls with crappy UI now
Sean Egan <seanegan@gmail.com>
parents:
23760
diff
changeset
|
164 |
23865
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
165 /** |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
166 * Gets the source from a session |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
167 * |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
168 * @param media The media object the session is in. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
169 * @param sess_id The session id of the session to get the source from. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
170 * |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
171 * @return The source retrieved. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
172 */ |
23821
12a16471f94e
Refactored PurpleMedia to make creating audio or video sessions virtually identical. Audio, video, and audio/video sessions now work. Also added videotestsrc to the video plugin preference.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23804
diff
changeset
|
173 GstElement *purple_media_get_src(PurpleMedia *media, const gchar *sess_id); |
23865
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
174 |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
175 /** |
24976
01df0829f054
Move sink from PurpleMediaSession to PurpleMediaStream.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24971
diff
changeset
|
176 * Gets the sink from a stream |
23865
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
177 * |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
178 * @param media The media object the session is in. |
24976
01df0829f054
Move sink from PurpleMediaSession to PurpleMediaStream.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24971
diff
changeset
|
179 * @param sess_id The session id the stream belongs to. |
01df0829f054
Move sink from PurpleMediaSession to PurpleMediaStream.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24971
diff
changeset
|
180 * @param participant The participant the stream is associated with. |
23865
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
181 * |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
182 * @return The sink retrieved. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
183 */ |
24976
01df0829f054
Move sink from PurpleMediaSession to PurpleMediaStream.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24971
diff
changeset
|
184 GstElement *purple_media_get_sink(PurpleMedia *media, const gchar *sess_id, const gchar *participant); |
23762
70cdff43ec76
You can actually receive Google Talk voice calls with crappy UI now
Sean Egan <seanegan@gmail.com>
parents:
23760
diff
changeset
|
185 |
23865
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
186 /** |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
187 * Gets the pipeline from the media session. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
188 * |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
189 * @param media The media session to retrieve the pipeline from. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
190 * |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
191 * @return The pipeline retrieved. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
192 */ |
23821
12a16471f94e
Refactored PurpleMedia to make creating audio or video sessions virtually identical. Audio, video, and audio/video sessions now work. Also added videotestsrc to the video plugin preference.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23804
diff
changeset
|
193 GstElement *purple_media_get_pipeline(PurpleMedia *media); |
23762
70cdff43ec76
You can actually receive Google Talk voice calls with crappy UI now
Sean Egan <seanegan@gmail.com>
parents:
23760
diff
changeset
|
194 |
23865
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
195 /** |
24982
0ad1b8e950d7
Add purple_media_error.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24976
diff
changeset
|
196 * Signals an error in the media session. |
0ad1b8e950d7
Add purple_media_error.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24976
diff
changeset
|
197 * |
0ad1b8e950d7
Add purple_media_error.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24976
diff
changeset
|
198 * @param media The media object to set the state on. |
0ad1b8e950d7
Add purple_media_error.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24976
diff
changeset
|
199 * @param error The format of the error message to send in the signal. |
0ad1b8e950d7
Add purple_media_error.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24976
diff
changeset
|
200 * @param ... The arguments to plug into the format. |
0ad1b8e950d7
Add purple_media_error.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24976
diff
changeset
|
201 */ |
0ad1b8e950d7
Add purple_media_error.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24976
diff
changeset
|
202 void purple_media_error(PurpleMedia *media, const gchar *error, ...); |
0ad1b8e950d7
Add purple_media_error.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24976
diff
changeset
|
203 |
0ad1b8e950d7
Add purple_media_error.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24976
diff
changeset
|
204 /** |
23865
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
205 * Set the media session to the ready state. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
206 * |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
207 * @param media The media object to set the state on. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
208 */ |
23762
70cdff43ec76
You can actually receive Google Talk voice calls with crappy UI now
Sean Egan <seanegan@gmail.com>
parents:
23760
diff
changeset
|
209 void purple_media_ready(PurpleMedia *media); |
23865
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
210 |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
211 /** |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
212 * Set the media session to the wait state. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
213 * |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
214 * @param media The media object to set the state on. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
215 */ |
23793
befeece4dd48
Change a few things:
Sadrul Habib Chowdhury <imadil@gmail.com>
parents:
23787
diff
changeset
|
216 void purple_media_wait(PurpleMedia *media); |
23865
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
217 |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
218 /** |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
219 * Set the media session to the accepted state. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
220 * |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
221 * @param media The media object to set the state on. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
222 */ |
23762
70cdff43ec76
You can actually receive Google Talk voice calls with crappy UI now
Sean Egan <seanegan@gmail.com>
parents:
23760
diff
changeset
|
223 void purple_media_accept(PurpleMedia *media); |
23865
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
224 |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
225 /** |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
226 * Set the media session to the rejected state. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
227 * |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
228 * @param media The media object to set the state on. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
229 */ |
23762
70cdff43ec76
You can actually receive Google Talk voice calls with crappy UI now
Sean Egan <seanegan@gmail.com>
parents:
23760
diff
changeset
|
230 void purple_media_reject(PurpleMedia *media); |
23865
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
231 |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
232 /** |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
233 * Set the media session to the hangup state. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
234 * |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
235 * @param media The media object to set the state on. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
236 */ |
23762
70cdff43ec76
You can actually receive Google Talk voice calls with crappy UI now
Sean Egan <seanegan@gmail.com>
parents:
23760
diff
changeset
|
237 void purple_media_hangup(PurpleMedia *media); |
23865
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
238 |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
239 /** |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
240 * Set the media session to the got_request state. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
241 * |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
242 * @param media The media object to set the state on. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
243 */ |
23837
ddbea813862e
Notify the user which type of media session the remote user wants to initiate.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23830
diff
changeset
|
244 void purple_media_got_request(PurpleMedia *media); |
23865
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
245 |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
246 /** |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
247 * Set the media session to the got_hangup state. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
248 * |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
249 * @param media The media object to set the state on. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
250 */ |
23762
70cdff43ec76
You can actually receive Google Talk voice calls with crappy UI now
Sean Egan <seanegan@gmail.com>
parents:
23760
diff
changeset
|
251 void purple_media_got_hangup(PurpleMedia *media); |
23865
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
252 |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
253 /** |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
254 * Set the media session to the got_accept state. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
255 * |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
256 * @param media The media object to set the state on. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
257 */ |
23787
92e71f6e10d4
Patch from Marcus Lundblad ('mlundblad') to improve audio support in xmpp.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents:
23775
diff
changeset
|
258 void purple_media_got_accept(PurpleMedia *media); |
92e71f6e10d4
Patch from Marcus Lundblad ('mlundblad') to improve audio support in xmpp.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents:
23775
diff
changeset
|
259 |
23865
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
260 /** |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
261 * Enumerates a list of devices. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
262 * |
24935
e8b8c6b14196
Simplified purple_media_get_devices.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24934
diff
changeset
|
263 * @param plugin The name of the GStreamer plugin from which to enumerate devices. |
23865
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
264 * |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
265 * @return The list of enumerated devices. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
266 */ |
24935
e8b8c6b14196
Simplified purple_media_get_devices.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24934
diff
changeset
|
267 GList *purple_media_get_devices(const gchar *plugin); |
23865
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
268 |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
269 /** |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
270 * Gets the device the plugin is currently set to. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
271 * |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
272 * @param element The plugin to retrieve the device from. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
273 * |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
274 * @return The device retrieved. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
275 */ |
23919
4b8c64deac5e
Simplify device API. Use gchar* instead of GValue.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23912
diff
changeset
|
276 gchar *purple_media_element_get_device(GstElement *element); |
23865
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
277 |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
278 /** |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
279 * Creates a default audio source. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
280 * |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
281 * @param sendbin Set to the newly created audio source. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
282 * @param sendlevel Set to the newly created level within the audio source. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
283 */ |
23787
92e71f6e10d4
Patch from Marcus Lundblad ('mlundblad') to improve audio support in xmpp.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents:
23775
diff
changeset
|
284 void purple_media_audio_init_src(GstElement **sendbin, |
92e71f6e10d4
Patch from Marcus Lundblad ('mlundblad') to improve audio support in xmpp.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents:
23775
diff
changeset
|
285 GstElement **sendlevel); |
23865
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
286 |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
287 /** |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
288 * Creates a default video source. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
289 * |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
290 * @param sendbin Set to the newly created video source. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
291 */ |
23787
92e71f6e10d4
Patch from Marcus Lundblad ('mlundblad') to improve audio support in xmpp.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents:
23775
diff
changeset
|
292 void purple_media_video_init_src(GstElement **sendbin); |
92e71f6e10d4
Patch from Marcus Lundblad ('mlundblad') to improve audio support in xmpp.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents:
23775
diff
changeset
|
293 |
23865
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
294 /** |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
295 * Creates a default audio sink. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
296 * |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
297 * @param recvbin Set to the newly created audio sink. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
298 * @param recvlevel Set to the newly created level within the audio sink. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
299 */ |
23787
92e71f6e10d4
Patch from Marcus Lundblad ('mlundblad') to improve audio support in xmpp.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents:
23775
diff
changeset
|
300 void purple_media_audio_init_recv(GstElement **recvbin, GstElement **recvlevel); |
23865
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
301 |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
302 /** |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
303 * Creates a default video sink. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
304 * |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
305 * @param sendbin Set to the newly created video sink. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
306 */ |
23821
12a16471f94e
Refactored PurpleMedia to make creating audio or video sessions virtually identical. Audio, video, and audio/video sessions now work. Also added videotestsrc to the video plugin preference.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23804
diff
changeset
|
307 void purple_media_video_init_recv(GstElement **sendbin); |
23787
92e71f6e10d4
Patch from Marcus Lundblad ('mlundblad') to improve audio support in xmpp.
Sadrul Habib Chowdhury <imadil@gmail.com>
parents:
23775
diff
changeset
|
308 |
23865
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
309 /** |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
310 * Adds a stream to a session. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
311 * |
24934
3b4b9795f987
purple_media_add_stream should only add a stream to one session.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24933
diff
changeset
|
312 * It only adds a stream to one audio session or video session as |
3b4b9795f987
purple_media_add_stream should only add a stream to one session.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24933
diff
changeset
|
313 * the @c sess_id must be unique between sessions. |
3b4b9795f987
purple_media_add_stream should only add a stream to one session.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24933
diff
changeset
|
314 * |
23865
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
315 * @param media The media object to find the session in. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
316 * @param sess_id The session id of the session to add the stream to. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
317 * @param who The name of the remote user to add the stream for. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
318 * @param type The type of stream to create. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
319 * @param transmitter The transmitter to use for the stream. |
24934
3b4b9795f987
purple_media_add_stream should only add a stream to one session.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24933
diff
changeset
|
320 * @param num_params The number of parameters to pass to Farsight. |
3b4b9795f987
purple_media_add_stream should only add a stream to one session.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24933
diff
changeset
|
321 * @param params The parameters to pass to Farsight. |
23865
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
322 * |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
323 * @return @c TRUE The stream was added successfully, @c FALSE otherwise. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
324 */ |
23821
12a16471f94e
Refactored PurpleMedia to make creating audio or video sessions virtually identical. Audio, video, and audio/video sessions now work. Also added videotestsrc to the video plugin preference.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23804
diff
changeset
|
325 gboolean purple_media_add_stream(PurpleMedia *media, const gchar *sess_id, const gchar *who, |
24933
6ab96d5d8ac6
Add params to purple_media_add_stream to allow for different libNice
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24931
diff
changeset
|
326 PurpleMediaSessionType type, const gchar *transmitter, |
6ab96d5d8ac6
Add params to purple_media_add_stream to allow for different libNice
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24931
diff
changeset
|
327 guint num_params, GParameter *params); |
23865
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
328 |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
329 /** |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
330 * Removes a stream from a session. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
331 * |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
332 * @param media The media object to find the session in. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
333 * @param sess_id The session id of the session to remove the stream from. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
334 * @param who The name of the remote user to remove the stream from. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
335 */ |
23821
12a16471f94e
Refactored PurpleMedia to make creating audio or video sessions virtually identical. Audio, video, and audio/video sessions now work. Also added videotestsrc to the video plugin preference.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23804
diff
changeset
|
336 void purple_media_remove_stream(PurpleMedia *media, const gchar *sess_id, const gchar *who); |
12a16471f94e
Refactored PurpleMedia to make creating audio or video sessions virtually identical. Audio, video, and audio/video sessions now work. Also added videotestsrc to the video plugin preference.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23804
diff
changeset
|
337 |
23865
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
338 /** |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
339 * Gets the session type from a session |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
340 * |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
341 * @param media The media object to find the session in. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
342 * @param sess_id The session id of the session to get the type from. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
343 * |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
344 * @return The retreived session type. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
345 */ |
23869
551a462b346a
Changed PurpleMediaStreamType to PurpleMediaSessionType.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23865
diff
changeset
|
346 PurpleMediaSessionType purple_media_get_session_type(PurpleMedia *media, const gchar *sess_id); |
23797
e1c8ec1259de
Updates voice and video to use Farsight 2, gets XMPP voice conferences
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23793
diff
changeset
|
347 |
23865
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
348 /** |
24960
a5f1804fcb4b
Combine get_*_codecs functions to mirror Farsight 2.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24938
diff
changeset
|
349 * Gets the codecs from a session. |
23865
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
350 * |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
351 * @param media The media object to find the session in. |
24960
a5f1804fcb4b
Combine get_*_codecs functions to mirror Farsight 2.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24938
diff
changeset
|
352 * @param sess_id The session id of the session to get the codecs from. |
23865
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
353 * |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
354 * @return The retreieved codecs. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
355 */ |
24960
a5f1804fcb4b
Combine get_*_codecs functions to mirror Farsight 2.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24938
diff
changeset
|
356 GList *purple_media_get_codecs(PurpleMedia *media, const gchar *sess_id); |
23865
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
357 |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
358 /** |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
359 * Adds remote candidates to the stream. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
360 * |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
361 * @param media The media object to find the session in. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
362 * @param sess_id The session id of the session find the stream in. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
363 * @param name The name of the remote user to add the candidates for. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
364 * @param remote_candidates The remote candidates to add. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
365 */ |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
366 void purple_media_add_remote_candidates(PurpleMedia *media, |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
367 const gchar *sess_id, |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
368 const gchar *name, |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
369 GList *remote_candidates); |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
370 |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
371 /** |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
372 * Gets the local candidates from a stream. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
373 * |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
374 * @param media The media object to find the session in. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
375 * @param sess_id The session id of the session to find the stream in. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
376 * @param name The name of the remote user to get the candidates from. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
377 */ |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
378 GList *purple_media_get_local_candidates(PurpleMedia *media, |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
379 const gchar *sess_id, |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
380 const gchar *name); |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
381 |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
382 /** |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
383 * Gets the active local candidate for the stream. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
384 * |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
385 * @param media The media object to find the session in. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
386 * @param sess_id The session id of the session to find the stream in. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
387 * @param name The name of the remote user to get the active candidate from. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
388 * |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
389 * @return The active candidate retrieved. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
390 */ |
23821
12a16471f94e
Refactored PurpleMedia to make creating audio or video sessions virtually identical. Audio, video, and audio/video sessions now work. Also added videotestsrc to the video plugin preference.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23804
diff
changeset
|
391 FsCandidate *purple_media_get_local_candidate(PurpleMedia *media, const gchar *sess_id, const gchar *name); |
23865
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
392 |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
393 /** |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
394 * Gets the active remote candidate for the stream. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
395 * |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
396 * @param media The media object to find the session in. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
397 * @param sess_id The session id of the session to find the stream in. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
398 * @param name The name of the remote user to get the remote candidate from. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
399 * |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
400 * @return The remote candidate retrieved. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
401 */ |
23821
12a16471f94e
Refactored PurpleMedia to make creating audio or video sessions virtually identical. Audio, video, and audio/video sessions now work. Also added videotestsrc to the video plugin preference.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23804
diff
changeset
|
402 FsCandidate *purple_media_get_remote_candidate(PurpleMedia *media, const gchar *sess_id, const gchar *name); |
23865
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
403 |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
404 /** |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
405 * Gets remote candidates from the stream. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
406 * |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
407 * @param media The media object to find the session in. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
408 * @param sess_id The session id of the session find the stream in. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
409 * @param name The name of the remote user to get the candidates from. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
410 * |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
411 * @return @c TRUE The codecs were set successfully, or @c FALSE otherwise. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
412 */ |
23845
13936e4405b7
Added better Farsight error handling.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23837
diff
changeset
|
413 gboolean purple_media_set_remote_codecs(PurpleMedia *media, const gchar *sess_id, |
13936e4405b7
Added better Farsight error handling.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23837
diff
changeset
|
414 const gchar *name, GList *codecs); |
23797
e1c8ec1259de
Updates voice and video to use Farsight 2, gets XMPP voice conferences
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23793
diff
changeset
|
415 |
23865
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
416 /** |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
417 * Returns whether or not the candidates for a remote user are prepared |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
418 * |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
419 * @param media The media object to find the remote user in. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
420 * @param name The remote user to check for. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
421 * |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
422 * @return @c TRUE All streams for the remote user have candidates prepared, @c FALSE otherwise. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
423 */ |
23830
b5a00ddb7077
Jingle sessions now keep track of their transaction state to a degree.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23824
diff
changeset
|
424 gboolean purple_media_candidates_prepared(PurpleMedia *media, const gchar *name); |
b5a00ddb7077
Jingle sessions now keep track of their transaction state to a degree.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23824
diff
changeset
|
425 |
23865
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
426 /** |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
427 * Sets the send codec for the a session. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
428 * |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
429 * @param media The media object to find the session in. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
430 * @param sess_id The session id of the session to set the codec for. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
431 * @param codec The codec to set the session to stream. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
432 * |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
433 * @return @c TRUE The codec was successfully changed, or @c FALSE otherwise. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
434 */ |
23862
3ffe166a355e
Set the proper send codec in Farsight.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23859
diff
changeset
|
435 gboolean purple_media_set_send_codec(PurpleMedia *media, const gchar *sess_id, FsCodec *codec); |
3ffe166a355e
Set the proper send codec in Farsight.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23859
diff
changeset
|
436 |
23865
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
437 /** |
24937
5a774d0817d8
Wait for Farsight 2's codecs-ready property to be TRUE before using codecs.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24935
diff
changeset
|
438 * Gets whether a session's codecs are ready to be used. |
5a774d0817d8
Wait for Farsight 2's codecs-ready property to be TRUE before using codecs.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24935
diff
changeset
|
439 * |
5a774d0817d8
Wait for Farsight 2's codecs-ready property to be TRUE before using codecs.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24935
diff
changeset
|
440 * @param media The media object to find the session in. |
5a774d0817d8
Wait for Farsight 2's codecs-ready property to be TRUE before using codecs.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24935
diff
changeset
|
441 * @param sess_id The session id of the session to check. |
5a774d0817d8
Wait for Farsight 2's codecs-ready property to be TRUE before using codecs.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24935
diff
changeset
|
442 * |
5a774d0817d8
Wait for Farsight 2's codecs-ready property to be TRUE before using codecs.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24935
diff
changeset
|
443 * @return @c TRUE The codecs are ready, or @c FALSE otherwise. |
5a774d0817d8
Wait for Farsight 2's codecs-ready property to be TRUE before using codecs.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24935
diff
changeset
|
444 */ |
5a774d0817d8
Wait for Farsight 2's codecs-ready property to be TRUE before using codecs.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24935
diff
changeset
|
445 gboolean purple_media_codecs_ready(PurpleMedia *media, const gchar *sess_id); |
5a774d0817d8
Wait for Farsight 2's codecs-ready property to be TRUE before using codecs.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24935
diff
changeset
|
446 |
5a774d0817d8
Wait for Farsight 2's codecs-ready property to be TRUE before using codecs.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24935
diff
changeset
|
447 /** |
23865
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
448 * Mutes or unmutes all the audio local audio sources. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
449 * |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
450 * @param media The media object to mute or unmute |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
451 * @param active @c TRUE to mutes all of the local audio sources, or @c FALSE to unmute. |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
452 */ |
23863
4eae2d40f11b
Added a mute button for the local microphone.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23862
diff
changeset
|
453 void purple_media_mute(PurpleMedia *media, gboolean active); |
4eae2d40f11b
Added a mute button for the local microphone.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23862
diff
changeset
|
454 |
24971
1ce297c8923b
Added media functions to set input and output volume.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24962
diff
changeset
|
455 /** |
1ce297c8923b
Added media functions to set input and output volume.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24962
diff
changeset
|
456 * Sets the input volume of all the selected sessions. |
1ce297c8923b
Added media functions to set input and output volume.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24962
diff
changeset
|
457 * |
1ce297c8923b
Added media functions to set input and output volume.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24962
diff
changeset
|
458 * @param media The media object the sessions are in. |
1ce297c8923b
Added media functions to set input and output volume.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24962
diff
changeset
|
459 * @param session_id The session to select (if any). |
1ce297c8923b
Added media functions to set input and output volume.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24962
diff
changeset
|
460 * @param level The level to set the volume to. |
1ce297c8923b
Added media functions to set input and output volume.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24962
diff
changeset
|
461 */ |
1ce297c8923b
Added media functions to set input and output volume.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24962
diff
changeset
|
462 void purple_media_set_input_volume(PurpleMedia *media, const gchar *session_id, double level); |
1ce297c8923b
Added media functions to set input and output volume.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24962
diff
changeset
|
463 |
1ce297c8923b
Added media functions to set input and output volume.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24962
diff
changeset
|
464 /** |
1ce297c8923b
Added media functions to set input and output volume.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24962
diff
changeset
|
465 * Sets the output volume of all the selected streams. |
1ce297c8923b
Added media functions to set input and output volume.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24962
diff
changeset
|
466 * |
1ce297c8923b
Added media functions to set input and output volume.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24962
diff
changeset
|
467 * @param media The media object the streams are in. |
1ce297c8923b
Added media functions to set input and output volume.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24962
diff
changeset
|
468 * @param session_id The session to limit the streams to (if any). |
1ce297c8923b
Added media functions to set input and output volume.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24962
diff
changeset
|
469 * @param participant The participant to limit the streams to (if any). |
1ce297c8923b
Added media functions to set input and output volume.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24962
diff
changeset
|
470 * @param level The level to set the volume to. |
1ce297c8923b
Added media functions to set input and output volume.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24962
diff
changeset
|
471 */ |
1ce297c8923b
Added media functions to set input and output volume.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24962
diff
changeset
|
472 void purple_media_set_output_volume(PurpleMedia *media, const gchar *session_id, |
1ce297c8923b
Added media functions to set input and output volume.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24962
diff
changeset
|
473 const gchar *participant, double level); |
1ce297c8923b
Added media functions to set input and output volume.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
24962
diff
changeset
|
474 |
23865
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
475 #ifdef __cplusplus |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
476 } |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
477 #endif |
b8a73b6dc0a4
* Added documentation to media.h and mediamanager.h
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23863
diff
changeset
|
478 |
23760 | 479 G_END_DECLS |
480 | |
23804
cbe97caec684
Use USE_VV instead of USE_FARSIGHT.
Mike Ruprecht <maiku@soc.pidgin.im>
parents:
23801
diff
changeset
|
481 #endif /* USE_VV */ |
23760 | 482 |
483 | |
484 #endif /* __MEDIA_H_ */ |