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

Unified Diff: webkit/media/crypto/ppapi/clear_key_cdm.h

Issue 11316045: Add a libvpx video decoder to ClearKeyCdm and move the fake video decoder to its own class. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase, fix incorrect DCHECK and fix include order. Created 8 years 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
« no previous file with comments | « webkit/media/crypto/ppapi/cdm_video_decoder.cc ('k') | webkit/media/crypto/ppapi/clear_key_cdm.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webkit/media/crypto/ppapi/clear_key_cdm.h
diff --git a/webkit/media/crypto/ppapi/clear_key_cdm.h b/webkit/media/crypto/ppapi/clear_key_cdm.h
index 691e1df128bc41a9cc5355a171c4f19ef4e5a4d0..83fd9e1fc0da1c6b851c3582242c9ff390fea373 100644
--- a/webkit/media/crypto/ppapi/clear_key_cdm.h
+++ b/webkit/media/crypto/ppapi/clear_key_cdm.h
@@ -17,27 +17,19 @@
#include "webkit/media/crypto/ppapi/content_decryption_module.h"
// Enable this to use the fake decoder for testing.
-// TODO(xhwang): Move fake decoders into separate classes.
+// TODO(tomfinegan): Move fake audio decoder into a separate class.
#if 0
#define CLEAR_KEY_CDM_USE_FAKE_AUDIO_DECODER
#endif
-#if 0
-#define CLEAR_KEY_CDM_USE_FAKE_VIDEO_DECODER
-#endif
-
-#if defined(CLEAR_KEY_CDM_USE_FAKE_VIDEO_DECODER)
-#undef CLEAR_KEY_CDM_USE_FFMPEG_DECODER
-#endif
-
namespace media {
class DecoderBuffer;
}
namespace webkit_media {
+class CdmVideoDecoder;
class FFmpegCdmAudioDecoder;
-class FFmpegCdmVideoDecoder;
// Clear key implementation of the cdm::ContentDecryptionModule interface.
class ClearKeyCdm : public cdm::ContentDecryptionModule {
@@ -143,13 +135,7 @@ class ClearKeyCdm : public cdm::ContentDecryptionModule {
// Returns cdm::kSuccess if any audio frame is successfully generated.
cdm::Status GenerateFakeAudioFrames(int64 timestamp_in_microseconds,
cdm::AudioFrames* audio_frames);
-#endif // CLEAR_KEY_CDM_USE_FAKE_VIDEO_DECODER
-
-#if defined(CLEAR_KEY_CDM_USE_FAKE_VIDEO_DECODER)
- // Generates a fake video frame with |video_size_| and |timestamp|.
- void GenerateFakeVideoFrame(base::TimeDelta timestamp,
- cdm::VideoFrame* video_frame);
-#endif // CLEAR_KEY_CDM_USE_FAKE_VIDEO_DECODER
+#endif // CLEAR_KEY_CDM_USE_FAKE_AUDIO_DECODER
Client client_;
media::AesDecryptor decryptor_;
@@ -180,12 +166,11 @@ class ClearKeyCdm : public cdm::ContentDecryptionModule {
#if defined(CLEAR_KEY_CDM_USE_FFMPEG_DECODER)
scoped_ptr<FFmpegCdmAudioDecoder> audio_decoder_;
- scoped_ptr<FFmpegCdmVideoDecoder> video_decoder_;
#endif // CLEAR_KEY_CDM_USE_FFMPEG_DECODER
-#if defined(CLEAR_KEY_CDM_USE_FAKE_VIDEO_DECODER)
- cdm::Size video_size_;
-#endif // CLEAR_KEY_CDM_USE_FAKE_VIDEO_DECODER
+ scoped_ptr<CdmVideoDecoder> video_decoder_;
+
+ DISALLOW_COPY_AND_ASSIGN(ClearKeyCdm);
};
} // namespace webkit_media
« no previous file with comments | « webkit/media/crypto/ppapi/cdm_video_decoder.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