Call glTexSubImage2D in native code for ImageTexture.Tile

This commit is contained in:
seven332 committed 2016-03-05 16:34:59 +08:00
1 parent e80df262a3
commit 92fc062ca0
17 files changed
+268 -99

No files matched your search

+11 -3
View File
@@ -66,13 +66,18 @@ public class Image {
return nativeIsCompleted(mNativePtr, mFormat);
}
public boolean render(int srcX, int srcY, Bitmap dst, int dstX, int dstY,
public void render(int srcX, int srcY, Bitmap dst, int dstX, int dstY,
int width, int height, boolean fillBlank, int defaultColor) {
checkRecycled();
return nativeRender(mNativePtr, mFormat, srcX, srcY, dst, dstX, dstY,
nativeRender(mNativePtr, mFormat, srcX, srcY, dst, dstX, dstY,
width, height, fillBlank, defaultColor);
}
public void texImage(boolean init, int tileType, int offsetX, int offsetY) {
checkRecycled();
nativeTexImage(mNativePtr, mFormat, init, tileType, offsetX, offsetY);
}
public void advance() {
checkRecycled();
nativeAdvance(mNativePtr, mFormat);
@@ -118,10 +123,13 @@ public class Image {
private static native boolean nativeIsCompleted(long nativePtr, int format);
private static native boolean nativeRender(long nativePtr, int format,
private static native void nativeRender(long nativePtr, int format,
int srcX, int srcY, Bitmap dst, int dstX, int dstY,
int width, int height, boolean fillBlank, int defaultColor);
private static native void nativeTexImage(long nativePtr, int format,
boolean init, int tileType, int offsetX, int offsetY);
private static native void nativeAdvance(long nativePtr, int format);
private static native int nativeGetDelay(long nativePtr, int format);