Android applications is sending images to perl script
ByteArrayOutputStream byteArrayBitmapStream = new ByteArrayOutputStrea
byte b = byteArrayBitmapStream.toByteArray();
and they are putting this in a string and send it to the script.
Here is the perl part i get this binary file.
if ( open ( PICTF,"> smepath/file.jpeg" ) )
print PICTF $contentpic;
my ($x, $y, $info) = imgsize("somepath/file.jpeg");
The $info yell there is no such known file format.
So i checked the binary code that app sends me.
I saw it is JFIF and this is JPEG.
Any suggestions what i might do to fix this ?
I want to save it to JPEG.
When i dump the binary code to .txt and change it to .jpeg image is not shown.
What should i do i am using IMAGER module.
P.S. Not the image is the problem i tried with LWP and it made it binary and i've saved it. The problem comes from JAVA.