Options
Menu

Interface Report

Represents the report generated from an AudioInputTest.

Hierarchy

  • Report

Index

Properties

deviceId

deviceId: MediaTrackConstraintSet["deviceId"]

The device ID used to get a MediaStream from using getUserMedia.

errors

errors: DiagnosticError[]

Any errors that occurred during the test.

Optional recordingUrl

recordingUrl: undefined | string

If AudioInputTest.Options.enableRecording is set to true, recordingUrl will be available in the report which can be used to playback captured audio from the microphone. Your application should revoke this URL if it is no longer needed.

Example:

const audioInputTest: AudioInputTest = testAudioInputDevice({ enableRecording: true });
audioInputTest.on(AudioInputTest.Events.End, (report: AudioInputTest.Report) => {
  const audioEl = new Audio();
  audioEl.src = report.recordingUrl;
  audioEl.play();

  // Revoke the url if no longer needed
  URL.revokeObjectURL(report.recordingUrl);
});

testName

testName: typeof testName

The name of the test.

Optional testTiming

testTiming: TimeMeasurement

Time measurements of test run time.

values

values: number[]

The volume levels emitted by the test during its run-time.

Generated using TypeDoc