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_ES_DESCRIPTOR_H_ | 5 #ifndef MEDIA_FORMATS_MP4_ES_DESCRIPTOR_H_ |
6 #define MEDIA_FORMATS_MP4_ES_DESCRIPTOR_H_ | 6 #define MEDIA_FORMATS_MP4_ES_DESCRIPTOR_H_ |
7 | 7 |
8 #include <stdint.h> | 8 #include <stdint.h> |
9 | 9 |
10 #include <vector> | 10 #include <vector> |
11 | 11 |
12 #include "media/base/media_export.h" | 12 #include "media/base/media_export.h" |
13 | 13 |
14 namespace media { | 14 namespace media { |
15 | 15 |
16 class BitReader; | 16 class BitReader; |
17 | 17 |
18 namespace mp4 { | 18 namespace mp4 { |
19 | 19 |
20 // The following values are extracted from ISO 14496 Part 1 Table 5 - | 20 // The following values are extracted from ISO 14496 Part 1 Table 5 - |
21 // objectTypeIndication Values. Only values currently in use are included. | 21 // objectTypeIndication Values. Only values currently in use are included. |
22 enum ObjectType { | 22 enum ObjectType { |
23 kForbidden = 0, | 23 kForbidden = 0, |
24 kISO_14496_3 = 0x40, // MPEG4 AAC | 24 kISO_14496_3 = 0x40, // MPEG4 AAC |
ddorwin
2016/01/04 23:22:17
Are these complex names the best option? I wonder
servolk
2016/01/07 02:30:04
I don't know. Git blame tells me these were added
| |
25 kISO_13818_7_AAC_LC = 0x67 // MPEG2 AAC-LC | 25 kISO_13818_7_AAC_LC = 0x67, // MPEG2 AAC-LC |
26 kAC3 = 0xa5, // AC3 | |
ddorwin
2016/01/04 23:22:17
Why do the names above have complex names while th
servolk
2016/01/07 02:30:04
I believe the standard that describes AC3/EAC3 aud
ddorwin
2016/01/07 19:12:43
I think we should be consistent, though I'm not wi
| |
27 kEAC3 = 0xa6 // EAC3 / Dolby Digital Plus | |
26 }; | 28 }; |
27 | 29 |
28 // This class parse object type and decoder specific information from an | 30 // This class parse object type and decoder specific information from an |
29 // elementary stream descriptor, which is usually contained in an esds box. | 31 // elementary stream descriptor, which is usually contained in an esds box. |
30 // Please refer to ISO 14496 Part 1 7.2.6.5 for more details. | 32 // Please refer to ISO 14496 Part 1 7.2.6.5 for more details. |
31 class MEDIA_EXPORT ESDescriptor { | 33 class MEDIA_EXPORT ESDescriptor { |
32 public: | 34 public: |
33 // Utility function to check if the given object type is AAC. | 35 // Utility function to check if the given object type is AAC. |
34 static bool IsAAC(uint8_t object_type); | 36 static bool IsAAC(uint8_t object_type); |
35 | 37 |
(...skipping 17 matching lines...) Expand all Loading... | |
53 | 55 |
54 uint8_t object_type_; | 56 uint8_t object_type_; |
55 std::vector<uint8_t> decoder_specific_info_; | 57 std::vector<uint8_t> decoder_specific_info_; |
56 }; | 58 }; |
57 | 59 |
58 } // namespace mp4 | 60 } // namespace mp4 |
59 | 61 |
60 } // namespace media | 62 } // namespace media |
61 | 63 |
62 #endif // MEDIA_FORMATS_MP4_ES_DESCRIPTOR_H_ | 64 #endif // MEDIA_FORMATS_MP4_ES_DESCRIPTOR_H_ |
OLD | NEW |