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

Side by Side Diff: media/base/mime_util_internal.h

Issue 1897363004: Reland of Implement support for vp9 in ISO-BMFF (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 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 unified diff | Download patch
« no previous file with comments | « media/base/key_systems.cc ('k') | media/base/mime_util_internal.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2012 The Chromium Authors. All rights reserved. 1 // Copyright 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 #ifndef MEDIA_BASE_MIME_UTIL_INTERNAL_H_ 5 #ifndef MEDIA_BASE_MIME_UTIL_INTERNAL_H_
6 #define MEDIA_BASE_MIME_UTIL_INTERNAL_H_ 6 #define MEDIA_BASE_MIME_UTIL_INTERNAL_H_
7 7
8 #include <map> 8 #include <map>
9 #include <string> 9 #include <string>
10 #include <vector> 10 #include <vector>
(...skipping 93 matching lines...) Expand 10 before | Expand all | Expand 10 after
104 // IsNotSupported is returned if |mime_type_lower_case| is not supported or at 104 // IsNotSupported is returned if |mime_type_lower_case| is not supported or at
105 // least one is not supported in |mime_type_lower_case|. |is_encrypted| means 105 // least one is not supported in |mime_type_lower_case|. |is_encrypted| means
106 // the codec will be used with encrypted blocks. 106 // the codec will be used with encrypted blocks.
107 SupportsType AreSupportedCodecs(const CodecSet& supported_codecs, 107 SupportsType AreSupportedCodecs(const CodecSet& supported_codecs,
108 const std::vector<std::string>& codecs, 108 const std::vector<std::string>& codecs,
109 const std::string& mime_type_lower_case, 109 const std::string& mime_type_lower_case,
110 bool is_encrypted) const; 110 bool is_encrypted) const;
111 111
112 // Converts a codec ID into an Codec enum value and indicates 112 // Converts a codec ID into an Codec enum value and indicates
113 // whether the conversion was ambiguous. 113 // whether the conversion was ambiguous.
114 // Returns true if this method was able to map |codec_id| to a specific 114 // Returns true if this method was able to map |codec_id| with
115 // Codec enum value. |codec| and |is_ambiguous| are only valid if true 115 // |mime_type_lower_case| to a specific Codec enum value. |codec| and
116 // is returned. Otherwise their value is undefined after the call. 116 // |is_ambiguous| are only valid if true is returned. Otherwise their value is
117 // undefined after the call.
117 // |is_ambiguous| is true if |codec_id| did not have enough information to 118 // |is_ambiguous| is true if |codec_id| did not have enough information to
118 // unambiguously determine the proper Codec enum value. If |is_ambiguous| 119 // unambiguously determine the proper Codec enum value. If |is_ambiguous|
119 // is true |codec| contains the best guess for the intended Codec enum value. 120 // is true |codec| contains the best guess for the intended Codec enum value.
120 // |is_encrypted| means the codec will be used with encrypted blocks. 121 // |is_encrypted| means the codec will be used with encrypted blocks.
121 bool StringToCodec(const std::string& codec_id, 122 bool StringToCodec(const std::string& mime_type_lower_case,
123 const std::string& codec_id,
122 Codec* codec, 124 Codec* codec,
123 bool* is_ambiguous, 125 bool* is_ambiguous,
124 bool is_encrypted) const; 126 bool is_encrypted) const;
125 127
126 // Returns true if |codec| is supported when contained in 128 // Returns true if |codec| is supported when contained in
127 // |mime_type_lower_case|. Note: This method will always return false for 129 // |mime_type_lower_case|. Note: This method will always return false for
128 // proprietary codecs if |allow_proprietary_codecs_| is set to false. 130 // proprietary codecs if |allow_proprietary_codecs_| is set to false.
129 // |is_encrypted| means the codec will be used with encrypted blocks. 131 // |is_encrypted| means the codec will be used with encrypted blocks.
130 bool IsCodecSupported(Codec codec, 132 bool IsCodecSupported(Codec codec,
131 const std::string& mime_type_lower_case, 133 const std::string& mime_type_lower_case,
(...skipping 30 matching lines...) Expand all
162 // Lookup table for string compare based string -> Codec mappings. 164 // Lookup table for string compare based string -> Codec mappings.
163 StringToCodecMappings string_to_codec_map_; 165 StringToCodecMappings string_to_codec_map_;
164 166
165 DISALLOW_COPY_AND_ASSIGN(MimeUtil); 167 DISALLOW_COPY_AND_ASSIGN(MimeUtil);
166 }; 168 };
167 169
168 } // namespace internal 170 } // namespace internal
169 } // namespace media 171 } // namespace media
170 172
171 #endif // MEDIA_BASE_MIME_UTIL_INTERNAL_H_ 173 #endif // MEDIA_BASE_MIME_UTIL_INTERNAL_H_
OLDNEW
« no previous file with comments | « media/base/key_systems.cc ('k') | media/base/mime_util_internal.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698