DescriptionHTMLMediaElement capture: teach the captured MStream to follow up source events
wip
This CL adds support for the MediaStream created by calling
captureStream() on a <video/audio> to follow the events of the
source <video/audio>, namely:
- if the source tag ends, the captured MediaStreamTracks are
ended and the captured MediaStream is ended (which wasn't
the case before).
- if the source tag hits an onloadedmetadata, MediaStreamTracks
are added to the captured MediaStream as fit.
-- this also allows for a MediaStream-with-no-tracks to be created
out of a source tag with no content.
Added/beefed up LayoutTests for this.
MediaStream::{add,remove}RemoteTrack are renamed to
{add,remove}TrackByComponent. The reason for the original
name is that only internal add/removal of tracks should fire
an on{add/remove}track [1], and until this CL this was only
possible for remote tracks.
[1] https://developer.mozilla.org/en-US/docs/Web/Events/addtrack
BUG=698514
CQ_INCLUDE_TRYBOTS=master.tryserver.blink:linux_trusty_blink_rel
Review-Url: https://codereview.chromium.org/2727583007
Cr-Commit-Position: refs/heads/master@{#454964}
Committed: https://chromium.googlesource.com/chromium/src/+/d80e6732a30c9f8b5c725fc98b013577799022cd
Patch Set 1 #Patch Set 2 : Connected on{add/remove}track events, moar LayoutTests #
Total comments: 3
Patch Set 3 : Made the media element and the MediaStream Members of MediaElementEventListener #
Total comments: 8
Patch Set 4 : haraken@ comments #Messages
Total messages: 41 (29 generated)
|