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

Unified Diff: media/webm/webm_crypto_helpers.h

Issue 119203003: Drop DecryptConfig::data_offset_. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix test Created 7 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
Index: media/webm/webm_crypto_helpers.h
diff --git a/media/webm/webm_crypto_helpers.h b/media/webm/webm_crypto_helpers.h
index c5f1f15ecac8abc21ebf6ced4aea75a52a3eff9a..086d745e3904dfae312b787bec3f37f151dfae5d 100644
--- a/media/webm/webm_crypto_helpers.h
+++ b/media/webm/webm_crypto_helpers.h
@@ -16,16 +16,17 @@ namespace media {
// information.
const char kWebMEncryptInitDataType[] = "video/webm";
-// Returns an initialized DecryptConfig, which can be sent to the Decryptor if
-// the stream has potentially encrypted frames. Every encrypted Block has a
-// signal byte, and if the frame is encrypted, an initialization vector
-// prepended to the frame. Leaving the IV empty will tell the decryptor that the
-// frame is unencrypted. Returns NULL if |data| is invalid. Current encrypted
-// WebM request for comments specification is here
+// Fills an initialized DecryptConfig, which can be sent to the Decryptor if
+// the stream has potentially encrypted frames. Also sets |data_offset| which
+// indicates where the encrypted data starts. Leaving the IV empty will tell
+// the decryptor that the frame is unencrypted. Returns true if |data| is valid,
+// false otherwise, in which case |decrypt_config| and |data_offset| will not be
+// changed. Current encrypted WebM request for comments specification is here
// http://wiki.webmproject.org/encryption/webm-encryption-rfc
-scoped_ptr<DecryptConfig> WebMCreateDecryptConfig(
- const uint8* data, int data_size,
- const uint8* key_id, int key_id_size);
+bool WebMCreateDecryptConfig(const uint8* data, int data_size,
+ const uint8* key_id, int key_id_size,
+ scoped_ptr<DecryptConfig>* decrypt_config,
+ int* data_offset);
} // namespace media

Powered by Google App Engine
This is Rietveld 408576698