字节数组图像文件 [英] Byte Array to Image File
本文介绍了字节数组图像文件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我给Java中的一个byte []数组其中包含图像的字节数,我需要将其输出到图像。我怎么会去这样做呢?
由于大部分
解决方案
IMG的BufferedImage = ImageIO.read(新ByteArrayInputStream进行(字节));
I am given a byte[] array in Java which contains the bytes for an image, and I need to output it into an image. How would I go about doing this?
Much thanks
解决方案
BufferedImage img = ImageIO.read(new ByteArrayInputStream(bytes));
这篇关于字节数组图像文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文