Hi,
It looks like the enabled property for MediaStreamTrack was fixed for
M27 release. See issue
https://code.google.com/p/chromium/issues/detail?id=114163.
So in your case you should test with at least M27. Also you if you are
observing issues related to sdp attributes (inactive/sendonly/
recvonly) i would suggest add information to this issue:-
https://code.google.com/p/webrtc/issues/detail?id=1640.
/Vikas
On Apr 19, 6:26 am, Wolfgang Beck <
wolfgang.bec...@googlemail.com>
wrote:
> That's how it is supposed to work. But at least in Chrome 26.0.1410.63.
> it's broken:
> - setting the 'enable' flag of the localStream's tracks to 'false' has no
> effect at all. Just tested
> pc.getLocalStreams()[0].getAudioTracks()[0].enabled = false
> pc.getLocalStreams()[0].getVideoTracks()[0].enabled = false
> the remote browser still shows the video.
>
> - browserA.pc.localDescription and browserB.pc.remoteDescription both show
> 'a=inactive' (after I made the prescribed setLocalDescription /
> setRemoteDescription call). Still, browserA sends the complete video stream.
> The only way is calling pause() on the receiving video element. But that's
> not useful outside of demos.
>
>
>
>
>
>
>
> On Friday, April 19, 2013 2:32:29 PM UTC+2, Dennis wrote:
>
> > AFAIK this is how webRTC works:
>
> > 1. Muting the video/audio HTML elements themselves only affects local
> > playback. RTP/RTCP/STUN is still transmitted.
> > 2. Setting the video/audio tracks's enabled flag to 'false' still
> > transmits RTP/RTCP/STUN, but it changes the contents of the RTP media
> > streams to 'zeros' for for audio (silence) and black video frames.
> > 3. Changing the local description SDP to 'inactive' halts the RTP
> > media stream completely. STUN & RTCP is still transmitted. but for this
> > to work, you need to do something like:
>
> > var tmp = pc1.localDescription;
> > tmp.sdp = *setInactiveFunc*(tmp.sdp);// where *setInactiveFunc *returns
> > the modified SDP with 'a=inactive'
> > pc1.setLocalDescription(tmp);
> > pc1.setRemoteDescription(pc1.remoteDescription); // completes the
> > offer/answer
>
> > Also, I didn't have any issues cloning media streams. When I cloned a
> > stream, and set the cloned stream's enabled flag to false, "zeros" are
> > transmitted as expected. If the cloned stream's enabled flags are "true"
> > while the parent's stream's enabled flag is "false", the local playout is
> > muted, but the media itself is still transmitted and played out
> > successfully on the receiver.
>
> > For #3, if you're doing more advanced work, when you resume, I think RTP
> > sequence numbers might be reset, but .roll over counters continue since
> > RTCP is still active.
>
> > *One question I have regarding #3* ... from my understanding reading
> > specs the ROC increments every time the sequence number increments past
> > modulo 2^16, e.g. 65535. In this situation for local 'on hold', If the
> > sequence numbers are resetting when you resume, how does the receiver keep
> > track of when the next ROC increment occurs? When a sender sets local
> > description to inactive & does the setLocal and setRemote, do you also need
> > to do this on the receiver's side in order for the ROC to stay in sync?
> > How does ROC work in this situation? My guess would be that if the
> > receiver is not also setting their remote description to inactive, the
> > receiver might know know when the next ROC increment occurs, then ROC might
> > get out of sync and thus eventually fail to decrypt and playout. I haven't
> > toyed around enough to figure this one out yet. Does anyone know the
> > answer to that?
>
> > On Fri, Apr 19, 2013 at 4:32 AM, Iñaki Baz Castillo <
i...@aliax.net<javascript:>
> > > wrote:
>
> >> 2013/4/18 Wolfgang Beck <
wolfgan...@googlemail.com <javascript:>>:
> >> > It's quite a mess.
>
> >> > - The offering browser doesn't care about a=inactive/recvonly
> >> attributes in
> >> > SDP. It still sends RTP
> >> > - The answering browser doesn't care about a=inactive either. It keeps
> >> > sending RTP.
> >> > - Disabling the local stream is fine for mute, but doesn't work for
> >> 'hold'
> >> > as the local stream will be muted for all ongoing calls.
> >> > Cloning the local stream and selectively muting them doesn't work
> >> either.
>
> >> So SDP is chosen as "media information exchange unit" but then there
> >> is no a real API for inspecting an SDP at JS level (i.e. how to know
> >> whether a "m" line has "a=sendonly"?) and there is no API for setting
> >> common SDP attributes (i.e. "a=sendonly", "a=inactive"...). And no
> >> events when a peer receives the same remote SDP but with "a=inactive"
> >> or whatever... and RTP still is sent which is even worse...
>
> >> Not sure if this is a bug in the spec or in the implementation.
> >> Hopefuly all these needs will be addressed.
>
> >> Regards.
>
> >> --
> >> Iñaki Baz Castillo
> >> <
i...@aliax.net <javascript:>>
>
> >> --
>
> >> ---
> >> You received this message because you are subscribed to the Google Groups
> >> "discuss-webrtc" group.
> >> To unsubscribe from this group and stop receiving emails from it, send an
> >> email to
discuss-webrt...@googlegroups.com <javascript:>.