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

Unified Diff: media/formats/mp4/box_definitions.h

Issue 1998333002: MP4 support for Common Encryption 'cbcs' scheme. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: handle comments Created 4 years, 6 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 side-by-side diff with in-line comments
Download patch
Index: media/formats/mp4/box_definitions.h
diff --git a/media/formats/mp4/box_definitions.h b/media/formats/mp4/box_definitions.h
index 01138801bea9d590af1327fe37527646fb0c8fce..8c2f2832f7c95e3116a49c0cb28962c656ef8ce3 100644
--- a/media/formats/mp4/box_definitions.h
+++ b/media/formats/mp4/box_definitions.h
@@ -20,6 +20,7 @@
#include "media/formats/mp4/avc.h"
#include "media/formats/mp4/box_reader.h"
#include "media/formats/mp4/fourccs.h"
+#include "media/media_features.h"
namespace media {
namespace mp4 {
@@ -129,6 +130,12 @@ struct MEDIA_EXPORT TrackEncryption : Box {
bool is_encrypted;
uint8_t default_iv_size;
std::vector<uint8_t> default_kid;
+#if BUILDFLAG(ENABLE_CBCS_ENCRYPTION_SCHEME)
+ uint8_t default_crypt_byte_block;
ddorwin 2016/06/17 23:32:40 Is "crypt" a common term in the spec? If not, use
dougsteed 2016/10/10 18:18:01 yes, this is the term used in the spec.
+ uint8_t default_skip_byte_block;
ddorwin 2016/06/17 23:32:40 Is this a count? If so, specify that because it's
dougsteed 2016/10/10 18:18:01 I used the exact term in the spec that names this
+ uint8_t default_constant_iv_size;
+ uint8_t default_constant_iv[16];
+#endif
};
struct MEDIA_EXPORT SchemeInfo : Box {
@@ -143,6 +150,8 @@ struct MEDIA_EXPORT ProtectionSchemeInfo : Box {
OriginalFormat format;
SchemeType type;
SchemeInfo info;
+
+ bool HasSupportedScheme() const;
};
struct MEDIA_EXPORT MovieHeader : Box {
@@ -282,10 +291,17 @@ struct MEDIA_EXPORT CencSampleEncryptionInfoEntry {
CencSampleEncryptionInfoEntry();
CencSampleEncryptionInfoEntry(const CencSampleEncryptionInfoEntry& other);
~CencSampleEncryptionInfoEntry();
+ bool Parse(BoxReader* reader);
bool is_encrypted;
uint8_t iv_size;
std::vector<uint8_t> key_id;
+#if BUILDFLAG(ENABLE_CBCS_ENCRYPTION_SCHEME)
+ uint8_t crypt_byte_block;
ddorwin 2016/06/17 23:32:40 ditto on names
dougsteed 2016/10/10 18:18:01 ditto. This is the actual name for the field in th
+ uint8_t skip_byte_block;
+ uint8_t constant_iv_size;
+ uint8_t constant_iv[16];
+#endif
};
struct MEDIA_EXPORT SampleGroupDescription : Box { // 'sgpd'.

Powered by Google App Engine
This is Rietveld 408576698