Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- BufferedImage image = new BufferedImage(Application.getPanelSize().width, Application.getPanelSize().height, BufferedImage.TYPE_INT_RGB);
- paintImage(image.createGraphics());
- ByteArrayOutputStream baos = new ByteArrayOutputStream();
- ImageIO.write(image, "png", baos);
- byte[] byteArray = baos.toByteArray();
- String base64 = new sun.misc.BASE64Encoder().encode(byteArray);
- log(base64);
Add Comment
Please, Sign In to add comment