| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef WEBKIT_MEDIA_CRYPTO_PPAPI_FFMPEG_CDM_VIDEO_DECODER_H_ | 5 #ifndef WEBKIT_MEDIA_CRYPTO_PPAPI_FFMPEG_CDM_VIDEO_DECODER_H_ |
| 6 #define WEBKIT_MEDIA_CRYPTO_PPAPI_FFMPEG_CDM_VIDEO_DECODER_H_ | 6 #define WEBKIT_MEDIA_CRYPTO_PPAPI_FFMPEG_CDM_VIDEO_DECODER_H_ |
| 7 | 7 |
| 8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
| 9 #include "base/compiler_specific.h" | 9 #include "base/compiler_specific.h" |
| 10 #include "webkit/media/crypto/ppapi/content_decryption_module.h" | 10 #include "webkit/media/crypto/ppapi/content_decryption_module.h" |
| 11 | 11 |
| 12 struct AVCodecContext; | 12 struct AVCodecContext; |
| 13 struct AVFrame; | 13 struct AVFrame; |
| 14 | 14 |
| 15 namespace webkit_media { | 15 namespace webkit_media { |
| 16 | 16 |
| 17 class FFmpegCdmVideoDecoder { | 17 class FFmpegCdmVideoDecoder { |
| 18 public: | 18 public: |
| 19 FFmpegCdmVideoDecoder(cdm::Allocator* allocator); | 19 explicit FFmpegCdmVideoDecoder(cdm::Allocator* allocator); |
| 20 ~FFmpegCdmVideoDecoder(); | 20 ~FFmpegCdmVideoDecoder(); |
| 21 bool Initialize(const cdm::VideoDecoderConfig& config); | 21 bool Initialize(const cdm::VideoDecoderConfig& config); |
| 22 void Deinitialize(); | 22 void Deinitialize(); |
| 23 void Reset(); | 23 void Reset(); |
| 24 | 24 |
| 25 // Returns true when |format| and |data_size| specify a supported video | 25 // Returns true when |format| and |data_size| specify a supported video |
| 26 // output configuration. | 26 // output configuration. |
| 27 static bool IsValidOutputConfig(cdm::VideoFormat format, | 27 static bool IsValidOutputConfig(cdm::VideoFormat format, |
| 28 const cdm::Size& data_size); | 28 const cdm::Size& data_size); |
| 29 | 29 |
| (...skipping 20 matching lines...) Expand all Loading... |
| 50 bool is_initialized_; | 50 bool is_initialized_; |
| 51 | 51 |
| 52 cdm::Allocator* const allocator_; | 52 cdm::Allocator* const allocator_; |
| 53 | 53 |
| 54 DISALLOW_COPY_AND_ASSIGN(FFmpegCdmVideoDecoder); | 54 DISALLOW_COPY_AND_ASSIGN(FFmpegCdmVideoDecoder); |
| 55 }; | 55 }; |
| 56 | 56 |
| 57 } // namespace webkit_media | 57 } // namespace webkit_media |
| 58 | 58 |
| 59 #endif // WEBKIT_MEDIA_CRYPTO_PPAPI_FFMPEG_CDM_VIDEO_DECODER_H_ | 59 #endif // WEBKIT_MEDIA_CRYPTO_PPAPI_FFMPEG_CDM_VIDEO_DECODER_H_ |
| OLD | NEW |