| Index: media/formats/mp2t/mp2t_stream_parser.h
 | 
| diff --git a/media/formats/mp2t/mp2t_stream_parser.h b/media/formats/mp2t/mp2t_stream_parser.h
 | 
| index 7c5c6951c3875b58b765ae21cb62cfd2aef8213e..bc24377c1737ed9d637e288d203b083a214b6f7b 100644
 | 
| --- a/media/formats/mp2t/mp2t_stream_parser.h
 | 
| +++ b/media/formats/mp2t/mp2t_stream_parser.h
 | 
| @@ -15,17 +15,21 @@
 | 
|  #include "base/memory/ref_counted.h"
 | 
|  #include "media/base/audio_decoder_config.h"
 | 
|  #include "media/base/byte_queue.h"
 | 
| +#include "media/base/decrypt_config.h"
 | 
|  #include "media/base/media_export.h"
 | 
|  #include "media/base/stream_parser.h"
 | 
|  #include "media/base/video_decoder_config.h"
 | 
|  #include "media/formats/mp2t/timestamp_unroller.h"
 | 
| +#include "media/media_features.h"
 | 
|  
 | 
|  namespace media {
 | 
|  
 | 
| +class DecryptConfig;
 | 
|  class StreamParserBuffer;
 | 
|  
 | 
|  namespace mp2t {
 | 
|  
 | 
| +class Descriptors;
 | 
|  class PidState;
 | 
|  
 | 
|  class MEDIA_EXPORT Mp2tStreamParser : public StreamParser {
 | 
| @@ -68,7 +72,11 @@ class MEDIA_EXPORT Mp2tStreamParser : public StreamParser {
 | 
|    // Possible values for |stream_type| are defined in:
 | 
|    // ISO-13818.1 / ITU H.222 Table 2.34 "Stream type assignments".
 | 
|    // |pes_pid| is part of the Program Map Table refered by |pmt_pid|.
 | 
| -  void RegisterPes(int pmt_pid, int pes_pid, int stream_type);
 | 
| +  // Some stream types are qualified by additional |descriptors|.
 | 
| +  void RegisterPes(int pmt_pid,
 | 
| +                   int pes_pid,
 | 
| +                   int stream_type,
 | 
| +                   const Descriptors& descriptors);
 | 
|  
 | 
|    // Since the StreamParser interface allows only one audio & video streams,
 | 
|    // an automatic PID filtering should be applied to select the audio & video
 | 
| @@ -95,6 +103,23 @@ class MEDIA_EXPORT Mp2tStreamParser : public StreamParser {
 | 
|        scoped_refptr<StreamParserBuffer> stream_parser_buffer);
 | 
|    bool EmitRemainingBuffers();
 | 
|  
 | 
| +#if BUILDFLAG(ENABLE_HLS_SAMPLE_AES)
 | 
| +  std::unique_ptr<PidState> MakeCatPidState();
 | 
| +  void UnregisterCat();
 | 
| +
 | 
| +  // Register the PIDs for the Cenc packets (CENC-ECM and CENC-PSSH).
 | 
| +  void RegisterCencPids(int ca_pid, int pssh_pid);
 | 
| +  void UnregisterCencPids();
 | 
| +
 | 
| +  // Register the DecryptConfig (parsed from CENC-ECM).
 | 
| +  void RegisterDecryptConfig(const DecryptConfig& config);
 | 
| +
 | 
| +  // Register the PSSH (parsed from CENC-PSSH).
 | 
| +  void RegisterPsshBoxes(const std::vector<uint8_t>& init_data);
 | 
| +
 | 
| +  const DecryptConfig* GetDecryptConfig() { return decrypt_config_.get(); }
 | 
| +#endif
 | 
| +
 | 
|    // List of callbacks.
 | 
|    InitCB init_cb_;
 | 
|    NewConfigCB config_cb_;
 | 
| @@ -132,6 +157,10 @@ class MEDIA_EXPORT Mp2tStreamParser : public StreamParser {
 | 
|    // So the unroller is global between PES pids.
 | 
|    TimestampUnroller timestamp_unroller_;
 | 
|  
 | 
| +#if BUILDFLAG(ENABLE_HLS_SAMPLE_AES)
 | 
| +  std::unique_ptr<DecryptConfig> decrypt_config_;
 | 
| +#endif
 | 
| +
 | 
|    DISALLOW_COPY_AND_ASSIGN(Mp2tStreamParser);
 | 
|  };
 | 
|  
 | 
| 
 |