display.captureScreen () always takes portrait picture even in landscape mode

We have tried using display.captureScreen () on our iPad application and even when we are in landscape mode it only takes the image in portrait.

PLEASE NOTE: In the simulator it will show correctly, however on the actual device (iPad) it will always take the photo in portrait.

There was an old bug posted:

#928 display.captureScreen and display.save not working when apps launch in landscape”

That has been marked fixed, but of course it is not. [import]uid: 11554 topic_id: 3937 reply_id: 303937[/import]

local screenCap = display.captureScreen( true )

Causes the simulator to hang. [import]uid: 9371 topic_id: 3937 reply_id: 11983[/import]

I haven’t had this issue but will try it out today. On my machine previously it has opened a dialog box allowing me to choose a place to save the screenshot on my hard-drive. [import]uid: 11554 topic_id: 3937 reply_id: 11984[/import]

My bad, was not removing and nil’ing the display object returned. Sorry.

But where on an Android device is the image created exactly? [import]uid: 9371 topic_id: 3937 reply_id: 12070[/import]

I tried today the same… display.captureScreen( true ) on a landscape application this is always save as portrait. such a bad result. :frowning:

Is there a way to have it fixed? [import]uid: 10160 topic_id: 3937 reply_id: 12698[/import]

Send a bug report to Ansca [import]uid: 9371 topic_id: 3937 reply_id: 12700[/import]

Yes I was told that if I removed the sizing information from my config.lua file it would but alas it still does not. At least not on the iPad.

Here is the config.lua file I am using:

[lua]application =
{
content =
{
fps = 60,

antialias = false,
},
}[/lua]

Ansca??? Are there any workarounds for this? [import]uid: 11554 topic_id: 3937 reply_id: 12710[/import]

Please try this with the new Corona.243 release. There are fixes for iPad image capture that work if you don’t specify height and width in your config.lua file (dynamic scaling).

-Tom [import]uid: 7559 topic_id: 3937 reply_id: 13393[/import]

It still doesn’t appear to be fixed. I’ve pasted my code below. I love the new features but I really think that fixing some of these fairly significant bugs first, THEN worrying about adding in new features might really be the way to go. Thank you.

[lua]application =
{
content =
{
fps = 60,

antialias = false,
},
}[/lua]

[lua]settings =
{
orientation =
{
default = “portrait”,

supported =
{
“landscapeLeft”, “landscapeRight”, “portrait”, “portraitUpsideDown”,
},
},

iphone =
{
plist =
{
UIPrerenderedIcon = true,
UIStatusBarHidden = true,
CFBundleIconFile = “Icon-72.png”
},
},
}[/lua]

[import]uid: 11554 topic_id: 3937 reply_id: 13505[/import]

Ditto. It doesn’t save the image in landscape either – IE, even rotating the displayGroup and then taking the screencapture still produces a landscape image in portrait mode.

What’s up folks ? [import]uid: 13859 topic_id: 3937 reply_id: 19192[/import]

Any movement on this topic? I am working on an app that will only run in landscape mode, and generating a proper landscape screengrab is an essential component. Can anybody suggest and workaround code to get us through until Ansca can release a bugfix? [import]uid: 27636 topic_id: 3937 reply_id: 23486[/import]

Nope. No movement or response from Ansca.

I’ve spent hours trying to find a work around but there isn’t one. There’s only 1 function to save an image to the user’s camera roll… and unfortunately, it does NOT work in landscape mode on the device – (though it does still seem to work in the simulator which is likely throwing off Ansca’s attempts to view this bug, IMHO.) [import]uid: 13859 topic_id: 3937 reply_id: 23503[/import]

Ken

I fixed one bug related to camera and looking at fixing this. Sorry if you don’t get a proper response from us. But we are aware, I fixed one bug, now looking into fixing this.

C. [import]uid: 24 topic_id: 3937 reply_id: 23550[/import]

Thanks, Carlos. I very much appreciate the quick reply, and your efforts to fix this bug! [import]uid: 27636 topic_id: 3937 reply_id: 23572[/import]

Thanks Carlos … I appreciate the response. Knowing it’s on the list and being looked at is a good thing. :wink: I hate bug posts and feel your codicial-pain.

Best,
~~Kenn [import]uid: 13859 topic_id: 3937 reply_id: 23577[/import]

thanks.

talk about really ugly code YIKES !

c. [import]uid: 24 topic_id: 3937 reply_id: 23579[/import]

Carlos,

As long as you are knee deep in this spaghetti, can you make sure the display.captureScreen function works correctly when viewed on different devices? I’m trying to implement simple scene transitions using this function, but if I specify a particular resolution in config. to take advantage of dynamic scaling, the captured screen will be the wrong size on certain devices. So, for example, on an iPad the captured screen will be a little too small in the width and/or height if my “native” resolution is iPhone 3.

Also, I’ve noticed different behavior with this function on the simulator vs. actual devices. So don’t think you’ve killed a bug until you’ve actually tested it on a few different real, honest-to-god devices!

Thanks for caring. [import]uid: 9422 topic_id: 3937 reply_id: 23593[/import]

One other thing I’m not sure was mentioned, in portrait upside down mode the picture is taken umm… not upside down??? Anyway I’ve kind of hacked it in my app by inverting the y scale of the clip when i show the user their captured clip however when they look in their gallery the image is inverted. [import]uid: 11554 topic_id: 3937 reply_id: 23595[/import]

Hello,

I was just wondering if this issue has been fixed? This functionality is one of the last pieces of the puzzle for my app.

I am very close to getting my subscription; however, I was curious to know if there might be an update to the public release any time soon? I only ask because there is a general comment regarding this bug fix within the Daily Build Summary: Builds 333 to 337: Week of 3/27/2011. But it does not give any specifics as to the fix in regards to the iPad.

Thanks
Rob
[import]uid: 16527 topic_id: 3937 reply_id: 31130[/import]

Rob

It has been fixed for all devices including IPad.

C [import]uid: 24 topic_id: 3937 reply_id: 31133[/import]