Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1325)

Unified Diff: media/base/audio_parameters.h

Issue 2503233003: Add enumerations for compressed (E)AC3 sample format (Closed)
Patch Set: Created 4 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: media/base/audio_parameters.h
diff --git a/media/base/audio_parameters.h b/media/base/audio_parameters.h
index 2cb28c64bdfd5688f244324d1d80df0ba8fb9005..d2628538e14b16881ba251f40164811981a1172a 100644
--- a/media/base/audio_parameters.h
+++ b/media/base/audio_parameters.h
@@ -72,6 +72,8 @@ class MEDIA_EXPORT AudioParameters {
enum Format {
AUDIO_PCM_LINEAR = 0, // PCM is 'raw' amplitude samples.
AUDIO_PCM_LOW_LATENCY, // Linear PCM, low latency requested.
+ AUDIO_BITSTREAM_AC3, // Compressed AC3 bitstream.
+ AUDIO_BITSTREAM_EAC3, // Compressed E-AC3 bitstream.
AUDIO_FAKE, // Creates a fake AudioOutputStream object.
AUDIO_FORMAT_LAST = AUDIO_FAKE, // Only used for validation of format.
};
@@ -139,6 +141,9 @@ class MEDIA_EXPORT AudioParameters {
// Comparison with other AudioParams.
bool Equals(const AudioParameters& other) const;
+ // Return true if |format_| is compressed audio.
+ bool IsCompressedFormat() const;
+
void set_format(Format format) { format_ = format; }
Format format() const { return format_; }

Powered by Google App Engine
This is Rietveld 408576698