summaryrefslogtreecommitdiff
path: root/chromium/media/audio/audio_io.h
diff options
context:
space:
mode:
Diffstat (limited to 'chromium/media/audio/audio_io.h')
-rw-r--r--chromium/media/audio/audio_io.h12
1 files changed, 10 insertions, 2 deletions
diff --git a/chromium/media/audio/audio_io.h b/chromium/media/audio/audio_io.h
index ae9111ab575..e574390d52e 100644
--- a/chromium/media/audio/audio_io.h
+++ b/chromium/media/audio/audio_io.h
@@ -39,7 +39,6 @@
// Specifically for this case we avoid supporting complex formats such as MP3
// or WMA. Complex format decoding should be done by the renderers.
-
// Models an audio stream that gets rendered to the audio hardware output.
// Because we support more audio streams than physically available channels
// a given AudioOutputStream might or might not talk directly to hardware.
@@ -155,9 +154,18 @@ class MEDIA_EXPORT AudioInputStream {
virtual ~AudioInputStream() {}
+ enum class OpenOutcome {
+ kSuccess,
+ kAlreadyOpen,
+ // Failed due to an unknown or unspecified reason.
+ kFailed,
+ // Failed to open due to OS-level System permissions.
+ kFailedSystemPermissions,
+ };
+
// Open the stream and prepares it for recording. Call Start() to actually
// begin recording.
- virtual bool Open() = 0;
+ virtual OpenOutcome Open() = 0;
// Starts recording audio and generating AudioInputCallback::OnData().
// The input stream does not take ownership of this callback.