- From: Randy Lin <rlin@mozilla.com>
- Date: Wed, 4 Dec 2013 17:56:50 -0800 (PST)
- To: Jim Barnett <Jim.Barnett@genesyslab.com>
- Cc: public-media-capture@w3.org
Hi Jim, About the start method "Set state to 'recording' and wait until media becomes available from stream." The stream available waiting time may not be estimated and it is possible that application want to cancel the recording operation during that time. Does the stop method should in waiting queue until the start tasks finished? That means stop method can be executed after onstart event fired. ------------------------------------- -rlin ----- Original Message ----- From: "Jim Barnett" <Jim.Barnett@genesyslab.com> To: "Randy Lin" <rlin@mozilla.com>, public-media-capture@w3.org Sent: Thursday, December 5, 2013 12:33:36 AM Subject: RE: Expect behavior of calling stop before receiving the onstart event on MediaRecorder API? Randy, I'm not sure why the UA would call stop(). I would expect the application to do it. But in any case, the behavior should be as follows: both start() and stop() queue tasks, so the stop() method's task will not be executed before the start task completes. One of the first things that the start task does is to set the state to 'recording'. At the time the stop task executes, it is true that the start event may not have been processed, but the state will be 'recording' and the stop task will execute and fire the dataavailable and stop events. The only time that the stop task would raise an error would be if the recorder was in the wrong state. - Jim -----Original Message----- From: Randy Lin [mailto:rlin@mozilla.com] Sent: Wednesday, December 04, 2013 3:26 AM To: public-media-capture@w3.org Subject: Expect behavior of calling stop before receiving the onstart event on MediaRecorder API? Hi all, Refer this API document. https://dvcs.w3.org/hg/dap/raw-file/tip/media-stream-capture/MediaRecorder.html What's the expect behavior if UA try to call the stop method before receiving the onstart event on MediaRecorder API. Should we queue this stop() task after onstart event or throw exception on stop method invoked or cancel the recording task and fire the events which stop() method required? ------------------------------------- -rlin
Received on Thursday, 5 December 2013 01:57:17 UTC