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

Side by Side Diff: media/webm/webm_parser.cc

Issue 23014009: media: Opus support for WebM in Media Source (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 7 years, 3 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 #include "media/webm/webm_parser.h" 5 #include "media/webm/webm_parser.h"
6 6
7 // This file contains code to parse WebM file elements. It was created 7 // This file contains code to parse WebM file elements. It was created
8 // from information in the Matroska spec. 8 // from information in the Matroska spec.
9 // http://www.matroska.org/technical/specs/index.html 9 // http://www.matroska.org/technical/specs/index.html
10 // This file contains code for encrypted WebM. Current WebM 10 // This file contains code for encrypted WebM. Current WebM
(...skipping 101 matching lines...) Expand 10 before | Expand all | Expand 10 after
112 }; 112 };
113 113
114 static const ElementIdInfo kBlockGroupIds[] = { 114 static const ElementIdInfo kBlockGroupIds[] = {
115 {BINARY, kWebMIdBlock}, 115 {BINARY, kWebMIdBlock},
116 {LIST, kWebMIdBlockAdditions}, 116 {LIST, kWebMIdBlockAdditions},
117 {UINT, kWebMIdBlockDuration}, 117 {UINT, kWebMIdBlockDuration},
118 {UINT, kWebMIdReferencePriority}, 118 {UINT, kWebMIdReferencePriority},
119 {BINARY, kWebMIdReferenceBlock}, 119 {BINARY, kWebMIdReferenceBlock},
120 {BINARY, kWebMIdCodecState}, 120 {BINARY, kWebMIdCodecState},
121 {LIST, kWebMIdSlices}, 121 {LIST, kWebMIdSlices},
122 {UINT, kWebMIdDiscardPadding},
fgalligan1 2013/08/26 21:10:06 DiscardPadding should come after CodecState.
vignesh 2013/08/26 21:44:23 Done.
122 }; 123 };
123 124
124 static const ElementIdInfo kBlockAdditionsIds[] = { 125 static const ElementIdInfo kBlockAdditionsIds[] = {
125 {LIST, kWebMIdBlockMore}, 126 {LIST, kWebMIdBlockMore},
126 }; 127 };
127 128
128 static const ElementIdInfo kBlockMoreIds[] = { 129 static const ElementIdInfo kBlockMoreIds[] = {
129 {UINT, kWebMIdBlockAddID}, 130 {UINT, kWebMIdBlockAddID},
130 {BINARY, kWebMIdBlockAdditional}, 131 {BINARY, kWebMIdBlockAdditional},
131 }; 132 };
(...skipping 21 matching lines...) Expand all
153 {UINT, kWebMIdMinCache}, 154 {UINT, kWebMIdMinCache},
154 {UINT, kWebMIdMaxCache}, 155 {UINT, kWebMIdMaxCache},
155 {UINT, kWebMIdDefaultDuration}, 156 {UINT, kWebMIdDefaultDuration},
156 {FLOAT, kWebMIdTrackTimecodeScale}, 157 {FLOAT, kWebMIdTrackTimecodeScale},
157 {UINT, kWebMIdMaxBlockAdditionId}, 158 {UINT, kWebMIdMaxBlockAdditionId},
158 {STRING, kWebMIdName}, 159 {STRING, kWebMIdName},
159 {STRING, kWebMIdLanguage}, 160 {STRING, kWebMIdLanguage},
160 {STRING, kWebMIdCodecID}, 161 {STRING, kWebMIdCodecID},
161 {BINARY, kWebMIdCodecPrivate}, 162 {BINARY, kWebMIdCodecPrivate},
162 {STRING, kWebMIdCodecName}, 163 {STRING, kWebMIdCodecName},
164 {UINT, kWebMIdSeekPreRoll},
fgalligan1 2013/08/26 21:10:06 These should be switched according to the spec lay
vignesh 2013/08/26 21:44:23 Done.
165 {UINT, kWebMIdCodecDelay},
163 {UINT, kWebMIdAttachmentLink}, 166 {UINT, kWebMIdAttachmentLink},
164 {UINT, kWebMIdCodecDecodeAll}, 167 {UINT, kWebMIdCodecDecodeAll},
165 {UINT, kWebMIdTrackOverlay}, 168 {UINT, kWebMIdTrackOverlay},
166 {LIST, kWebMIdTrackTranslate}, 169 {LIST, kWebMIdTrackTranslate},
167 {LIST, kWebMIdVideo}, 170 {LIST, kWebMIdVideo},
168 {LIST, kWebMIdAudio}, 171 {LIST, kWebMIdAudio},
169 {LIST, kWebMIdTrackOperation}, 172 {LIST, kWebMIdTrackOperation},
170 {LIST, kWebMIdContentEncodings}, 173 {LIST, kWebMIdContentEncodings},
171 }; 174 };
172 175
(...skipping 761 matching lines...) Expand 10 before | Expand all | Expand 10 after
934 if (kSegmentIds[i].id_ == id_b) 937 if (kSegmentIds[i].id_ == id_b)
935 return true; 938 return true;
936 } 939 }
937 } 940 }
938 941
939 // kWebMIdSegment siblings. 942 // kWebMIdSegment siblings.
940 return ((id_b == kWebMIdSegment) || (id_b == kWebMIdEBMLHeader)); 943 return ((id_b == kWebMIdSegment) || (id_b == kWebMIdEBMLHeader));
941 } 944 }
942 945
943 } // namespace media 946 } // namespace media
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698