diff options
author | Sebastien Vincent <seb@jitsi.org> | 2010-10-04 06:42:47 +0000 |
---|---|---|
committer | Sebastien Vincent <seb@jitsi.org> | 2010-10-04 06:42:47 +0000 |
commit | 9c74aed085db4e9daac24cc90cfd268fa1bd88be (patch) | |
tree | 17a78ff11d282c034b74ca30f2beb88b5567f197 /src/net/java/sip/communicator/impl | |
parent | e03fd00b5737905ed3b17918105b2d9255a1bc59 (diff) | |
download | jitsi-9c74aed085db4e9daac24cc90cfd268fa1bd88be.zip jitsi-9c74aed085db4e9daac24cc90cfd268fa1bd88be.tar.gz jitsi-9c74aed085db4e9daac24cc90cfd268fa1bd88be.tar.bz2 |
Create video calls with a MediaDevice in OperationSetDesktopSharingServer.
Diffstat (limited to 'src/net/java/sip/communicator/impl')
2 files changed, 12 insertions, 9 deletions
diff --git a/src/net/java/sip/communicator/impl/protocol/jabber/OperationSetDesktopSharingServerJabberImpl.java b/src/net/java/sip/communicator/impl/protocol/jabber/OperationSetDesktopSharingServerJabberImpl.java index 488c24e..ce9af86 100644 --- a/src/net/java/sip/communicator/impl/protocol/jabber/OperationSetDesktopSharingServerJabberImpl.java +++ b/src/net/java/sip/communicator/impl/protocol/jabber/OperationSetDesktopSharingServerJabberImpl.java @@ -8,6 +8,7 @@ package net.java.sip.communicator.impl.protocol.jabber; import java.util.*; import java.util.List; // disambiguation +import java.text.*; import java.awt.*; import java.awt.event.*; @@ -132,9 +133,9 @@ public class OperationSetDesktopSharingServerJabberImpl */ @Override public Call createVideoCall(String uri, MediaDevice device) - throws OperationFailedException + throws OperationFailedException, ParseException { - CallJabberImpl call = (CallJabberImpl)super.createVideoCall(uri); + CallJabberImpl call = (CallJabberImpl)super.createVideoCall(uri, device); CallPeerJabberImpl callPeer = call.getCallPeers().next(); callPeer.addCallPeerListener(callPeerListener); @@ -161,7 +162,7 @@ public class OperationSetDesktopSharingServerJabberImpl public Call createVideoCall(Contact callee, MediaDevice device) throws OperationFailedException { - CallJabberImpl call = (CallJabberImpl)super.createVideoCall(callee); + CallJabberImpl call = (CallJabberImpl)super.createVideoCall(callee, device); CallPeerJabberImpl callPeer = call.getCallPeers().next(); callPeer.addCallPeerListener(callPeerListener); diff --git a/src/net/java/sip/communicator/impl/protocol/sip/OperationSetDesktopSharingServerSipImpl.java b/src/net/java/sip/communicator/impl/protocol/sip/OperationSetDesktopSharingServerSipImpl.java index 6df66b8..6389f4c 100644 --- a/src/net/java/sip/communicator/impl/protocol/sip/OperationSetDesktopSharingServerSipImpl.java +++ b/src/net/java/sip/communicator/impl/protocol/sip/OperationSetDesktopSharingServerSipImpl.java @@ -24,6 +24,7 @@ import org.xml.sax.*; import net.java.sip.communicator.service.neomedia.MediaType; // disambiguation import net.java.sip.communicator.service.neomedia.format.*; +import net.java.sip.communicator.service.neomedia.device.*; import net.java.sip.communicator.service.protocol.*; import net.java.sip.communicator.service.hid.*; import net.java.sip.communicator.service.protocol.event.*; @@ -153,6 +154,7 @@ public class OperationSetDesktopSharingServerSipImpl * * @param uri the address of the callee that we should invite to a new * call. + * @param device <tt>MediaDevice</tt> to use for this call * @return CallPeer the CallPeer that will represented by the * specified uri. All following state change events will be delivered * through that call peer. The Call that this peer is a member @@ -164,15 +166,14 @@ public class OperationSetDesktopSharingServerSipImpl * string. */ @Override - public Call createVideoCall(String uri) + public Call createVideoCall(String uri, MediaDevice device) throws OperationFailedException, ParseException { - CallSipImpl call = (CallSipImpl)super.createVideoCall(uri); + CallSipImpl call = (CallSipImpl)super.createVideoCall(uri, device); CallPeerSipImpl callPeer = call.getCallPeers().next(); callPeer.addMethodProcessorListener(this); callPeer.addCallPeerListener(callPeerListener); - /* TODO change to MediaType.DESKTOP */ size = (((VideoMediaFormat)call.getDefaultDevice(MediaType.VIDEO). getFormat()).getSize()); return call; @@ -183,6 +184,7 @@ public class OperationSetDesktopSharingServerSipImpl * * @param callee the address of the callee that we should invite to a new * call. + * @param device <tt>MediaDevice</tt> to use for this call * @return CallPeer the CallPeer that will represented by the * specified uri. All following state change events will be delivered * through that call peer. The Call that this peer is a member @@ -192,14 +194,14 @@ public class OperationSetDesktopSharingServerSipImpl * to create the video call. */ @Override - public Call createVideoCall(Contact callee) throws OperationFailedException + public Call createVideoCall(Contact callee, MediaDevice device) + throws OperationFailedException { - CallSipImpl call = (CallSipImpl)super.createVideoCall(callee); + CallSipImpl call = (CallSipImpl)super.createVideoCall(callee, device); CallPeerSipImpl callPeer = call.getCallPeers().next(); callPeer.addMethodProcessorListener(this); callPeer.addCallPeerListener(callPeerListener); - /* TODO change to MediaType.DESKTOP */ size = (((VideoMediaFormat)call.getDefaultDevice(MediaType.VIDEO). getFormat()).getSize()); return call; |