public class JNI
extends java.lang.Object
构造器和说明 |
---|
JNI() |
限定符和类型 | 方法和说明 |
---|---|
static boolean |
bytesIsGif(byte[] bytes)
判断是否是gif
|
static void |
destroy(long ptr)
销毁
|
static boolean |
fileIsGif(java.lang.String path)
判断是否是gif
|
static int |
getCurrentFrame(long ptr)
获取当前帧位置
|
static void |
getFrame(long ptr,
int frame,
android.graphics.Bitmap bitmap)
获得指定帧图像
|
static int |
getFrameCount(long ptr)
获取帧数
|
static int |
getFrameDuration(long ptr)
获取当前帧间隔
|
static int |
getHeight(long ptr)
取得高度
|
static boolean |
getStrict(long ptr)
是否启用严格模式
|
static int |
getWidth(long ptr)
取得宽度
|
static void |
gotoFrame(long ptr,
int frame,
android.graphics.Bitmap bitmap)
跳到指定帧
|
static long |
openBytes(byte[] bytes)
通过byte数组打开 gif 图
|
static long |
openFile(java.lang.String path)
通过文件路径打开 gif 图
|
static void |
setFrame(long ptr,
int frame) |
static void |
setFrameDuration(long ptr,
int duration)
修改帧间隔
|
static void |
setStrict(long ptr,
boolean strict)
启用/停止严格模式
|
static int |
updateFrame(long ptr,
android.graphics.Bitmap bitmap)
更新一帧
|
public static long openFile(java.lang.String path)
path
- public static long openBytes(byte[] bytes)
bytes
- public static boolean fileIsGif(java.lang.String path)
path
- public static boolean bytesIsGif(byte[] bytes)
bytes
- public static int updateFrame(long ptr, android.graphics.Bitmap bitmap)
ptr
- bitmap
- public static int getWidth(long ptr)
ptr
- public static int getHeight(long ptr)
ptr
- public static int getFrameCount(long ptr)
ptr
- public static int getFrameDuration(long ptr)
ptr
- public static void setFrameDuration(long ptr, int duration)
ptr
- duration
- public static int getCurrentFrame(long ptr)
ptr
- public static void gotoFrame(long ptr, int frame, android.graphics.Bitmap bitmap)
ptr
- frame
- public static void getFrame(long ptr, int frame, android.graphics.Bitmap bitmap)
ptr
- frame
- public static void setFrame(long ptr, int frame)
public static void setStrict(long ptr, boolean strict)
ptr
- strict
- public static boolean getStrict(long ptr)
ptr
- public static void destroy(long ptr)
ptr
-