display.capture not working on certain Android devices

I’m running into an issue where capturing to a local yields a blank image on devices. Particularly I’ve had it on a Kindle Fire. A tester also reported it on the Nexus 6. On the Nook instead of an empty image I get garbage from the most recent sprite sheet that was loaded.

My main test case has been the Kindle though, and using Corona 2015.2646 (2015.5.27). I found that if I set saveToPhotoLibrary to true, then the image would display. It almost seems like the extra time for it to save the image to storage (I see a bit of lag) does the trick for giving me a valid display object. I don’t want to save to the photo library as this is temp image.

Are there any known issues in this version of Corona regarding display.capture and these devices? I have a few other devices where this isn’t an issue such as the Samsung S3 and an Insignia Flex Elite.

i had a few problems with display.capture/display.save functions. if i remember well, i “resolved” then with timers. try to introduce some “lag” if that works.

I have tried experimenting with a bit of delay, as much as 3 seconds so far with no results.

What is strange is that I am working on an update to a game that was put out in late 2013, and in that version display.capture worked fine on those devices, and still does currently in the store versions. This leads me to believe something changed under the hood in Corona which now affects those devices. I haven’t yet tried a daily build but I may do that next to see if anything has changed.

Hello, Im thinking this is a bug of some sort… Why dont you try downgrading on the daily build? maybe a couple months back and see if that’ll help?..

I did try all the way back to the earliest version that will run on OS X Yosemite - CoronaSDK-2014.2438. Still had the issue.

I took a different approach, using display.save and then display.newImage. This gives it the necessary time to grab the image and load it back in to an object. That’ll work just fine for now.

Thanks for the input!

i had a few problems with display.capture/display.save functions. if i remember well, i “resolved” then with timers. try to introduce some “lag” if that works.

I have tried experimenting with a bit of delay, as much as 3 seconds so far with no results.

What is strange is that I am working on an update to a game that was put out in late 2013, and in that version display.capture worked fine on those devices, and still does currently in the store versions. This leads me to believe something changed under the hood in Corona which now affects those devices. I haven’t yet tried a daily build but I may do that next to see if anything has changed.

Hello, Im thinking this is a bug of some sort… Why dont you try downgrading on the daily build? maybe a couple months back and see if that’ll help?..

I did try all the way back to the earliest version that will run on OS X Yosemite - CoronaSDK-2014.2438. Still had the issue.

I took a different approach, using display.save and then display.newImage. This gives it the necessary time to grab the image and load it back in to an object. That’ll work just fine for now.

Thanks for the input!