Camera2: Fix wrong index in ColorSpaceTransform

Bug: 15309870
Change-Id: I89a043a005435695ac8649e20d4e0e58d0f62bc7
This commit is contained in:
Yin-Chia Yeh
2014-05-28 09:12:03 -07:00
committed by Yin-chia Yeh
parent b9a65de1f7
commit 884cddcdf4

View File

@@ -139,8 +139,8 @@ public final class ColorSpaceTransform {
throw new IllegalArgumentException("row out of range");
}
int numerator = mElements[row * ROWS * RATIONAL_SIZE + column + OFFSET_NUMERATOR];
int denominator = mElements[row * ROWS * RATIONAL_SIZE + column + OFFSET_DENOMINATOR];
int numerator = mElements[(row * COLUMNS + column) * RATIONAL_SIZE + OFFSET_NUMERATOR];
int denominator = mElements[(row * COLUMNS + column) * RATIONAL_SIZE + OFFSET_DENOMINATOR];
return new Rational(numerator, denominator);
}