[farsight2/master] Make the fs_stream_emit_src_pad_added a function of the library
Olivier Crête
olivier.crete at collabora.co.uk
Tue Dec 23 15:20:57 PST 2008
---
docs/libs/farsight-libs-sections.txt | 1 +
gst-libs/gst/farsight/fs-stream.c | 21 ++++++++++++++++++++-
gst-libs/gst/farsight/fs-stream.h | 4 ++++
gst/fsrtpconference/fs-rtp-stream.c | 8 --------
gst/fsrtpconference/fs-rtp-stream.h | 4 ----
gst/fsrtpconference/fs-rtp-substream.c | 2 +-
6 files changed, 26 insertions(+), 14 deletions(-)
diff --git a/docs/libs/farsight-libs-sections.txt b/docs/libs/farsight-libs-sections.txt
index b0473ab..f158aa7 100644
--- a/docs/libs/farsight-libs-sections.txt
+++ b/docs/libs/farsight-libs-sections.txt
@@ -27,6 +27,7 @@ fs_stream_select_candidate_pair
fs_stream_preload_recv_codec
fs_stream_set_remote_codecs
fs_stream_emit_error
+fs_stream_emit_src_pad_added
<SUBSECTION Standard>
FS_STREAM
FS_IS_STREAM
diff --git a/gst-libs/gst/farsight/fs-stream.c b/gst-libs/gst/farsight/fs-stream.c
index d77e627..e7b6dc6 100644
--- a/gst-libs/gst/farsight/fs-stream.c
+++ b/gst-libs/gst/farsight/fs-stream.c
@@ -521,7 +521,7 @@ fs_stream_set_remote_codecs (FsStream *stream,
* @error_msg: Error message to be displayed to user
* @debug_msg: Debugging error message
*
- * This function emit the "error" signal on a #FsStream, it should only be
+ * This function emits the #FsStream::error" signal, it should only be
* called by subclasses.
*/
void
@@ -530,3 +530,22 @@ fs_stream_emit_error (FsStream *stream, gint error_no,
{
g_signal_emit (stream, signals[ERROR], 0, error_no, error_msg, debug_msg);
}
+
+
+/**
+ * fs_stream_emit_src_pad_added:
+ * @stream: #FsStream on which to emit the src-pad-added signal
+ * @pad: the #GstPad that this #FsStream has created
+ * @codec: The #FsCodec for this pad
+ *
+ * This functin emits the #FsStream::src-pad-added" signal, it should only be
+ * called by subclasses.
+ */
+
+void
+fs_stream_emit_src_pad_added (FsStream *stream,
+ GstPad *pad,
+ FsCodec *codec)
+{
+ g_signal_emit (stream, signals[SRC_PAD_ADDED], 0, pad, codec);
+}
diff --git a/gst-libs/gst/farsight/fs-stream.h b/gst-libs/gst/farsight/fs-stream.h
index b39d3a1..31820a6 100644
--- a/gst-libs/gst/farsight/fs-stream.h
+++ b/gst-libs/gst/farsight/fs-stream.h
@@ -144,6 +144,10 @@ gboolean fs_stream_set_remote_codecs (FsStream *stream,
void fs_stream_emit_error (FsStream *stream, gint error_no,
gchar *error_msg, gchar *debug_msg);
+void fs_stream_emit_src_pad_added (FsStream *stream,
+ GstPad *ghostpad,
+ FsCodec *codec);
+
G_END_DECLS
#endif /* __FS_STREAM_H__ */
diff --git a/gst/fsrtpconference/fs-rtp-stream.c b/gst/fsrtpconference/fs-rtp-stream.c
index b675211..fb74478 100644
--- a/gst/fsrtpconference/fs-rtp-stream.c
+++ b/gst/fsrtpconference/fs-rtp-stream.c
@@ -614,14 +614,6 @@ _transmitter_error (
fs_stream_emit_error (stream, errorno, error_msg, debug_msg);
}
-void
-fs_rtp_stream_src_pad_added (FsRtpStream *stream,
- GstPad *ghostpad,
- FsCodec *codec)
-{
- g_signal_emit_by_name (stream, "src-pad-added", ghostpad, codec);
-}
-
/**
* fs_rtp_stream_add_substream:
diff --git a/gst/fsrtpconference/fs-rtp-stream.h b/gst/fsrtpconference/fs-rtp-stream.h
index 9e0096c..46b6cd5 100644
--- a/gst/fsrtpconference/fs-rtp-stream.h
+++ b/gst/fsrtpconference/fs-rtp-stream.h
@@ -88,10 +88,6 @@ void fs_rtp_stream_invalidate_codec_locked (FsRtpStream *stream,
gint pt,
const FsCodec *codec);
-void fs_rtp_stream_src_pad_added (FsRtpStream *stream,
- GstPad *ghostpad,
- FsCodec *codec);
-
void fs_rtp_stream_maybe_emit_codecs_changed (FsRtpStream *stream,
FsRtpSubStream *substream);
diff --git a/gst/fsrtpconference/fs-rtp-substream.c b/gst/fsrtpconference/fs-rtp-substream.c
index fa20e94..e769fa3 100644
--- a/gst/fsrtpconference/fs-rtp-substream.c
+++ b/gst/fsrtpconference/fs-rtp-substream.c
@@ -748,7 +748,7 @@ fs_rtp_sub_stream_add_output_ghostpad_locked (FsRtpSubStream *substream,
substream->priv->output_ghostpad = ghostpad;
- fs_rtp_stream_src_pad_added (substream->priv->stream,
+ fs_stream_emit_src_pad_added (FS_STREAM (substream->priv->stream),
ghostpad,
substream->priv->codec);
--
1.5.6.5
More information about the farsight-commits
mailing list