[whatwg] need a way to set output format from StreamRecorder
per-erik.brodin at ericsson.com
Fri Nov 19 10:50:42 PST 2010
We are about to start implementing stream.record() and StreamRecorder.
The spec currently says that “the file must be in a format supported by
the user agent for use in audio and video elements” which is a
reasonable restriction. However, there is currently no way to set the
output format of the resulting File that you get from recorder.stop().
It is unlikely that specifying a default format would be sufficient if
you in addition to container formats and codecs consider resolution,
color depth, frame rate etc. for video and sample size and rate, number
of channels etc. for audio.
Perhaps an argument should be added to record() that specifies the
output format from StreamRecorder as a MIME type with parameters? Since
record() should probably throw when an unsupported type is supplied, it
would perhaps be useful to have a canRecordType() or similar to be able
to test for supported formats.
More information about the whatwg