[telepathy-ashes/master] Make all streams bidirectional ASAP.

David Laban david.laban at collabora.co.uk
Wed Oct 7 04:40:02 PDT 2009


Fixes the issue where you couldn't upgrade a call to add video.
---
 ashes/tools/media_echoer.py |    6 +++++-
 1 files changed, 5 insertions(+), 1 deletions(-)

diff --git a/ashes/tools/media_echoer.py b/ashes/tools/media_echoer.py
index 493038b..2187e0c 100644
--- a/ashes/tools/media_echoer.py
+++ b/ashes/tools/media_echoer.py
@@ -61,11 +61,12 @@ class MediaChannelEchoer(ContactAcceptor):
         """
         Connects up incoming media to the outgoing media pad.
         """
-        print green("Accepting, (and throwing away) incoming audio/video.")
         type = stream.get_property ("media-type")
         if type == farsight.MEDIA_TYPE_AUDIO:
+            print green("Accepting, (and reflecting) incoming audio.")
             pipe = gst.parse_bin_from_description("identity", True)
         elif type == farsight.MEDIA_TYPE_VIDEO:
+            print green("Accepting, (and reflecting) incoming video.")
             pipe = gst.parse_bin_from_description("identity", True)
 
         sinkpad = stream.get_property("sink-pad")
@@ -83,6 +84,9 @@ class MediaChannelEchoer(ContactAcceptor):
         stream.connect("src-pad-added", self.src_pad_added)
         print green('Waiting for incoming audio/video.')
 
+        id = stream.get_property("stream-id")
+        self.dbus_object[self.channel_type].RequestStreamDirection(id, 3)
+
     def session_created(self, channel, conference, participant):
         """
         """
-- 
1.5.6.5




More information about the telepathy-commits mailing list