类 ImageUtil
- java.lang.Object
-
- cn.authing.guard.util.ImageUtil
-
public class ImageUtil extends Object
-
-
字段概要
字段 修饰符和类型 字段 说明 static intSCREENSHOT_SIZEstatic intTHUMBNAIL_SIZE
-
构造器概要
构造器 构造器 说明 ImageUtil()
-
方法概要
所有方法 静态方法 具体方法 修饰符和类型 方法 说明 static BitmapgetScaledImage(Context context, Uri uri, int maxSize)static BitmapgetScreenshot(Context context, Uri uri)static BitmapgetThumbnail(Context context, Uri uri)static voidsaveImage(Context context, Bitmap toBitmap)保存图片到相册的方法static BitmapstringToBitmap(String url)base 64 图片转码
-
-
-
方法详细资料
-
getThumbnail
public static Bitmap getThumbnail(Context context, Uri uri) throws IOException
- 抛出:
IOException
-
getScreenshot
public static Bitmap getScreenshot(Context context, Uri uri) throws IOException
- 抛出:
IOException
-
getScaledImage
public static Bitmap getScaledImage(Context context, Uri uri, int maxSize) throws IOException
- 抛出:
IOException
-
-