Java 类org.webrtc.SdpObserver 实例源码

项目:licodeAndroidClient    文件:StreamDescription.java   
public void initLocal(PeerConnection pc, SdpObserver sdpObserver) {
    mLocal = true;
    mState = StreamState.LOCAL;
    this.pc = pc;
    mSdpConstraints = new MediaConstraints();
    mSdpConstraints.mandatory.add(new MediaConstraints.KeyValuePair(
            "OfferToReceiveAudio", "true"));
    mSdpConstraints.mandatory.add(new MediaConstraints.KeyValuePair(
            "OfferToReceiveVideo", "true"));
    pc.createOffer(sdpObserver, mSdpConstraints);
}
项目:licodeAndroidClient    文件:StreamDescription.java   
public void initRemote(PeerConnection pc, SdpObserver sdpObserver) {
    mLocal = false;
    mState = StreamState.OPENING;
    this.pc = pc;
    mSdpConstraints = new MediaConstraints();
    mSdpConstraints.mandatory.add(new MediaConstraints.KeyValuePair(
            "OfferToReceiveAudio", "true"));
    mSdpConstraints.mandatory.add(new MediaConstraints.KeyValuePair(
            "OfferToReceiveVideo", "true"));
    pc.createOffer(sdpObserver, mSdpConstraints);
}