W3C home > Mailing lists > Public > public-webrtc-logs@w3.org > October 2018

[mediacapture-record] Should a dataavailable event be dispatched in case there is no available data

From: youennf via GitHub <sysbot+gh@w3.org>
Date: Thu, 18 Oct 2018 21:18:11 +0000
To: public-webrtc-logs@w3.org
Message-ID: <issues.opened-371717610-1539897490-sysbot+gh@w3.org>
youennf has just created a new issue for https://github.com/w3c/mediacapture-record:

== Should a dataavailable event be dispatched in case there is no available data ==
The current spec seems to mandate that a dataavailable event is sent even though there might be no data.
The current behavior is probably to dispatch such event with a blob whose size is 0.
Implementations might call WebSocket.send or upload empty blobs for no good reason though.
Or they would need to check the size of the blob, in which case having a nullable blob might make more sense.

Would it make sense to do the following:
- Return promises to notify the application that an action (stop/pause/requestData...) is done
- Dispatch dataavailable events only when needed if there is actually some data available


Please view or discuss this issue at https://github.com/w3c/mediacapture-record/issues/153 using your GitHub account
Received on Thursday, 18 October 2018 21:18:43 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 19:22:07 UTC