Android encoding/decoding issues
<p>Need your help again.I am getting byte[] from onPreviewFrame(byte[] data, Camera arg1).Now i am transferring each frame through TCP to my System and then write a JPG file with that byte[].But when i open this JPG file it says that invalid JPG file.Moreover,when i send the same byte [] from PictureCallback jpegCallback = new PictureCallback() method and then write a JPG file on my PC ,it works fine.</p>

<p>I know its a kind of encoding issue,actually byte[] which i get from onPreviewFrame is byte array of compressed image data.</p>

<p>I can only transfer this byte array of compressed image data through TCP from my Phone to PC.But i want to decode this data once i get this on PC.Can you guys please help me how should i proceed.</p>

<p>I would be very grateful for any kind of help.</p>

<p>Best regards,
ZAI</p>
