Answers for "outputstream to image js example"

0

outputstream to image js example

<img src="data:image/png;base64,[ENCODED STRING GOES HERE]">
Posted by: Guest on August-07-2020
0

outputstream to image js example

// Java side
BufferedImage image = ImageIO.read(new File("helloworld.png"));
ByteArrayOutputStream outputStream = new ByteArrayOutputStream();
ImageIO.write(image, "png", outputStream);
String encodedImage = Base64.encode(outputStream.toByteArray());

// js side
<img src="data:image/png;base64,[ENCODED STRING GOES HERE]">
Posted by: Guest on August-07-2020

Code answers related to "outputstream to image js example"

Code answers related to "Javascript"

Browse Popular Code Answers by Language