TPEPlatform/MediaRecorder

Summary

We already have mozCamera for take photo or video recording. mozCamera itself is not part of any standard web spec, which means

  1. It works on Firefox platform only.
  2. Totally isolate in media world. There is no way to connect data stream from mozCamera with media processing module, such as WebAudio, or recording module, such as MediaRecorder.

MediaRecorder takes media stream, which may come from web audio or media source or user media, as input. User may process all these media streams before recording. In mozCamera, there is nothing that user can do between capturerer and recorder, except canned video effect.

Regarding to architecture of Encoding framework, please visit "MediaEncoder Framework".

Track Encoder Milestone

The following table reveals encode and associate container format we are going to support:

Type Encoder Detailed Container
Audio Opus mono/ stereo Ogg
Vobis mono/ stereo Ogg
AAC mono/ stereo/ 5.0/ 5.1 MPEG-4
PCM 16 bit LPCM Wave
Video H.264 Baseline Profile MPEG-4
VP8 WebM

List pros and cons for each audio/ video codec. We need more clear view to prioritize codec support sequence.

Requirements for a video codec, which is the way to we prioritize encoder support:

  1. Image quality
  2. Performance
  3. Power consumption
  4. Hardware support
  5. Licensing

META Issues

META bugs for Encoding framework:

Bug No Description
bug 803414 WebAPI: Implementation MediaRecorder API
bug 879688 Framework: Implement MediaEncoder
bug 842243 Framework: Implement Audio encoding path
bug 879669 Framework: Implement Video encoding path
bug 888177 WebAPI: Implement ImageCapture API

Testing Plan

  1. Jason Smith: https://etherpad.mozilla.org/media-recording-testing
Bug No Description Statue Target Assigned
bug 889772 Audio Recording - Marionette Test Case Open Gecko 25 Randy Lin
TBD Video Recording - Marionette Test Case Open Gecko 26 Randy Lin

Codec/ Container support

Schedule is not well define yet. All the information list bellow is not confirmed.

B2G

Type Milestone Target Issue Assignee
Audio Opus/ OGG Gecko 24 bug 842243 Shelly
LPCM/ Wav TBD
MP3 Not defined bug 884162
Video H.264/ AAC/ MP4 Gecko 28 bug 879668
VP8/ Vobis/ WebM Gecko 27 bug 881840
VP9/ Opus/ WebM ??/?? TBD

Android

Milestone Target Issue Assignee
Opus/ OGG 6/14 bug 842243 Shelly

Linux

Milestone Target Issue Assignee
Opus/ OGG 6/14 bug 842243 Shelly

Windows

Milestone Target Date Issue No Assignee
Opus/ OGG 6/14 bug 842243 Shelly

MacOS

Milestone Target Date Issue No Assignee
Opus/ OGG 6/14 bug 842243 Shelly

Reference