blob: 4aafc64935c593e4e9d694d4889c069cf9928f8e [file] [log] [blame]
Praveen Chavane3674af2016-03-18 12:27:29 -07001<?xml version="1.0" encoding="utf-8" ?>
2<!-- Copyright 2016 The Android Open Source Project
Praveen Chavane4d7c6b2013-11-06 17:52:03 -08003
4 Licensed under the Apache License, Version 2.0 (the "License");
5 you may not use this file except in compliance with the License.
6 You may obtain a copy of the License at
7
8 http://www.apache.org/licenses/LICENSE-2.0
9
10 Unless required by applicable law or agreed to in writing, software
11 distributed under the License is distributed on an "AS IS" BASIS,
12 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 See the License for the specific language governing permissions and
14 limitations under the License.
15-->
Shalaj Jainf1840dd2015-02-27 15:39:27 -080016
Praveen Chavan33532eb2015-08-07 17:03:00 -070017<!--
18<!DOCTYPE MediaCodecs [
19<!ELEMENT Include EMPTY>
20<!ATTLIST Include href CDATA #REQUIRED>
21<!ELEMENT MediaCodecs (Decoders|Encoders|Include)*>
22<!ELEMENT Decoders (MediaCodec|Include)*>
23<!ELEMENT Encoders (MediaCodec|Include)*>
24<!ELEMENT MediaCodec (Type|Quirk|Include)*>
25<!ATTLIST MediaCodec name CDATA #REQUIRED>
26<!ATTLIST MediaCodec type CDATA>
27<!ELEMENT Type EMPTY>
28<!ATTLIST Type name CDATA #REQUIRED>
29<!ELEMENT Quirk EMPTY>
30<!ATTLIST Quirk name CDATA #REQUIRED>
31]>
32
33There's a simple and a complex syntax to declare the availability of a
34media codec:
35
36A codec that properly follows the OpenMax spec and therefore doesn't have any
37quirks and that only supports a single content type can be declared like so:
38
39 <MediaCodec name="OMX.foo.bar" type="something/interesting" />
40
41If a codec has quirks OR supports multiple content types, the following syntax
42can be used:
43
44 <MediaCodec name="OMX.foo.bar" >
45 <Type name="something/interesting" />
46 <Type name="something/else" />
47 ...
48 <Quirk name="requires-allocate-on-input-ports" />
49 <Quirk name="requires-allocate-on-output-ports" />
50 <Quirk name="output-buffers-are-unreadable" />
51 </MediaCodec>
52
53Only the three quirks included above are recognized at this point:
54
55"requires-allocate-on-input-ports"
56 must be advertised if the component does not properly support specification
57 of input buffers using the OMX_UseBuffer(...) API but instead requires
58 OMX_AllocateBuffer to be used.
59
60"requires-allocate-on-output-ports"
61 must be advertised if the component does not properly support specification
62 of output buffers using the OMX_UseBuffer(...) API but instead requires
63 OMX_AllocateBuffer to be used.
64
65"output-buffers-are-unreadable"
66 must be advertised if the emitted output buffers of a decoder component
67 are not readable, i.e. use a custom format even though abusing one of
68 the official OMX colorspace constants.
69 Clients of such decoders will not be able to access the decoded data,
70 naturally making the component much less useful. The only use for
71 a component with this quirk is to render the output to the screen.
72 Audio decoders MUST NOT advertise this quirk.
73 Video decoders that advertise this quirk must be accompanied by a
74 corresponding color space converter for thumbnail extraction,
75 matching surfaceflinger support that can render the custom format to
76 a texture and possibly other code, so just DON'T USE THIS QUIRK.
77
78
79-->
80
81<!--
Shivaprasad Hongalc35aec52015-09-02 16:54:03 -070082 8996 Decoder capabilities
83 __________________________________________________________________
84 | Codec | W H fps Mbps MB/s | Secure-dec |
85 |__________|_________________________________________|____________|
86 | h264 | 3840 2160 60 100 1958400 | Y |
87 | | (4096) (2160) (56) (100) | |
88 | hevc | 3840 2160 60 100 1958400 | Y |
89 | | (4096) (2160) (56) (100) | |
90 | mpeg4 | 1920 1088 60 60 489600 | N |
Shivaprasad Hongalc35aec52015-09-02 16:54:03 -070091 | vp8 | 3840 2160 30 20 979200 | N |
Shalaj Jain0f3f18f2015-08-25 19:30:27 -070092 | vp9 | 3840 2160 30 20 979200 | Y |
Shivaprasad Hongalc35aec52015-09-02 16:54:03 -070093 | h263 | 864 480 30 2 48600 | N |
Shivaprasad Hongalc35aec52015-09-02 16:54:03 -070094 |__________|_________________________________________|____________|
95
96
97 8996 Encoder capabilities
98 ______________________________________________________
99 | Codec | W H fps Mbps MB/s |
100 |__________|_________________________________________|
101 | h264 | 3840 2160 30 100 979200 |
102 | hevc | 3840 2160 30 100 979200 |
103 | mpeg4 | 1920 1088 60 60 489600 |
104 | vp8 | 3840 2160 30 20 979200 |
105 | h263 | 864 480 30 2 48600 |
106 |__________|_________________________________________|
Praveen Chavan33532eb2015-08-07 17:03:00 -0700107-->
108
Shalaj Jainf1840dd2015-02-27 15:39:27 -0800109<MediaCodecs>
110 <Include href="media_codecs_google_audio.xml" />
111 <Include href="media_codecs_google_telephony.xml" />
Shivaprasad Hongalab2ada92015-08-20 19:52:35 -0700112 <Settings>
113 <Setting name="max-video-encoder-input-buffers" value="11" />
114 </Settings>
Praveen Chavane4d7c6b2013-11-06 17:52:03 -0800115 <Encoders>
Praveen Chavane4d7c6b2013-11-06 17:52:03 -0800116 <MediaCodec name="OMX.qcom.video.encoder.mpeg4" type="video/mp4v-es" >
117 <Quirk name="requires-allocate-on-input-ports" />
Praveen Chavan33532eb2015-08-07 17:03:00 -0700118 <Quirk name="requires-allocate-on-output-ports" />
Praveen Chavane4d7c6b2013-11-06 17:52:03 -0800119 <Quirk name="requires-loaded-to-idle-after-allocation"/>
Shalaj Jainf1840dd2015-02-27 15:39:27 -0800120 <Limit name="size" min="96x64" max="1920x1088" />
121 <Limit name="alignment" value="2x2" />
122 <Limit name="block-size" value="16x16" />
123 <Limit name="blocks-per-second" min="1" max="489600" />
124 <Limit name="bitrate" range="1-60000000" />
Shivaprasad Hongald3365332015-09-15 14:01:54 -0700125 <Limit name="frame-rate" range="1-240" />
Shivaprasad Hongalab2ada92015-08-20 19:52:35 -0700126 <Limit name="concurrent-instances" max="16" />
Praveen Chavane4d7c6b2013-11-06 17:52:03 -0800127 </MediaCodec>
128 <MediaCodec name="OMX.qcom.video.encoder.h263" type="video/3gpp" >
129 <Quirk name="requires-allocate-on-input-ports" />
Praveen Chavan33532eb2015-08-07 17:03:00 -0700130 <Quirk name="requires-allocate-on-output-ports" />
131 <Quirk name="requires-loaded-to-idle-after-allocation" />
132 <Limit name="size" min="96x64" max="864x480" />
Shalaj Jainf1840dd2015-02-27 15:39:27 -0800133 <Limit name="alignment" value="2x2" />
Praveen Chavan33532eb2015-08-07 17:03:00 -0700134 <Limit name="block-size" value="16x16" />
135 <Limit name="blocks-per-second" min="1" max="48600" />
136 <Limit name="bitrate" range="1-2000000" />
Shivaprasad Hongald3365332015-09-15 14:01:54 -0700137 <Limit name="frame-rate" range="1-240" />
Shivaprasad Hongalab2ada92015-08-20 19:52:35 -0700138 <Limit name="concurrent-instances" max="16" />
Praveen Chavane4d7c6b2013-11-06 17:52:03 -0800139 </MediaCodec>
Praveen Chavane3674af2016-03-18 12:27:29 -0700140 <MediaCodec name="OMX.qcom.video.encoder.avc" type="video/avc" >
141 <Quirk name="requires-allocate-on-input-ports" />
142 <Quirk name="requires-allocate-on-output-ports" />
143 <Quirk name="requires-loaded-to-idle-after-allocation" />
144 <Limit name="size" min="96x64" max="4096x2160" />
145 <Limit name="alignment" value="2x2" />
146 <Limit name="block-size" value="16x16" />
147 <Limit name="blocks-per-second" min="1" max="979200" />
148 <Limit name="bitrate" range="1-100000000" />
149 <Limit name="frame-rate" range="1-240" />
150 <Limit name="concurrent-instances" max="16" />
151 </MediaCodec>
Praveen Chavan33532eb2015-08-07 17:03:00 -0700152 <MediaCodec name="OMX.qcom.video.encoder.vp8" type="video/x-vnd.on2.vp8" >
Praveen Chavan285bd5d2014-03-11 10:22:26 -0700153 <Quirk name="requires-allocate-on-input-ports" />
Praveen Chavan33532eb2015-08-07 17:03:00 -0700154 <Quirk name="requires-allocate-on-output-ports" />
155 <Quirk name="requires-loaded-to-idle-after-allocation" />
Shalaj Jainf1840dd2015-02-27 15:39:27 -0800156 <Limit name="size" min="96x64" max="3840x2160" />
157 <Limit name="alignment" value="2x2" />
158 <Limit name="block-size" value="16x16" />
Shivaprasad Hongalc35aec52015-09-02 16:54:03 -0700159 <Limit name="blocks-per-second" min="1" max="979200" />
Praveen Chavan33532eb2015-08-07 17:03:00 -0700160 <Limit name="bitrate" range="1-20000000" />
Shivaprasad Hongald3365332015-09-15 14:01:54 -0700161 <Limit name="frame-rate" range="1-240" />
Shivaprasad Hongalab2ada92015-08-20 19:52:35 -0700162 <Limit name="concurrent-instances" max="16" />
Praveen Chavan33532eb2015-08-07 17:03:00 -0700163 </MediaCodec>
164 <MediaCodec name="OMX.qcom.video.encoder.hevc" type="video/hevc" >
165 <Quirk name="requires-allocate-on-input-ports" />
166 <Quirk name="requires-allocate-on-output-ports" />
167 <Quirk name="requires-loaded-to-idle-after-allocation" />
Praveen Chavane3674af2016-03-18 12:27:29 -0700168 <Limit name="size" min="176x64" max="4096x2160" />
Praveen Chavan33532eb2015-08-07 17:03:00 -0700169 <Limit name="alignment" value="2x2" />
170 <Limit name="block-size" value="16x16" />
Shivaprasad Hongalc35aec52015-09-02 16:54:03 -0700171 <Limit name="blocks-per-second" min="1" max="979200" />
Shalaj Jainf1840dd2015-02-27 15:39:27 -0800172 <Limit name="bitrate" range="1-100000000" />
Shivaprasad Hongald3365332015-09-15 14:01:54 -0700173 <Limit name="frame-rate" range="1-240" />
Shivaprasad Hongalab2ada92015-08-20 19:52:35 -0700174 <Limit name="concurrent-instances" max="16" />
Shalaj Jainf1840dd2015-02-27 15:39:27 -0800175 </MediaCodec>
Praveen Chavane4d7c6b2013-11-06 17:52:03 -0800176 </Encoders>
177 <Decoders>
Praveen Chavane4d7c6b2013-11-06 17:52:03 -0800178 <MediaCodec name="OMX.qcom.video.decoder.avc" type="video/avc" >
179 <Quirk name="requires-allocate-on-input-ports" />
Praveen Chavan33532eb2015-08-07 17:03:00 -0700180 <Quirk name="requires-allocate-on-output-ports" />
181 <Limit name="size" min="64x64" max="4096x2160" />
Shalaj Jainf1840dd2015-02-27 15:39:27 -0800182 <Limit name="alignment" value="2x2" />
183 <Limit name="block-size" value="16x16" />
Shivaprasad Hongalc35aec52015-09-02 16:54:03 -0700184 <Limit name="blocks-per-second" min="1" max="1958400" />
Shalaj Jainf1840dd2015-02-27 15:39:27 -0800185 <Limit name="bitrate" range="1-100000000" />
186 <Feature name="adaptive-playback" />
Shivaprasad Hongalab2ada92015-08-20 19:52:35 -0700187 <Limit name="concurrent-instances" max="16" />
Shalaj Jainf1840dd2015-02-27 15:39:27 -0800188 </MediaCodec>
189 <MediaCodec name="OMX.qcom.video.decoder.avc.secure" type="video/avc" >
190 <Quirk name="requires-allocate-on-input-ports" />
Praveen Chavan33532eb2015-08-07 17:03:00 -0700191 <Quirk name="requires-allocate-on-output-ports" />
192 <Limit name="size" min="64x64" max="4096x2160" />
Shalaj Jainf1840dd2015-02-27 15:39:27 -0800193 <Limit name="alignment" value="2x2" />
194 <Limit name="block-size" value="16x16" />
Shivaprasad Hongalc35aec52015-09-02 16:54:03 -0700195 <Limit name="blocks-per-second" min="1" max="1958400" />
Shalaj Jainf1840dd2015-02-27 15:39:27 -0800196 <Limit name="bitrate" range="1-100000000" />
197 <Feature name="adaptive-playback" />
198 <Feature name="secure-playback" required="true" />
Shalaj Jain600e1d62015-11-24 17:34:56 -0800199 <Limit name="concurrent-instances" max="6" />
Shalaj Jainf1840dd2015-02-27 15:39:27 -0800200 </MediaCodec>
201 <MediaCodec name="OMX.qcom.video.decoder.mpeg4" type="video/mp4v-es" >
202 <Quirk name="requires-allocate-on-input-ports" />
Praveen Chavane3674af2016-03-18 12:27:29 -0700203 <Quirk name="requires-allocate-on-output-ports" />
Shalaj Jainf1840dd2015-02-27 15:39:27 -0800204 <Limit name="size" min="64x64" max="1920x1088" />
205 <Limit name="alignment" value="2x2" />
206 <Limit name="block-size" value="16x16" />
207 <Limit name="blocks-per-second" min="1" max="489600" />
208 <Limit name="bitrate" range="1-60000000" />
209 <Feature name="adaptive-playback" />
Shivaprasad Hongalab2ada92015-08-20 19:52:35 -0700210 <Limit name="concurrent-instances" max="16" />
Praveen Chavane4d7c6b2013-11-06 17:52:03 -0800211 </MediaCodec>
Praveen Chavane4d7c6b2013-11-06 17:52:03 -0800212 <MediaCodec name="OMX.qcom.video.decoder.h263" type="video/3gpp" >
213 <Quirk name="requires-allocate-on-input-ports" />
Praveen Chavan33532eb2015-08-07 17:03:00 -0700214 <Quirk name="requires-allocate-on-output-ports" />
Shalaj Jainf1840dd2015-02-27 15:39:27 -0800215 <Limit name="size" min="64x64" max="864x480" />
216 <Limit name="alignment" value="2x2" />
217 <Limit name="block-size" value="16x16" />
218 <Limit name="blocks-per-second" min="1" max="489600" />
219 <Limit name="bitrate" range="1-2000000" />
Shalaj Jainf1840dd2015-02-27 15:39:27 -0800220 <Feature name="adaptive-playback" />
Shivaprasad Hongalab2ada92015-08-20 19:52:35 -0700221 <Limit name="concurrent-instances" max="16" />
Praveen Chavane4d7c6b2013-11-06 17:52:03 -0800222 </MediaCodec>
223 <MediaCodec name="OMX.qcom.video.decoder.vp8" type="video/x-vnd.on2.vp8" >
224 <Quirk name="requires-allocate-on-input-ports" />
225 <Quirk name="requires-allocate-on-output-ports" />
Shalaj Jainf1840dd2015-02-27 15:39:27 -0800226 <Limit name="size" min="64x64" max="3840x2160" />
227 <Limit name="alignment" value="2x2" />
228 <Limit name="block-size" value="16x16" />
Shivaprasad Hongalc35aec52015-09-02 16:54:03 -0700229 <Limit name="blocks-per-second" min="1" max="979200" />
Shalaj Jainf1840dd2015-02-27 15:39:27 -0800230 <Limit name="bitrate" range="1-20000000" />
231 <Feature name="adaptive-playback" />
Shivaprasad Hongalab2ada92015-08-20 19:52:35 -0700232 <Limit name="concurrent-instances" max="16" />
Praveen Chavane4d7c6b2013-11-06 17:52:03 -0800233 </MediaCodec>
Praveen Chavanda239332016-03-18 12:45:26 -0700234 <MediaCodec name="OMX.qcom.video.decoder.vp9" type="video/x-vnd.on2.vp9" >
235 <Quirk name="requires-allocate-on-input-ports" />
236 <Quirk name="requires-allocate-on-output-ports" />
237 <Limit name="size" min="64x64" max="3840x2160" />
238 <Limit name="alignment" value="2x2" />
239 <Limit name="block-size" value="16x16" />
240 <Limit name="blocks-per-second" min="1" max="979200" />
241 <Limit name="bitrate" range="1-100000000" />
242 <Limit name="frame-rate" range="1-240" />
243 <Feature name="adaptive-playback" />
244 <Limit name="concurrent-instances" max="16" />
245 </MediaCodec>
Rohit Kulkarnib2e99f92016-06-10 15:19:50 -0700246 <MediaCodec name="OMX.qcom.video.decoder.vp9.secure" type="video/x-vnd.on2.vp9" >
247 <Quirk name="requires-allocate-on-input-ports" />
248 <Quirk name="requires-allocate-on-output-ports" />
249 <Limit name="size" min="64x64" max="3840x2160" />
250 <Limit name="alignment" value="2x2" />
251 <Limit name="block-size" value="16x16" />
252 <Limit name="blocks-per-second" min="1" max="979200" />
253 <Limit name="bitrate" range="1-100000000" />
254 <Feature name="adaptive-playback" />
255 <Feature name="secure-playback" required="true" />
256 <Limit name="concurrent-instances" max="6" />
257 </MediaCodec>
Praveen Chavane4d7c6b2013-11-06 17:52:03 -0800258 <MediaCodec name="OMX.qcom.video.decoder.hevc" type="video/hevc" >
259 <Quirk name="requires-allocate-on-input-ports" />
260 <Quirk name="requires-allocate-on-output-ports" />
Shalaj Jainf1840dd2015-02-27 15:39:27 -0800261 <Limit name="size" min="64x64" max="4096x2160" />
262 <Limit name="alignment" value="2x2" />
263 <Limit name="block-size" value="16x16" />
Shivaprasad Hongalc35aec52015-09-02 16:54:03 -0700264 <Limit name="blocks-per-second" min="1" max="1958400" />
Shalaj Jainf1840dd2015-02-27 15:39:27 -0800265 <Limit name="bitrate" range="1-100000000" />
266 <Feature name="adaptive-playback" />
Shivaprasad Hongalab2ada92015-08-20 19:52:35 -0700267 <Limit name="concurrent-instances" max="16" />
Praveen Chavane4d7c6b2013-11-06 17:52:03 -0800268 </MediaCodec>
Shalaj Jain3711bf72015-05-19 15:49:10 -0700269 <MediaCodec name="OMX.qcom.video.decoder.hevc.secure" type="video/hevc" >
270 <Quirk name="requires-allocate-on-input-ports" />
271 <Quirk name="requires-allocate-on-output-ports" />
272 <Limit name="size" min="64x64" max="4096x2160" />
273 <Limit name="alignment" value="2x2" />
274 <Limit name="block-size" value="16x16" />
Shivaprasad Hongalc35aec52015-09-02 16:54:03 -0700275 <Limit name="blocks-per-second" min="1" max="1958400" />
Shalaj Jain3711bf72015-05-19 15:49:10 -0700276 <Limit name="bitrate" range="1-100000000" />
277 <Feature name="adaptive-playback" />
278 <Feature name="secure-playback" required="true" />
Shalaj Jain600e1d62015-11-24 17:34:56 -0800279 <Limit name="concurrent-instances" max="6" />
Shalaj Jain3711bf72015-05-19 15:49:10 -0700280 </MediaCodec>
Praveen Chavane4d7c6b2013-11-06 17:52:03 -0800281 </Decoders>
Shalaj Jainf1840dd2015-02-27 15:39:27 -0800282 <Include href="media_codecs_google_video.xml" />
283</MediaCodecs>