This is an archived snapshot of W3C's public bugzilla bug tracker, decommissioned in April 2019. Please see the home page for more details.

Bug 22263 - Clarify synchronization of tracks in a MediaStream
Summary: Clarify synchronization of tracks in a MediaStream
Status: RESOLVED FIXED
Alias: None
Product: WebRTC Working Group
Classification: Unclassified
Component: Media Capture and Streams (show other bugs)
Version: unspecified
Hardware: PC Linux
: P2 minor
Target Milestone: ---
Assignee: Adam Bergkvist
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-06-04 15:58 UTC by Dominique Hazael-Massieux
Modified: 2014-05-08 08:03 UTC (History)
4 users (show)

See Also:


Attachments

Description Dominique Hazael-Massieux 2013-06-04 15:58:30 UTC
Currently, the language used to indicate that tracks in a MediaStream needs to be synchronized doesn't not carry much normativeness:
"All tracks in a MediaStream are intended to be synchronized when rendered".

I think there should be a conformance requirement that the user agent MUST keep tracks of a given MediaStream synchronized when rendering them.

This has probably also some impact on MediaStream consumer if we resolve bug #22260
Comment 1 Martin Thomson 2013-06-04 19:54:47 UTC
This is a difficult problem to address with strong normative language.  For local playback, it's a no-brainer, but once the tracks traverse a network it's less clear-cut.

In some cases it's better to let audio/video desync rather than suffer glitches, which tend to be more noticeable.  Furthermore, some tests have indicated that synchronization imposes delays that have a negative affect on user perception.  That is, the delays are worse than a little synchronization drift.

Of course, applications that don't want synchronization could put MediaStreamTracks in separate MediaStreams, but that allows for unconstrained drift.

That leaves me with the conclusion that it should be up to browsers to determine how they want to synchronize tracks.
Comment 2 Stefan Hakansson LK 2013-06-05 09:27:54 UTC
I agree to Martin (and I think "All tracks in a MediaStream are intended to be synchronized when rendered" catches that pretty well).
Comment 3 Dominique Hazael-Massieux 2013-06-05 11:16:17 UTC
OK, fair enough; should this be closed then?
Comment 4 Stefan Hakansson LK 2013-06-05 11:51:04 UTC
(In reply to comment #3)
> OK, fair enough; should this be closed then?

Yes, that's at least my view.
Comment 5 Martin Thomson 2013-06-05 16:32:15 UTC
While the intent of the current text is sufficient, it probably isn't enough information for an implementer to understand all the ramifications of the statement.

We could expect that implementations will do the right thing, but it might be better to expand on that statement rather than just leave it lie.  Dom isn't the only person who is likely to ask the question regarding conformance.

I don't think that this sounds right, but something along these lines might be appropriate:

"While the intent is to synchronize tracks, it could be better in some circumstances to permit tracks to lose synchronization.  In particular, when tracks are remotely sourced and real-time (see WebRTC), it can be better to allow loss of synchronization than to accumulate delays or risk glitches and other artefacts.  Implementations are expected to understand the implications of choices regarding synchronization of playback and the effect that these have on user perception."
Comment 6 Harald Alvestrand 2014-03-19 14:36:59 UTC
I suggest that we take Martin's proposed text and insert it as a "NOTE" in section 4.1 (the only place we mention synchronization).
Comment 7 Stefan Hakansson LK 2014-04-22 08:50:52 UTC
Harald's proposal seem straightforward. Assigning to Adam (to do the actual edit).
Comment 9 Stefan Hakansson LK 2014-05-08 08:03:46 UTC
Fixed in http://dev.w3.org/2011/webrtc/editor/archives/20140507/getusermedia.html