am c60a5d78: am 3ed95fe2: Merge "media: add support for 160-byte image info in MediaCodec" into lmp-mr1-dev

* commit 'c60a5d781a5e9f927d5971f2127cada9d213a128':
  media: add support for 160-byte image info in MediaCodec
This commit is contained in:
Lajos Molnar
2014-11-26 12:02:50 +00:00
committed by Android Git Automerger

View File

@@ -1784,11 +1784,11 @@ final public class MediaCodec {
mYOffset = yOffset;
mInfo = info;
// read media-info. the size of media info can be 80 or 156 depending on
// read media-info. the size of media info can be 80 or 156/160 depending on
// whether it was created on a 32- or 64-bit process. See MediaImage
if (info.remaining() == 80 || info.remaining() == 156) {
boolean sizeIsLong = info.remaining() == 156;
int type = info.getInt();
if (info.remaining() == 80 || info.remaining() == 156 || info.remaining() == 160) {
boolean sizeIsLong = info.remaining() != 80;
int type = readInt(info, info.remaining() == 160);
if (type != TYPE_YUV) {
throw new UnsupportedOperationException("unsupported type: " + type);
}