am d39e19eb: am 351879df: Merge "Fix getBytesSize for YUV allocations."

* commit 'd39e19eb8af54683d03ae955a5a58fea48a58754':
  Fix getBytesSize for YUV allocations.
This commit is contained in:
Tim Murray
2014-03-07 01:34:55 +00:00
committed by Android Git Automerger

View File

@@ -223,6 +223,9 @@ public class Allocation extends BaseObj {
*
*/
public int getBytesSize() {
if (mType.mDimYuv != 0) {
return (int)Math.ceil(mType.getCount() * mType.getElement().getBytesSize() * 1.5);
}
return mType.getCount() * mType.getElement().getBytesSize();
}