Agreed. I tossed out the manifest change as an idea just in case the
bug was somehow tied to dynamically setting full-screen mode.

If you think of it, write this up as an issue on http://b.android.com,
no so much for the bug itself (which is probably an HTC thing), but as
a CTS bug, since ideally the CTS would catch this sort of
compatibility flaw.

On Mon, Nov 15, 2010 at 2:38 AM, blindfold <seeingwithso...@gmail.com> wrote:
> Sounds like a G2/Android bug then, because still image results should
> always be totally unrelated to any (screen) layout settings. Only
> camera preview results can be linked to layout.
>
> On Nov 15, 1:26 am, Stephen Lebed <srle...@gmail.com> wrote:
>> It is a supported size on the g2.  I'm not specifying the size, its
>> the default res for the camera.
>>
>> It looks like part of the problem is with
>>
>> getWindow().setFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN,
>> WindowManager.LayoutParams.FLAG_FULLSCREEN);
>>
>> I use this in the onCreate method.  Again, I use this all the time,
>> but when I comment out this line, I can save uncorrupted images. I'm
>> still hunting for an answer.  It is related to my layout xml.
>>
>> On Nov 14, 12:53 pm, blindfold <seeingwithso...@gmail.com> wrote:
>>
>> > 2.592 x 1.952 looks like an unusual (unsupported) image size to me.
>> > Maybe try 2.592 x 1.944?
>>
>> > Regards
>>
>> > On Nov 14, 7:58 pm, Stephen Lebed <srle...@gmail.com> wrote:
>>
>> > > I can't figure out why I'm getting corrupted images when I save them
>> > > in my app.  In fact the thumbnail seems to be fine, but the actual
>> > > image is corrupted, as if the stride value is not being set
>> > > correctly.  The following is the code I'm using the save the image,
>> > > which is taken from other version of camera apps almost directly.  In
>> > > other apps it seems to be saving images without problem.  This is
>> > > called from a Camera.PictureCallback.onPictureTaken(byte[] data,
>> > > Camera camera)
>>
>> > > File filename = new File("Test_SnapShotK.jpg");
>> > > File exportDir = new File(Environment.getExternalStorageDirectory(),
>> > > "TestDir");
>>
>> > > if (!exportDir.exists()) {
>> > >         exportDir.mkdirs();
>> > >         Log.i(TAG, "making directory " + exportDir.toString());
>>
>> > > }
>>
>> > > File file = new File(exportDir, filename.getName());
>>
>> > > try {
>> > >         FileOutputStream fileOutputStream = new FileOutputStream(file);
>> > >         fileOutputStream.write(data);
>> > >         fileOutputStream.flush();
>> > >         fileOutputStream.close();
>>
>> > > } catch (IOException e) {
>>
>> > >         Log.e(TAG, e.getMessage(), e);
>>
>> > > }
>>
>> > > Since I can't attach the image I'm getting directly in this post, here
>> > > is a link to it.
>>
>> > >http://www.mechnology.com/Test_SnapShotK.jpg
>>
>> > > Has anyone else gotten this problem and have been able to resolve it.
>> > > I'm testing this on a G2 phone.  Any help is greatly appreciated.
>>
>> > > Stephen
>>
>>
>
> --
> 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
> android-developers+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en
>



-- 
Mark Murphy (a Commons Guy)
http://commonsware.com | http://github.com/commonsguy
http://commonsware.com/blog | http://twitter.com/commonsguy

Warescription: Three Android Books, Plus Updates, One Low Price!

-- 
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
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to