...
Code Block | ||||
---|---|---|---|---|
| ||||
function playParticipantsStream(participant) { participant.getStreams()[0].play(display).on(STREAM_STATUS.PLAYING, function if (participant.playplayingStream) { $("[id$=Name]").each(function (index, valuedocument.getElementById(playingStream.id()).addEventListener('resize', function (event) { if ($(value).text() == participant.name()) { var p = value.id.replace('Name', ''); var pDisplay = p + 'Display'; participant.play(document.getElementById(pDisplay)).on(STREAM_STATUS.PLAYING, function (playingStream) { resizeVideo(event.target); }); if (button) { document.getElementById(playingStream.id()).addEventListener('resize', function (event) $(button).text("Stop").off('click').click(function(){ $(this).prop('disabled', true); resizeVideo(event.target); playingStream.stop(); }).prop('disabled', false); } }).on(STREAM_STATUS.STOPPED, function });() { onParticipantStopped(participant); }).on(STREAM_STATUS.FAILED, function () { }onParticipantStopped(participant); } }); |
12. Stop of streaming.
stream.stop() code
...