IceMediaStream stream = iceAgent.getAgent().getStream(name);
MediaFormat format = streamNameToMediaFormats.get(name);
Byte payloadTypeId = streamNameToPayloadTypeId.get(name);
if( stream == null || format == null || payloadTypeId == null )
throw new IOException("Stream \"" + name + "\" not found.");
Component rtpComponent = stream.getComponent(org.ice4j.ice.Component.RTP);
Component rtcpComponent = stream.getComponent(org.ice4j.ice.Component.RTCP);
if( rtpComponent == null )
throw new IOException("RTP component not found.");
if( rtcpComponent == null )
throw new IOException("RTCP Component not found.");
CandidatePair rtpPair = rtpComponent.getSelectedPair();
CandidatePair rtcpPair = rtcpComponent.getSelectedPair();
// System.out.println( "RTP : L " + rtpPair.getLocalCandidate().getDatagramSocket().getLocalPort() + " <-> " + rtpPair.getRemoteCandidate().getTransportAddress() + " R " );
// System.out.println( "RTCP: L " + rtcpPair.getLocalCandidate().getDatagramSocket().getLocalPort() + " <-> " + rtcpPair.getRemoteCandidate().getTransportAddress() + " R " );
return startStream( name,