OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 MEDIA_FORMATS_MP4_BOX_DEFINITIONS_H_ | 5 #ifndef MEDIA_FORMATS_MP4_BOX_DEFINITIONS_H_ |
6 #define MEDIA_FORMATS_MP4_BOX_DEFINITIONS_H_ | 6 #define MEDIA_FORMATS_MP4_BOX_DEFINITIONS_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 26 matching lines...) Expand all Loading... |
37 bool Parse(BoxReader* reader) override; \ | 37 bool Parse(BoxReader* reader) override; \ |
38 FourCC BoxType() const override; | 38 FourCC BoxType() const override; |
39 | 39 |
40 struct MEDIA_EXPORT FileType : Box { | 40 struct MEDIA_EXPORT FileType : Box { |
41 DECLARE_BOX_METHODS(FileType); | 41 DECLARE_BOX_METHODS(FileType); |
42 | 42 |
43 FourCC major_brand; | 43 FourCC major_brand; |
44 uint32 minor_version; | 44 uint32 minor_version; |
45 }; | 45 }; |
46 | 46 |
47 // If only copying the 'pssh' boxes, use ProtectionSystemSpecificHeader. | |
48 // If access to the individual fields is needed, use | |
49 // FullProtectionSystemSpecificHeader. | |
50 struct MEDIA_EXPORT ProtectionSystemSpecificHeader : Box { | 47 struct MEDIA_EXPORT ProtectionSystemSpecificHeader : Box { |
51 DECLARE_BOX_METHODS(ProtectionSystemSpecificHeader); | 48 DECLARE_BOX_METHODS(ProtectionSystemSpecificHeader); |
52 | 49 |
| 50 std::vector<uint8> system_id; |
53 std::vector<uint8> raw_box; | 51 std::vector<uint8> raw_box; |
54 }; | 52 }; |
55 | 53 |
56 struct MEDIA_EXPORT FullProtectionSystemSpecificHeader : Box { | |
57 DECLARE_BOX_METHODS(FullProtectionSystemSpecificHeader); | |
58 | |
59 std::vector<uint8> system_id; | |
60 std::vector<std::vector<uint8>> key_ids; | |
61 std::vector<uint8> data; | |
62 }; | |
63 | |
64 struct MEDIA_EXPORT SampleAuxiliaryInformationOffset : Box { | 54 struct MEDIA_EXPORT SampleAuxiliaryInformationOffset : Box { |
65 DECLARE_BOX_METHODS(SampleAuxiliaryInformationOffset); | 55 DECLARE_BOX_METHODS(SampleAuxiliaryInformationOffset); |
66 | 56 |
67 std::vector<uint64> offsets; | 57 std::vector<uint64> offsets; |
68 }; | 58 }; |
69 | 59 |
70 struct MEDIA_EXPORT SampleAuxiliaryInformationSize : Box { | 60 struct MEDIA_EXPORT SampleAuxiliaryInformationSize : Box { |
71 DECLARE_BOX_METHODS(SampleAuxiliaryInformationSize); | 61 DECLARE_BOX_METHODS(SampleAuxiliaryInformationSize); |
72 | 62 |
73 uint8 default_sample_info_size; | 63 uint8 default_sample_info_size; |
(...skipping 365 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
439 std::vector<TrackFragment> tracks; | 429 std::vector<TrackFragment> tracks; |
440 std::vector<ProtectionSystemSpecificHeader> pssh; | 430 std::vector<ProtectionSystemSpecificHeader> pssh; |
441 }; | 431 }; |
442 | 432 |
443 #undef DECLARE_BOX | 433 #undef DECLARE_BOX |
444 | 434 |
445 } // namespace mp4 | 435 } // namespace mp4 |
446 } // namespace media | 436 } // namespace media |
447 | 437 |
448 #endif // MEDIA_FORMATS_MP4_BOX_DEFINITIONS_H_ | 438 #endif // MEDIA_FORMATS_MP4_BOX_DEFINITIONS_H_ |
OLD | NEW |