I am trying to capture a picture from the Android camera - preferrably raw, but jpg ok - and then display it on the G1 screen. My problem is that only black frames are displayed. The preview does work.
This code works on the emulator, but displays a black frame on the G1 device. The emulator displays an interesting picture of the green android robot and a blackberry like phone. Here is the code I am using. I have tried many options for the Camera parameters including various PixelFormats and resolutions. In addition to the code below, I have tried various versions with BitmapDisplayables and ByteArrayInputStreams. Here is the code I am currently using to attempt to display the image: Camera.PictureCallback pictureCallback = new Camera.PictureCallback() { public void onPictureTaken(byte[] data, Camera camera) { Bitmap bm = BitmapFactory.decodeByteArray(data, 0, data.length); ImageView iv = new ImageView(cx); iv.setImageBitmap(bm); linearLayout.addView(iv); } }; Does anyone have any idea why this code is not working Thank you for any help you can offer. - Sincerely, David Manpearl --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~----------~----~----~----~------~----~------~--~---