Android图片转base64加密在其它平台显示

一、前言

有时候传递给后台图片的话需要用base64进行加密,然后在其它平台显示。正常来说直接使用base64加密的内容是没法展示的,除非知道图片格式啥的,或者加上前缀,因为通常来说Android自己加密自己解密,所以也不太需要做这个操作。这里将完整流程进行记录,达到跨端端目的。涉及到其它文件流加密的话也可以参考这种方式。

二、前缀问题

倘若直接想用base64进行保存的话,需要在加密完的字符串前面添加前缀,根据不同的格式有以下两种
text.jpg

data:image/jpeg;base64,

text.png

data:image/png;base64,

下面列出一个完整的加密字符串

data:image/jpeg;base64,/9j/4AAQSkZJRgABAQAAAQABAAD/4gIoSUNDX1BST0ZJTEUAAQEAAAIYAAAAAAIQAABtbnRyUkdCIFhZWiAAAAAAAAAAAAAAAABhY3NwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAQAA9tYAAQAAAADTLQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAlkZXNjAAAA8AAAAHRyWFlaAAABZAAAABRnWFlaAAABeAAAABRiWFlaAAABjAAAABRyVFJDAAABoAAAAChnVFJDAAABoAAAAChiVFJDAAABoAAAACh3dHB0AAAByAAAABRjcHJ0AAAB3AAAADxtbHVjAAAAAAAAAAEAAAAMZW5VUwAAAFgAAAAcAHMAUgBHAEIAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFhZWiAAAAAAAABvogAAOPUAAAOQWFlaIAAAAAAAAGKZAAC3hQAAGNpYWVogAAAAAAAAJKAAAA+EAAC2z3BhcmEAAAAAAAQAAAACZmYAAPKnAAANWQAAE9AAAApbAAAAAAAAAABYWVogAAAAAAAA9tYAAQAAAADTLW1sdWMAAAAAAAAAAQAAAAxlblVTAAAAIAAAABwARwBvAG8AZwBsAGUAIABJAG4AYwAuACAAMgAwADEANv/bAEMAE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=

测试网址
https://www.qtool.net/picconvert
http://www.atoolbox.net/Tool.php?Id=1024
http://www.jsons.cn/img2base64/

三、详细代码

下面是一个将一个drawable图片转换为base64的代码

// data:image/png;base64,
// data:image/jpeg;base64,
    val base64Png = "data:image/png;base64,"
    val base64Jpeg = "data:image/jpeg;base64,"
    private fun loadBase64(){
        val bitmap = loadResourceByDrawable()
        var base64 = base64Jpeg + bitmapToBase64(bitmap)
        base64 = URLEncoder.encode(base64,Charsets.UTF_8.toString())//需要这个处理,否则网络传输中有些字符会被过滤掉
        lifecycleScope.launch(Dispatchers.IO){
            Log.e("YM---->","--->base64:${base64}")
            saveLog(base64)
        }
    }

    //加载资源
    private fun loadResourceByDrawable(): Bitmap{
        val drawable = ContextCompat.getDrawable(this,R.mipmap.test)
        val bitmapDrawable = drawable as BitmapDrawable
        return bitmapDrawable.bitmap
    }

    /*
     * bitmap转base64
     * */
    private fun bitmapToBase64(bitmap: Bitmap?): String {
        var result: String? = null
        var baos: ByteArrayOutputStream? = null
        try {
            if (bitmap != null) {
                baos = ByteArrayOutputStream()
                bitmap.compress(Bitmap.CompressFormat.JPEG, 50, baos)
                baos.flush()
                baos.close()
                val bitmapBytes: ByteArray = baos.toByteArray()
//                result = Base64.encodeToString(bitmapBytes, Base64.DEFAULT)
                result = Base64.encodeToString(bitmapBytes, Base64.NO_WRAP)
            }
        } catch (e: IOException) {
            e.printStackTrace()
        } finally {
            try {
                if (baos != null) {
                    baos.flush()
                    baos.close()
                }
            } catch (e: IOException) {
                e.printStackTrace()
            }
        }
        return result ?: "没有内容"
    }
    /*end*/


    //保存base64到本地文件中
    fun saveLog(base64Content: String){
        val logPath = Environment.getExternalStorageDirectory().absolutePath + File.separator + "保存图片base64编码.txt"
        val file = File(logPath)
        if (file.exists()){
            file.delete()
        }
        file.createNewFile()
        val fos = FileOutputStream(file)
        fos.write(base64Content.toByteArray())
        fos.flush()
        fos.close()
    }

不过我的需求是将截图传给后端,所以在上述代码基础上需要添加下面代码

	// 开始截屏
    private fun startCapture(){
        val bitmap = screenshotView()
        val base64 = bitmapToBase64(bitmap)
        lifecycleScope.launch(Dispatchers.IO){
            Log.e("YM---->","--->base64:${base64}")
            saveLog(base64)
        }
    }
    
    private fun screenshotView(): Bitmap {
        val view: View = window.decorView
        // view.setDrawingCacheEnabled(true); // 设置缓存,可用于实时截图
        val bitmap =
            Bitmap.createBitmap(view.width, view.height, Bitmap.Config.ARGB_8888)
        val canvas = Canvas(bitmap)
        view.draw(canvas)
        // view.setDrawingCacheEnabled(false); // 清空缓存,可用于实时截图
        return bitmap
    }

由于base64的字符串太长,控制台显示不完,所以里面有个代码是将日志保存到本地saveLog()。以供查阅。

你可能感兴趣的:(Android,android)