Skip to content

Commit 6d89746

Browse files
committed
The spec text was unclear. From offline discussion with the original spec author it's believed that the intent of the spec language was meant to convey that the first produced timecode would contain an absolute timestamp. However, it's not clear what usecase is unlocked by that, as the user can construct their own absolute timestamp with performance.now() on event reception. This ignores the fact that the event handler can execute delayed, but since it's not clear what problem this fixes, this PR simply makes the timestamp sequence start with zero instead. Fixes #222.
1 parent 48e2abf commit 6d89746

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

MediaRecorder.bs

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -680,10 +680,11 @@ enum RecordingState {
680680
encoding of the blob data.
681681

682682
<dt><dfn attribute for="BlobEvent"><code>timecode</code></dfn></dt>
683-
<dd>The difference between the timestamp of the first chunk in
684-
{{BlobEvent/data}} and the timestamp of the first chunk in the first
685-
{{BlobEvent}} produced by this recorder as a {{DOMHighResTimeStamp}} [[!HR-TIME]]. Note that the {{BlobEvent/timecode}}
686-
in the first produced {{BlobEvent}} does not need to be zero.
683+
<dd>For a MediaRecorder instance, the {{BlobEvent/timecode}} in the first
684+
produced {{BlobEvent}} contains 0. Subsequent {{BlobEvent}}'s
685+
{{BlobEvent/timecode}} contain the difference of the timestamp of creation of
686+
the first chunk in said {{BlobEvent}} and the timestamp of the first chunk of the
687+
first produced {{BlobEvent}}, as {{DOMHighResTimeStamp}} [[!HR-TIME]].
687688
</dd>
688689

689690
</dl>

0 commit comments

Comments
 (0)