Questions tagged «javax.imageio»

7
Java-从图像获取像素数组
我正在寻找从中获取像素数据(以表格形式int[][])的最快方法BufferedImage。我的目标是能够解决像素(x, y)从使用图像int[x][y]。我发现的所有方法都不这样做(大多数返回int[]s)。

13
如何使用Java获取图像的高度和宽度?
除了使用ImageIO.read来获取图像的高度和宽度外,还有其他方法吗? 因为我遇到了锁定线程的问题。 at com.sun.medialib.codec.jpeg.Decoder.njpeg_decode(Native Method) at com.sun.medialib.codec.jpeg.Decoder.decode(Decoder.java:87) at com.sun.media.imageioimpl.plugins.jpeg.CLibJPEGImageReader.decode(CLibJPEGImageReader.java:73) - locked <0xd96fb668> (a com.sun.media.imageioimpl.plugins.jpeg.CLibJPEGImageReader) at com.sun.media.imageioimpl.plugins.clib.CLibImageReader.getImage(CLibImageReader.java:320) - locked <0xd96fb668> (a com.sun.media.imageioimpl.plugins.jpeg.CLibJPEGImageReader) at com.sun.media.imageioimpl.plugins.clib.CLibImageReader.read(CLibImageReader.java:384) - locked <0xd96fb668> (a com.sun.media.imageioimpl.plugins.jpeg.CLibJPEGImageReader) at javax.imageio.ImageIO.read(ImageIO.java:1400) at javax.imageio.ImageIO.read(ImageIO.java:1322) 此错误仅在Sun应用服务器上发生,因此我怀疑这是Sun错误。
By using our site, you acknowledge that you have read and understand our Cookie Policy and Privacy Policy.
Licensed under cc by-sa 3.0 with attribution required.