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

Unified Diff: media/base/audio_decoder_config.h

Issue 1490613005: media config: expand is_encrypted to a struct. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: mojo changes; Message->base::Pickle Created 4 years, 10 months 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_decoder_config.h
diff --git a/media/base/audio_decoder_config.h b/media/base/audio_decoder_config.h
index a0e262f005d3343279ac3e5fa137549d4a203db8..022f96536fb475123c46e3cb3037482fbf4f1fc6 100644
--- a/media/base/audio_decoder_config.h
+++ b/media/base/audio_decoder_config.h
@@ -13,6 +13,7 @@
#include "base/macros.h"
#include "base/time/time.h"
#include "media/base/channel_layout.h"
+#include "media/base/encryption_scheme.h"
#include "media/base/media_export.h"
#include "media/base/sample_format.h"
@@ -66,7 +67,7 @@ class MEDIA_EXPORT AudioDecoderConfig {
ChannelLayout channel_layout,
int samples_per_second,
const std::vector<uint8_t>& extra_data,
- bool is_encrypted);
+ const EncryptionScheme& encryption_scheme);
~AudioDecoderConfig();
@@ -76,7 +77,7 @@ class MEDIA_EXPORT AudioDecoderConfig {
ChannelLayout channel_layout,
int samples_per_second,
const std::vector<uint8_t>& extra_data,
- bool is_encrypted,
+ const EncryptionScheme& encryption_scheme,
base::TimeDelta seek_preroll,
int codec_delay);
@@ -109,7 +110,12 @@ class MEDIA_EXPORT AudioDecoderConfig {
// Whether the audio stream is potentially encrypted.
// Note that in a potentially encrypted audio stream, individual buffers
// can be encrypted or not encrypted.
- bool is_encrypted() const { return is_encrypted_; }
+ bool is_encrypted() const;
ddorwin 2016/03/01 02:17:41 My concern in PS1 of cast_audio_output_stream_unit
dougsteed 2016/03/02 18:07:52 It seems to me that generally in the code (there a
ddorwin 2016/03/02 23:24:05 Okay. I guess we should look for places where we e
+
+ // Encryption scheme used for encrypted buffers.
+ const EncryptionScheme& encryption_scheme() const {
+ return encryption_scheme_;
+ }
private:
AudioCodec codec_;
@@ -119,7 +125,7 @@ class MEDIA_EXPORT AudioDecoderConfig {
int samples_per_second_;
int bytes_per_frame_;
std::vector<uint8_t> extra_data_;
- bool is_encrypted_;
+ EncryptionScheme encryption_scheme_;
// |seek_preroll_| is the duration of the data that the decoder must decode
// before the decoded data is valid.

Powered by Google App Engine
This is Rietveld 408576698