Chromium Code Reviews| Index: media/base/audio_decoder_config.h |
| diff --git a/media/base/audio_decoder_config.h b/media/base/audio_decoder_config.h |
| index ae72383a0a99853cb13bf6d744c120b3474b4f97..d098a9480fb167490040eb582e0ff9d6d149d88b 100644 |
| --- a/media/base/audio_decoder_config.h |
| +++ b/media/base/audio_decoder_config.h |
| @@ -11,6 +11,7 @@ |
| #include "base/basictypes.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" |
| @@ -61,7 +62,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(); |
| @@ -71,7 +72,7 @@ class MEDIA_EXPORT AudioDecoderConfig { |
| ChannelLayout channel_layout, |
| int samples_per_second, |
| const std::vector<uint8>& extra_data, |
| - bool is_encrypted, |
| + const EncryptionScheme& encryption_scheme, |
| base::TimeDelta seek_preroll, |
| int codec_delay); |
| @@ -106,7 +107,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 { return encryption_scheme_.is_encrypted(); } |
|
ddorwin
2015/12/10 18:36:00
As mentioned earlier, I think this might be hiding
ddorwin
2015/12/10 18:36:00
Again, unclear if this is a "simple accessor."
dougsteed
2015/12/14 21:19:01
I don't know all the usages of this class, and I d
|
| + |
| + // Encryption scheme used for encrypted buffers. |
| + const EncryptionScheme& encryption_scheme() const { |
| + return encryption_scheme_; |
| + } |
| private: |
| AudioCodec codec_; |
| @@ -116,7 +122,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. |