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