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

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

Issue 260963002: Support parsing of sgpd and sbgp boxes (Closed) Base URL: http://git.chromium.org/chromium/src.git@temp
Patch Set: Created 6 years, 8 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
« no previous file with comments | « no previous file | media/formats/mp4/box_definitions.cc » ('j') | media/formats/mp4/box_definitions.cc » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/formats/mp4/box_definitions.h
diff --git a/media/formats/mp4/box_definitions.h b/media/formats/mp4/box_definitions.h
index 9daa82e136c11e188854f377d741971f0b854ff8..de267d9cc462b933a67202009674ca2d00978de7 100644
--- a/media/formats/mp4/box_definitions.h
+++ b/media/formats/mp4/box_definitions.h
@@ -355,6 +355,40 @@ class MEDIA_EXPORT IndependentAndDisposableSamples : public Box {
std::vector<SampleDependsOn> sample_depends_on_;
};
+struct MEDIA_EXPORT CencSampleEncryptionInfoEntry {
+ CencSampleEncryptionInfoEntry();
+ ~CencSampleEncryptionInfoEntry();
+
+ bool is_encrypted;
+ uint8 iv_size;
+ std::vector<uint8> key_id;
+};
+
+struct MEDIA_EXPORT SampleGroupDescription : Box {
xhwang 2014/05/01 19:11:28 Add comment that this is "sgpd" box.
kqyang 2014/05/01 20:26:35 Done.
+ DECLARE_BOX_METHODS(SampleGroupDescription);
+
+ uint32 grouping_type;
+ std::vector<CencSampleEncryptionInfoEntry> entries;
+};
+
+struct MEDIA_EXPORT SampleToGroupEntry {
+ enum GroupDescriptionIndexBase {
+ kTrackGroupDescriptionIndexBase = 0,
+ kFragmentGroupDescriptionIndexBase = 0x10000,
+ };
+
+ uint32 sample_count;
+ uint32 group_description_index;
+};
+
+struct MEDIA_EXPORT SampleToGroup : Box {
xhwang 2014/05/01 19:11:28 Add comment that this is a "sbgp" box.
kqyang 2014/05/01 20:26:35 Done.
+ DECLARE_BOX_METHODS(SampleToGroup);
+
+ uint32 grouping_type;
+ uint32 grouping_type_parameter; // Version 1 only.
+ std::vector<SampleToGroupEntry> entries;
+};
+
struct MEDIA_EXPORT TrackFragment : Box {
DECLARE_BOX_METHODS(TrackFragment);
@@ -364,6 +398,8 @@ struct MEDIA_EXPORT TrackFragment : Box {
SampleAuxiliaryInformationOffset auxiliary_offset;
SampleAuxiliaryInformationSize auxiliary_size;
IndependentAndDisposableSamples sdtp;
+ SampleGroupDescription sample_group_description;
+ SampleToGroup sample_to_group;
};
struct MEDIA_EXPORT MovieFragment : Box {
« no previous file with comments | « no previous file | media/formats/mp4/box_definitions.cc » ('j') | media/formats/mp4/box_definitions.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698