Confirmed users
35
edits
No edit summary |
No edit summary |
||
| Line 46: | Line 46: | ||
== Ongoing Work == | == Ongoing Work == | ||
== Audio Performance Framework | == Audio Performance Framework == | ||
{{Bug|909524}} is ongoing effort to provide minimal components that serves as a good starting point | <p>{{Bug|909524}} is ongoing effort to provide minimal components that serves as a good starting point | ||
for carrying out Peer Connection audio quality analysis as part of Mozilla's Talos framework | for carrying out Peer Connection audio quality analysis as part of Mozilla's Talos framework.</p> | ||
Below picture captures the test setup for reporting Perceptual Evaluation of Speech Quality (PESQ) | Below picture captures the test setup for reporting Perceptual Evaluation of Speech Quality (PESQ) | ||
scores for audio played through the Peer Connection. | scores for audio played through the Peer Connection. | ||
| Line 58: | Line 59: | ||
Following sub-sections explain in details the various components for this setup. | Following sub-sections explain in details the various components for this setup. | ||
=== Talos === | === Talos === | ||
[[Talos]] is Mozilla's python performance testing framework that is usable on Windows, Mac and Linux. | <p>[[Talos]] is Mozilla's python performance testing framework that is usable on Windows, Mac and Linux. | ||
Talos provides automated way to start/stop Firefox , perform tests and capture results to be reported to the Mozilla's graphing server across various Firefox builds. | Talos provides automated way to start/stop Firefox , perform tests and capture results to be reported to the Mozilla's graphing server across various Firefox builds.</p> | ||
Talos is used in our setup to run media tests along with other start-up and page-loader performance tests. | <p>Talos is used in our setup to run media tests along with other start-up and page-loader performance tests.</p> | ||
=== MozCaptureStream and Peer Connection === | === MozCaptureStream and Peer Connection === | ||
Once we have the framework figured out to run automated media-tests, | <p>Once we have the framework figured out to run automated media-tests, the next step is deciding on how do we insert | ||
input audio file into WebRTC Peer Connection. For this purpose Mozilla's MediaStreamProcessing API '''mozCaptureStreamUntilEnded''' enables the <audio> element to produce MediaStream that consists | input audio file into the WebRTC Peer Connection.</p> | ||
of whatever the <audio> element is playing. Thus the stream produced by the <audio> element in this | <p>For this purpose Mozilla's MediaStreamProcessing API '''mozCaptureStreamUntilEnded''' enables the <audio> element to produce MediaStream that consists of whatever the <audio> element is playing. Thus the stream produced by the <audio> element in this fashion replaces the function of obtaining the media stream via the WebRTC GetUserMedia API. Finally, | ||
fashion replaces the function of obtaining the media stream via the WebRTC GetUserMedia API. Finally, | |||
the generated MediaStream is added to the local Peer Connection element via the addStream() API as shown | the generated MediaStream is added to the local Peer Connection element via the addStream() API as shown | ||
below | below.</p> | ||
<a | <code> | ||
// localAudio is an <audio> , localPC is a PeerConnection Object | |||
localAudio.src = "input.wav"; | |||
localAudioStream = localAudio.mozCaptureStreamUnitlEnded(); | |||
localAudio.play() | |||
localPC.addStream(localAudioStream) | |||
</code> | |||
<br> | |||
=== Audio Tools - PulseAudio, Sox, PESQ === | === Audio Tools - PulseAudio, Sox, PESQ === | ||
From the previous 2 sub-sections we have the following <br> | |||
*A way to run automated browser tests using Talos | |||
*A way a feeding audio from an input audio file audio input to the Peer Connection without having to use the GetUserMedia() API | |||
In order to record the output Audio and compute PESQ scores, | |||
=== Summary === | === Summary === | ||