Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 63d8edcc authored by Sally Qi's avatar Sally Qi
Browse files

[Lut API] LUT java interface update.

- LutProperties#getSize return integer instead.

Bug: 349667978
Test: builds
Flag: NONE new added apis are all hidden now
Change-Id: I0913bb1b40b6e395d06f389ef6aaab96bf742b68
parent 480405c5
Loading
Loading
Loading
Loading
+3 −3
Original line number Diff line number Diff line
@@ -30,7 +30,7 @@ import java.lang.annotation.RetentionPolicy;
 */
public final class LutProperties {
    private final @Dimension int mDimension;
    private final long mSize;
    private final int mSize;
    private final @SamplingKey int[] mSamplingKeys;

    @Retention(RetentionPolicy.SOURCE)
@@ -68,7 +68,7 @@ public final class LutProperties {
    /**
     * @return the size of the Lut.
     */
    public long getSize() {
    public int getSize() {
        return mSize;
    }

@@ -83,7 +83,7 @@ public final class LutProperties {
    }

    /* use in the native code */
    private LutProperties(@Dimension int dimension, long size, @SamplingKey int[] samplingKeys) {
    private LutProperties(@Dimension int dimension, int size, @SamplingKey int[] samplingKeys) {
        if (dimension != ONE_DIMENSION || dimension != THREE_DIMENSION) {
            throw new IllegalArgumentException("The dimension is either 1 or 3!");
        }
+1 −1
Original line number Diff line number Diff line
@@ -213,6 +213,6 @@ int register_android_hardware_OverlayProperties(JNIEnv* env) {
    clazz = FindClassOrDie(env, "android/hardware/LutProperties");
    gLutPropertiesClassInfo.clazz = MakeGlobalRefOrDie(env, clazz);
    gLutPropertiesClassInfo.ctor =
            GetMethodIDOrDie(env, gLutPropertiesClassInfo.clazz, "<init>", "(IJ[I)V");
            GetMethodIDOrDie(env, gLutPropertiesClassInfo.clazz, "<init>", "(II[I)V");
    return err;
}