summaryrefslogtreecommitdiffstats
path: root/graphics
diff options
context:
space:
mode:
authorNarayan Kamath <narayan@google.com>2014-01-16 07:31:53 -0800
committerAndroid Git Automerger <android-git-automerger@android.com>2014-01-16 07:31:53 -0800
commit8796ab7f22d3e9f5b85571e8851851c023416f96 (patch)
tree294ac74f02915dcfdf68842e24d32d54cc551743 /graphics
parent947d88a0eacafb2e5ec5ce5eaaae8be32ecb9aa9 (diff)
parentbb35356dc05632664e1d65588c9d0570c185280b (diff)
downloadframeworks_base-8796ab7f22d3e9f5b85571e8851851c023416f96.zip
frameworks_base-8796ab7f22d3e9f5b85571e8851851c023416f96.tar.gz
frameworks_base-8796ab7f22d3e9f5b85571e8851851c023416f96.tar.bz2
am bb35356d: Merge changes Id54087dd,I946325e4,I2a2b2e68
* commit 'bb35356dc05632664e1d65588c9d0570c185280b': AArch64: Use long for pointers in BitmapRegionDecoder AArch64: Use long for pointers in Movie class AArch64: Add AssetInputStream.getNativeAsset
Diffstat (limited to 'graphics')
-rw-r--r--graphics/java/android/graphics/BitmapRegionDecoder.java16
-rw-r--r--graphics/java/android/graphics/Movie.java10
2 files changed, 13 insertions, 13 deletions
diff --git a/graphics/java/android/graphics/BitmapRegionDecoder.java b/graphics/java/android/graphics/BitmapRegionDecoder.java
index 3a99977..e689b08 100644
--- a/graphics/java/android/graphics/BitmapRegionDecoder.java
+++ b/graphics/java/android/graphics/BitmapRegionDecoder.java
@@ -33,7 +33,7 @@ import java.io.InputStream;
*
*/
public final class BitmapRegionDecoder {
- private int mNativeBitmapRegionDecoder;
+ private long mNativeBitmapRegionDecoder;
private boolean mRecycled;
// ensures that the native decoder object exists and that only one decode can
// occur at a time.
@@ -114,7 +114,7 @@ public final class BitmapRegionDecoder {
boolean isShareable) throws IOException {
if (is instanceof AssetManager.AssetInputStream) {
return nativeNewInstance(
- ((AssetManager.AssetInputStream) is).getAssetInt(),
+ ((AssetManager.AssetInputStream) is).getNativeAsset(),
isShareable);
} else {
// pass some temp storage down to the native code. 1024 is made up,
@@ -165,7 +165,7 @@ public final class BitmapRegionDecoder {
This can be called from JNI code.
*/
- private BitmapRegionDecoder(int decoder) {
+ private BitmapRegionDecoder(long decoder) {
mNativeBitmapRegionDecoder = decoder;
mRecycled = false;
}
@@ -254,12 +254,12 @@ public final class BitmapRegionDecoder {
}
}
- private static native Bitmap nativeDecodeRegion(int lbm,
+ private static native Bitmap nativeDecodeRegion(long lbm,
int start_x, int start_y, int width, int height,
BitmapFactory.Options options);
- private static native int nativeGetWidth(int lbm);
- private static native int nativeGetHeight(int lbm);
- private static native void nativeClean(int lbm);
+ private static native int nativeGetWidth(long lbm);
+ private static native int nativeGetHeight(long lbm);
+ private static native void nativeClean(long lbm);
private static native BitmapRegionDecoder nativeNewInstance(
byte[] data, int offset, int length, boolean isShareable);
@@ -268,5 +268,5 @@ public final class BitmapRegionDecoder {
private static native BitmapRegionDecoder nativeNewInstance(
InputStream is, byte[] storage, boolean isShareable);
private static native BitmapRegionDecoder nativeNewInstance(
- int asset, boolean isShareable);
+ long asset, boolean isShareable);
}
diff --git a/graphics/java/android/graphics/Movie.java b/graphics/java/android/graphics/Movie.java
index 9419faf..b0a4553 100644
--- a/graphics/java/android/graphics/Movie.java
+++ b/graphics/java/android/graphics/Movie.java
@@ -21,9 +21,9 @@ import java.io.InputStream;
import java.io.FileInputStream;
public class Movie {
- private final int mNativeMovie;
+ private final long mNativeMovie;
- private Movie(int nativeMovie) {
+ private Movie(long nativeMovie) {
if (nativeMovie == 0) {
throw new RuntimeException("native movie creation failed");
}
@@ -48,19 +48,19 @@ public class Movie {
return null;
}
if (is instanceof AssetManager.AssetInputStream) {
- final int asset = ((AssetManager.AssetInputStream) is).getAssetInt();
+ final long asset = ((AssetManager.AssetInputStream) is).getNativeAsset();
return nativeDecodeAsset(asset);
}
return nativeDecodeStream(is);
}
- private static native Movie nativeDecodeAsset(int asset);
+ private static native Movie nativeDecodeAsset(long asset);
private static native Movie nativeDecodeStream(InputStream is);
public static native Movie decodeByteArray(byte[] data, int offset,
int length);
- private static native void nativeDestructor(int nativeMovie);
+ private static native void nativeDestructor(long nativeMovie);
public static Movie decodeFile(String pathName) {
InputStream is;