[android-developers] Cannot cast from Bitmap to byte[]

2010-04-05 Thread Pinheiro
I'm trying to draw an image downloaded from the web but keep getting the error Cannot cast from Bitmap to byte[]. Here's the code snippet: BufferedInputStream bis = new BufferedInputStream(somethingdownloaded); DataInputStream dis = new DataInputStream(bis); Bitmap image;

Re: [android-developers] Cannot cast from Bitmap to byte[]

2010-04-05 Thread Mark Murphy
I'm trying to draw an image downloaded from the web but keep getting the error Cannot cast from Bitmap to byte[]. Here's the code snippet: BufferedInputStream bis = new BufferedInputStream(somethingdownloaded); DataInputStream dis = new DataInputStream(bis);

Re: [android-developers] Cannot cast from Bitmap to byte[]

2010-04-05 Thread Abdul Mateen
Hi, This is not possible. fairly you can either use Bitmap bitmap; bitmap.compress function to get the bytes to the buffer or you can use getInt(). On Mon, Apr 5, 2010 at 4:54 PM, Pinheiro rui.c.pinhe...@gmail.com wrote: I'm trying to draw an image downloaded from the web but keep getting the