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

Side by Side Diff: webkit/media/crypto/ppapi/clear_key_cdm.h

Issue 11028087: Add decoder de-initialize and reset to the Pepper CDM API. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Address comments with the exception of renaming Deinit Created 8 years, 2 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « webkit/media/crypto/ppapi/cdm_wrapper.cc ('k') | webkit/media/crypto/ppapi/clear_key_cdm.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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_CLEAR_KEY_CDM_H_ 5 #ifndef WEBKIT_MEDIA_CRYPTO_PPAPI_CLEAR_KEY_CDM_H_
6 #define WEBKIT_MEDIA_CRYPTO_PPAPI_CLEAR_KEY_CDM_H_ 6 #define WEBKIT_MEDIA_CRYPTO_PPAPI_CLEAR_KEY_CDM_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
(...skipping 27 matching lines...) Expand all
38 int key_size, 38 int key_size,
39 const uint8_t* key_id, 39 const uint8_t* key_id,
40 int key_id_size) OVERRIDE; 40 int key_id_size) OVERRIDE;
41 virtual cdm::Status CancelKeyRequest(const char* session_id, 41 virtual cdm::Status CancelKeyRequest(const char* session_id,
42 int session_id_size) OVERRIDE; 42 int session_id_size) OVERRIDE;
43 virtual void TimerExpired(cdm::KeyMessage* msg, bool* populated) OVERRIDE; 43 virtual void TimerExpired(cdm::KeyMessage* msg, bool* populated) OVERRIDE;
44 virtual cdm::Status Decrypt(const cdm::InputBuffer& encrypted_buffer, 44 virtual cdm::Status Decrypt(const cdm::InputBuffer& encrypted_buffer,
45 cdm::DecryptedBlock* decrypted_block) OVERRIDE; 45 cdm::DecryptedBlock* decrypted_block) OVERRIDE;
46 virtual cdm::Status InitializeVideoDecoder( 46 virtual cdm::Status InitializeVideoDecoder(
47 const cdm::VideoDecoderConfig& video_decoder_config) OVERRIDE; 47 const cdm::VideoDecoderConfig& video_decoder_config) OVERRIDE;
48 virtual void DeinitializeDecoder(cdm::StreamType decoder_type) OVERRIDE;
49 virtual void ResetDecoder(cdm::StreamType decoder_type) OVERRIDE;
48 virtual cdm::Status DecryptAndDecodeFrame( 50 virtual cdm::Status DecryptAndDecodeFrame(
49 const cdm::InputBuffer& encrypted_buffer, 51 const cdm::InputBuffer& encrypted_buffer,
50 cdm::VideoFrame* video_frame) OVERRIDE; 52 cdm::VideoFrame* video_frame) OVERRIDE;
51 virtual void ResetVideoDecoder() OVERRIDE;
52 virtual void StopVideoDecoder() OVERRIDE;
53 53
54 private: 54 private:
55 class Client : public media::DecryptorClient { 55 class Client : public media::DecryptorClient {
56 public: 56 public:
57 enum Status { 57 enum Status {
58 kKeyAdded, 58 kKeyAdded,
59 kKeyError, 59 kKeyError,
60 kKeyMessage, 60 kKeyMessage,
61 kNeedKey 61 kNeedKey
62 }; 62 };
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
104 // Protects the |client_| from being accessed by the |decryptor_| 104 // Protects the |client_| from being accessed by the |decryptor_|
105 // simultaneously. 105 // simultaneously.
106 base::Lock client_lock_; 106 base::Lock client_lock_;
107 107
108 cdm::Allocator* const allocator_; 108 cdm::Allocator* const allocator_;
109 }; 109 };
110 110
111 } // namespace webkit_media 111 } // namespace webkit_media
112 112
113 #endif // WEBKIT_MEDIA_CRYPTO_PPAPI_CLEAR_KEY_CDM_H_ 113 #endif // WEBKIT_MEDIA_CRYPTO_PPAPI_CLEAR_KEY_CDM_H_
OLDNEW
« no previous file with comments | « webkit/media/crypto/ppapi/cdm_wrapper.cc ('k') | webkit/media/crypto/ppapi/clear_key_cdm.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698