Java BufferedImage from Byte Array getBufferedImage(byte[] imageBytes)

Here you can find the source of getBufferedImage(byte[] imageBytes)

Description

get Buffered Image

License

Apache License

Declaration

public static BufferedImage getBufferedImage(byte[] imageBytes) throws IOException 

Method Source Code


//package com.java2s;
//License from project: Apache License 

import javax.imageio.ImageIO;

import java.awt.image.BufferedImage;
import java.io.ByteArrayInputStream;

import java.io.IOException;

public class Main {
    public static BufferedImage getBufferedImage(byte[] imageBytes) throws IOException {
        ByteArrayInputStream input = new ByteArrayInputStream(imageBytes);
        return ImageIO.read(input);
    }//from  w ww . j  av a2s.  c  om
}

Related

  1. fromByteArray(byte[] data)
  2. fromByteArray(byte[] imagebytes)
  3. fromByteIntensity(BufferedImage image, byte[] bytes)
  4. fromIntIntensityScaled(int width, int height, int[] data)
  5. fromIntRGB(BufferedImage image, int[] rgb)
  6. getImage(byte[] bytes)
  7. getImage(byte[] imageBytes)
  8. getImage(byte[] imageBytes)