1<?xml version="1.0" encoding="utf-8"?> 2<!-- Copyright (C) 2010 The Android Open Source Project 3 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--> 16<!DOCTYPE MediaSettings [ 17<!ELEMENT MediaSettings (CamcorderProfiles, 18 EncoderOutputFileFormat+, 19 VideoEncoderCap+, 20 AudioEncoderCap+, 21 VideoDecoderCap, 22 AudioDecoderCap)> 23<!ELEMENT CamcorderProfiles (EncoderProfile+, ImageEncoding+, ImageDecoding, Camera)> 24<!ATTLIST CamcorderProfiles cameraId (0|1) #REQUIRED> 25<!ELEMENT EncoderProfile (Video, Audio)> 26<!ATTLIST EncoderProfile quality (high|low) #REQUIRED> 27<!ATTLIST EncoderProfile fileFormat (mp4|3gp) #REQUIRED> 28<!ATTLIST EncoderProfile duration (30|60) #REQUIRED> 29<!ELEMENT Video EMPTY> 30<!ATTLIST Video codec (h264|h263|m4v) #REQUIRED> 31<!ATTLIST Video bitRate CDATA #REQUIRED> 32<!ATTLIST Video width CDATA #REQUIRED> 33<!ATTLIST Video height CDATA #REQUIRED> 34<!ATTLIST Video frameRate CDATA #REQUIRED> 35<!ELEMENT Audio EMPTY> 36<!ATTLIST Audio codec (amrnb|amrwb|aac) #REQUIRED> 37<!ATTLIST Audio bitRate CDATA #REQUIRED> 38<!ATTLIST Audio sampleRate CDATA #REQUIRED> 39<!ATTLIST Audio channels (1|2) #REQUIRED> 40<!ELEMENT ImageEncoding EMPTY> 41<!ATTLIST ImageEncoding quality (90|80|70|60|50|40) #REQUIRED> 42<!ELEMENT ImageDecoding EMPTY> 43<!ATTLIST ImageDecoding memCap CDATA #REQUIRED> 44<!ELEMENT Camera EMPTY> 45<!ATTLIST Camera previewFrameRate CDATA #REQUIRED> 46<!ELEMENT EncoderOutputFileFormat EMPTY> 47<!ATTLIST EncoderOutputFileFormat name (mp4|3gp) #REQUIRED> 48<!ELEMENT VideoEncoderCap EMPTY> 49<!ATTLIST VideoEncoderCap name (h264|h263|m4v|wmv) #REQUIRED> 50<!ATTLIST VideoEncoderCap enabled (true|false) #REQUIRED> 51<!ATTLIST VideoEncoderCap minBitRate CDATA #REQUIRED> 52<!ATTLIST VideoEncoderCap maxBitRate CDATA #REQUIRED> 53<!ATTLIST VideoEncoderCap minFrameWidth CDATA #REQUIRED> 54<!ATTLIST VideoEncoderCap maxFrameWidth CDATA #REQUIRED> 55<!ATTLIST VideoEncoderCap minFrameHeight CDATA #REQUIRED> 56<!ATTLIST VideoEncoderCap maxFrameHeight CDATA #REQUIRED> 57<!ATTLIST VideoEncoderCap minFrameRate CDATA #REQUIRED> 58<!ATTLIST VideoEncoderCap maxFrameRate CDATA #REQUIRED> 59<!ELEMENT AudioEncoderCap EMPTY> 60<!ATTLIST AudioEncoderCap name (amrnb|amrwb|aac|heaac|aaceld) #REQUIRED> 61<!ATTLIST AudioEncoderCap enabled (true|false) #REQUIRED> 62<!ATTLIST AudioEncoderCap minBitRate CDATA #REQUIRED> 63<!ATTLIST AudioEncoderCap maxBitRate CDATA #REQUIRED> 64<!ATTLIST AudioEncoderCap minSampleRate CDATA #REQUIRED> 65<!ATTLIST AudioEncoderCap maxSampleRate CDATA #REQUIRED> 66<!ATTLIST AudioEncoderCap minChannels (1|2) #REQUIRED> 67<!ATTLIST AudioEncoderCap maxChannels (1|2) #REQUIRED> 68<!ELEMENT VideoDecoderCap EMPTY> 69<!ATTLIST VideoDecoderCap name (wmv) #REQUIRED> 70<!ATTLIST VideoDecoderCap enabled (true|false) #REQUIRED> 71<!ELEMENT AudioDecoderCap EMPTY> 72<!ATTLIST AudioDecoderCap name (wma) #REQUIRED> 73<!ATTLIST AudioDecoderCap enabled (true|false) #REQUIRED> 74]> 75<!-- 76 This file is used to declare the multimedia profiles and capabilities 77 on an android-powered device. 78--> 79<MediaSettings> 80 <!-- Each camcorder profile defines a set of predefined configuration parameters --> 81 <CamcorderProfiles cameraId="0"> 82 83 <EncoderProfile quality="low" fileFormat="3gp" duration="30"> 84 <Video codec="h263" 85 bitRate="128000" 86 width="176" 87 height="144" 88 frameRate="15" /> 89 90 <Audio codec="amrnb" 91 bitRate="12200" 92 sampleRate="8000" 93 channels="1" /> 94 </EncoderProfile> 95 96 <EncoderProfile quality="high" fileFormat="mp4" duration="60"> 97 <Video codec="h264" 98 bitRate="15000000" 99 width="1920" 100 height="1080" 101 frameRate="30" /> 102 103 <Audio codec="aac" 104 bitRate="192000" 105 sampleRate="48000" 106 channels="2" /> 107 </EncoderProfile> 108 109 <EncoderProfile quality="qcif" fileFormat="3gp" duration="30"> 110 <Video codec="h263" 111 bitRate="128000" 112 width="176" 113 height="144" 114 frameRate="15" /> 115 116 <Audio codec="amrnb" 117 bitRate="12200" 118 sampleRate="8000" 119 channels="1" /> 120 </EncoderProfile> 121 122 <EncoderProfile quality="cif" fileFormat="3gp" duration="30"> 123 <Video codec="h264" 124 bitRate="640000" 125 width="352" 126 height="288" 127 frameRate="30" /> 128 129 <Audio codec="amrnb" 130 bitRate="12200" 131 sampleRate="8000" 132 channels="1" /> 133 </EncoderProfile> 134 135 <EncoderProfile quality="qvga" fileFormat="3gp" duration="30"> 136 <Video codec="h264" 137 bitRate="640000" 138 width="320" 139 height="240" 140 frameRate="30" /> 141 142 <Audio codec="aac" 143 bitRate="128000" 144 sampleRate="48000" 145 channels="2" /> 146 147 </EncoderProfile> 148 149 <EncoderProfile quality="480p" fileFormat="mp4" duration="60"> 150 <Video codec="h264" 151 bitRate="3000000" 152 width="720" 153 height="480" 154 frameRate="30" /> 155 156 <Audio codec="aac" 157 bitRate="128000" 158 sampleRate="48000" 159 channels="2" /> 160 161 </EncoderProfile> 162 163 <EncoderProfile quality="720p" fileFormat="mp4" duration="60"> 164 <Video codec="h264" 165 bitRate="8000000" 166 width="1280" 167 height="720" 168 frameRate="30" /> 169 170 <Audio codec="aac" 171 bitRate="192000" 172 sampleRate="48000" 173 channels="2" /> 174 </EncoderProfile> 175 176 <EncoderProfile quality="1080p" fileFormat="mp4" duration="60"> 177 <Video codec="h264" 178 bitRate="15000000" 179 width="1920" 180 height="1080" 181 frameRate="30" /> 182 183 <Audio codec="aac" 184 bitRate="192000" 185 sampleRate="48000" 186 channels="2" /> 187 </EncoderProfile> 188 189 <EncoderProfile quality="timelapselow" fileFormat="3gp" duration="30"> 190 <Video codec="h263" 191 bitRate="128000" 192 width="176" 193 height="144" 194 frameRate="15" /> 195 196 <Audio codec="amrnb" 197 bitRate="12200" 198 sampleRate="8000" 199 channels="1" /> 200 </EncoderProfile> 201 202 <EncoderProfile quality="timelapsehigh" fileFormat="mp4" duration="30"> 203 <Video codec="h264" 204 bitRate="15000000" 205 width="1920" 206 height="1080" 207 frameRate="30" /> 208 209 <Audio codec="aac" 210 bitRate="192000" 211 sampleRate="48000" 212 channels="2" /> 213 </EncoderProfile> 214 215 <EncoderProfile quality="timelapseqcif" fileFormat="3gp" duration="30"> 216 <Video codec="h263" 217 bitRate="128000" 218 width="176" 219 height="144" 220 frameRate="15" /> 221 222 <Audio codec="amrnb" 223 bitRate="12200" 224 sampleRate="8000" 225 channels="1" /> 226 </EncoderProfile> 227 228 <EncoderProfile quality="timelapsecif" fileFormat="3gp" duration="30"> 229 <Video codec="h264" 230 bitRate="640000" 231 width="352" 232 height="288" 233 frameRate="30" /> 234 235 <Audio codec="amrnb" 236 bitRate="12200" 237 sampleRate="8000" 238 channels="1" /> 239 </EncoderProfile> 240 241 <EncoderProfile quality="timelapse480p" fileFormat="mp4" duration="30"> 242 <Video codec="h264" 243 bitRate="3000000" 244 width="720" 245 height="480" 246 frameRate="30" /> 247 248 <Audio codec="amrnb" 249 bitRate="12200" 250 sampleRate="8000" 251 channels="1" /> 252 </EncoderProfile> 253 254 <EncoderProfile quality="timelapse720p" fileFormat="mp4" duration="30"> 255 <Video codec="h264" 256 bitRate="8000000" 257 width="1280" 258 height="720" 259 frameRate="30" /> 260 261 <Audio codec="aac" 262 bitRate="192000" 263 sampleRate="48000" 264 channels="2" /> 265 </EncoderProfile> 266 267 <EncoderProfile quality="timelapse1080p" fileFormat="mp4" duration="30"> 268 <Video codec="h264" 269 bitRate="15000000" 270 width="1920" 271 height="1080" 272 frameRate="30" /> 273 274 <Audio codec="aac" 275 bitRate="192000" 276 sampleRate="48000" 277 channels="2" /> 278 </EncoderProfile> 279 280 <ImageEncoding quality="90" /> 281 <ImageEncoding quality="80" /> 282 <ImageEncoding quality="70" /> 283 <ImageDecoding memCap="20000000" /> 284 285 <Camera previewFrameRate="30" /> 286 287 </CamcorderProfiles> 288 289 <CamcorderProfiles cameraId="1"> 290 <EncoderProfile quality="high" fileFormat="mp4" duration="60"> 291 <Video codec="h264" 292 bitRate="15000000" 293 width="1920" 294 height="1080" 295 frameRate="30" /> 296 297 <Audio codec="aac" 298 bitRate="192000" 299 sampleRate="48000" 300 channels="2" /> 301 </EncoderProfile> 302 303 <EncoderProfile quality="low" fileFormat="3gp" duration="30"> 304 <Video codec="h263" 305 bitRate="128000" 306 width="176" 307 height="144" 308 frameRate="15" /> 309 310 <Audio codec="amrnb" 311 bitRate="12200" 312 sampleRate="8000" 313 channels="1" /> 314 </EncoderProfile> 315 316 <EncoderProfile quality="qcif" fileFormat="3gp" duration="30"> 317 <Video codec="h263" 318 bitRate="128000" 319 width="176" 320 height="144" 321 frameRate="15" /> 322 323 <Audio codec="amrnb" 324 bitRate="12200" 325 sampleRate="8000" 326 channels="1" /> 327 </EncoderProfile> 328 329 <EncoderProfile quality="qvga" fileFormat="3gp" duration="30"> 330 <Video codec="h264" 331 bitRate="640000" 332 width="320" 333 height="240" 334 frameRate="30" /> 335 336 <Audio codec="aac" 337 bitRate="128000" 338 sampleRate="48000" 339 channels="2" /> 340 341 </EncoderProfile> 342 343 <EncoderProfile quality="cif" fileFormat="3gp" duration="30"> 344 <Video codec="h264" 345 bitRate="640000" 346 width="352" 347 height="288" 348 frameRate="30" /> 349 350 <Audio codec="amrnb" 351 bitRate="12200" 352 sampleRate="8000" 353 channels="1" /> 354 </EncoderProfile> 355 356 <EncoderProfile quality="480p" fileFormat="mp4" duration="60"> 357 <Video codec="h264" 358 bitRate="3000000" 359 width="720" 360 height="480" 361 frameRate="30" /> 362 363 <Audio codec="aac" 364 bitRate="128000" 365 sampleRate="48000" 366 channels="2" /> 367 368 </EncoderProfile> 369 370 <EncoderProfile quality="720p" fileFormat="mp4" duration="60"> 371 <Video codec="h264" 372 bitRate="3000000" 373 width="1280" 374 height="720" 375 frameRate="30" /> 376 377 <Audio codec="aac" 378 bitRate="192000" 379 sampleRate="48000" 380 channels="2" /> 381 </EncoderProfile> 382 383 <EncoderProfile quality="1080p" fileFormat="mp4" duration="60"> 384 <Video codec="h264" 385 bitRate="15000000" 386 width="1920" 387 height="1080" 388 frameRate="30" /> 389 390 <Audio codec="aac" 391 bitRate="192000" 392 sampleRate="48000" 393 channels="2" /> 394 </EncoderProfile> 395 396 <EncoderProfile quality="timelapselow" fileFormat="3gp" duration="30"> 397 <Video codec="h263" 398 bitRate="128000" 399 width="176" 400 height="144" 401 frameRate="15" /> 402 403 <Audio codec="amrnb" 404 bitRate="12200" 405 sampleRate="8000" 406 channels="1" /> 407 </EncoderProfile> 408 409 <EncoderProfile quality="timelapsehigh" fileFormat="mp4" duration="30"> 410 <Video codec="h264" 411 bitRate="3000000" 412 width="1920" 413 height="1080" 414 frameRate="30" /> 415 416 <Audio codec="aac" 417 bitRate="192000" 418 sampleRate="48000" 419 channels="2" /> 420 </EncoderProfile> 421 422 <EncoderProfile quality="timelapseqcif" fileFormat="3gp" duration="30"> 423 <Video codec="h263" 424 bitRate="128000" 425 width="176" 426 height="144" 427 frameRate="15" /> 428 429 <Audio codec="amrnb" 430 bitRate="12200" 431 sampleRate="8000" 432 channels="1" /> 433 </EncoderProfile> 434 435 <EncoderProfile quality="timelapsecif" fileFormat="3gp" duration="30"> 436 <Video codec="h264" 437 bitRate="640000" 438 width="352" 439 height="288" 440 frameRate="30" /> 441 442 <Audio codec="amrnb" 443 bitRate="12200" 444 sampleRate="8000" 445 channels="1" /> 446 </EncoderProfile> 447 448 <EncoderProfile quality="timelapse480p" fileFormat="mp4" duration="30"> 449 <Video codec="h264" 450 bitRate="3000000" 451 width="720" 452 height="480" 453 frameRate="30" /> 454 455 <Audio codec="amrnb" 456 bitRate="12200" 457 sampleRate="8000" 458 channels="1" /> 459 </EncoderProfile> 460 461 <EncoderProfile quality="timelapse720p" fileFormat="mp4" duration="30"> 462 <Video codec="h264" 463 bitRate="3000000" 464 width="1280" 465 height="720" 466 frameRate="30" /> 467 468 <Audio codec="aac" 469 bitRate="192000" 470 sampleRate="48000" 471 channels="2" /> 472 </EncoderProfile> 473 474 <EncoderProfile quality="timelapse1080p" fileFormat="mp4" duration="30"> 475 <Video codec="h264" 476 bitRate="3000000" 477 width="1920" 478 height="1080" 479 frameRate="30" /> 480 481 <Audio codec="aac" 482 bitRate="192000" 483 sampleRate="48000" 484 channels="2" /> 485 </EncoderProfile> 486 487 <ImageEncoding quality="90" /> 488 <ImageEncoding quality="80" /> 489 <ImageEncoding quality="70" /> 490 <ImageDecoding memCap="20000000" /> 491 492 <Camera previewFrameRate="30" /> 493 494 </CamcorderProfiles> 495 496 497 <EncoderOutputFileFormat name="3gp" /> 498 <EncoderOutputFileFormat name="mp4" /> 499 500 <!-- 501 If a codec is not enabled, it is invisible to the applications 502 In other words, the applications won't be able to use the codec 503 or query the capabilities of the codec at all if it is disabled 504 --> 505 <VideoEncoderCap name="h264" enabled="true" 506 minBitRate="64000" maxBitRate="15000000" 507 minFrameWidth="176" maxFrameWidth="1920" 508 minFrameHeight="144" maxFrameHeight="1080" 509 minFrameRate="15" maxFrameRate="60" /> 510 511 <VideoEncoderCap name="h263" enabled="true" 512 minBitRate="64000" maxBitRate="2000000" 513 minFrameWidth="176" maxFrameWidth="720" 514 minFrameHeight="144" maxFrameHeight="480" 515 minFrameRate="15" maxFrameRate="30" /> 516 517 <VideoEncoderCap name="m4v" enabled="true" 518 minBitRate="64000" maxBitRate="8000000" 519 minFrameWidth="176" maxFrameWidth="720" 520 minFrameHeight="144" maxFrameHeight="480" 521 minFrameRate="15" maxFrameRate="30" /> 522 523 <AudioEncoderCap name="aac" enabled="true" 524 minBitRate="32000" maxBitRate="320000" 525 minSampleRate="8000" maxSampleRate="48000" 526 minChannels="1" maxChannels="2" /> 527 528 <AudioEncoderCap name="amrwb" enabled="true" 529 minBitRate="6600" maxBitRate="23850" 530 minSampleRate="16000" maxSampleRate="16000" 531 minChannels="1" maxChannels="1" /> 532 533 <AudioEncoderCap name="amrnb" enabled="true" 534 minBitRate="4750" maxBitRate="12200" 535 minSampleRate="8000" maxSampleRate="8000" 536 minChannels="1" maxChannels="1" /> 537 538 <AudioEncoderCap name="aac" enabled="true" 539 minBitRate="32000" maxBitRate="320000" 540 minSampleRate="8000" maxSampleRate="48000" 541 minChannels="1" maxChannels="1" /> 542 543 <AudioEncoderCap name="heaac" enabled="true" 544 minBitRate="8000" maxBitRate="64000" 545 minSampleRate="16000" maxSampleRate="48000" 546 minChannels="1" maxChannels="2" /> 547 548 <AudioEncoderCap name="aaceld" enabled="true" 549 minBitRate="16000" maxBitRate="192000" 550 minSampleRate="8000" maxSampleRate="48000" 551 minChannels="1" maxChannels="2" /> 552 553 <!-- 554 FIXME: 555 We do not check decoder capabilities at present 556 At present, we only check whether windows media is visible 557 for TEST applications. For other applications, we do 558 not perform any checks at all. 559 --> 560 <VideoDecoderCap name="wmv" enabled="true"/> 561 <AudioDecoderCap name="wma" enabled="true"/> 562</MediaSettings> 563