LC 5.02 problem with "screen capture"

Want to talk about something that isn't covered by another category?

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller

Post Reply
shankez
Posts: 15
Joined: Sun Nov 20, 2011 3:25 pm

LC 5.02 problem with "screen capture"

Post by shankez » Thu Dec 15, 2011 1:12 am

Hello, hope this is the right place to have an answer from developers. There is a problem with screen capture command in new version 5.02, it returns a black screen on IOS, while in version 5.01 it works perfectly... I am doing some mistake in the use of the command ?
Thank anyone would help!
Antonio - Italy

Mark
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 5150
Joined: Thu Feb 23, 2006 9:24 pm
Contact:

Re: LC 5.02 problem with "screen capture"

Post by Mark » Thu Dec 15, 2011 6:09 pm

Post your script.
The biggest LiveCode group on Facebook: https://www.facebook.com/groups/livecode.developers
The book "Programming LiveCode for the Real Beginner"! Get it here! http://tinyurl.com/book-livecode

shankez
Posts: 15
Joined: Sun Nov 20, 2011 3:25 pm

Re: LC 5.02 problem with "screen capture"

Post by shankez » Fri Dec 16, 2011 7:06 pm

Hi Mark,
I think the problem is not version 5.0.2 in itself but definitly the use of the accelerated graphic..
Anyway this is the script, it is connected to a text entry field (field "domanda") and its aim is to take a screenshot of what the user has written in the field, as it was written on the page of a book.

Code: Select all

on returnInField
   disable me
   export snapshot from rectangle "0,0,320,480" of this card to pictVariable as PNG
   put pictVariable into image "Pagina1" of card "foglio"
   go to card "foglio"
   aeChangeRect the long ID of image "Pagina1",80, 120, 240, 360,1000,"inOut"
   aeChangeRect the long ID of image "Pagina0",0, 0, 320, 480,1000,"inOut"
end returnInField
Using the 5.0.1 version, it returned a messy graphics on the IDE but it works perfectly in the iPhone simulator and on the real iPhone. Using 5.0.2 with the command

Code: Select all

set the acceleratedRendering of this stack to true
gives back a screen capture of the 0,0,320,480 of my computer screen (and not of the card) and in simulator gives a black screen.
Thank you for help!
Antonio

Mark
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 5150
Joined: Thu Feb 23, 2006 9:24 pm
Contact:

Re: LC 5.02 problem with "screen capture"

Post by Mark » Sat Dec 17, 2011 8:25 pm

Hi Antonio,

I tred your script and don't see anything strange. It works fine in the IDE and in the simulator. I have created a simple stack for testing, which you can download here.

I did notice that in some very rare occasions, the PNG picture may get corrupt. Does it help if you use a different format, e.g. JPEG?

I removed the lines using the Animation Engine, because including it was too much trouble for such a little test. Does it make a difference if you don't use AE?

Kind regards,

Mark
The biggest LiveCode group on Facebook: https://www.facebook.com/groups/livecode.developers
The book "Programming LiveCode for the Real Beginner"! Get it here! http://tinyurl.com/book-livecode

shankez
Posts: 15
Joined: Sun Nov 20, 2011 3:25 pm

Re: LC 5.02 problem with "screen capture"

Post by shankez » Sat Dec 17, 2011 11:13 pm

Hi Mark, thank you for the script, I will study it to understand why it works while mine don't works.
Another thing: I have tried your stack on my iPhone too, it works fine for screen capture, but it has the same problem of mine about the caps lock mode when the keyboard appears.. Is there any way to turn this off?
Really thanks you!
Antonio

Mark
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 5150
Joined: Thu Feb 23, 2006 9:24 pm
Contact:

Re: LC 5.02 problem with "screen capture"

Post by Mark » Sat Dec 17, 2011 11:25 pm

Hi Antonio,

I don't know what caps lock problem you mean, but if you create a native input control, as described in the iOS Release Notes, then you should be able to change the keyboard types.

Best,

Mark
The biggest LiveCode group on Facebook: https://www.facebook.com/groups/livecode.developers
The book "Programming LiveCode for the Real Beginner"! Get it here! http://tinyurl.com/book-livecode

shankez
Posts: 15
Joined: Sun Nov 20, 2011 3:25 pm

Re: LC 5.02 problem with "screen capture"

Post by shankez » Sun Dec 18, 2011 12:54 am

Hi Mark, I mean that when the keyboard appears, it has capital letters locked, and it seems there is no way to change it. I will try to create a native input control as you said. Thank you again for your help!
Antonio

teacherguy
Posts: 379
Joined: Thu Dec 08, 2011 2:43 am

Re: LC 5.02 problem with "screen capture"

Post by teacherguy » Sun Jan 22, 2012 3:42 pm

shankez wrote:Hi Mark, I mean that when the keyboard appears, it has capital letters locked, and it seems there is no way to change it.
Antonio
Same for me

raulvelazquez
Posts: 54
Joined: Fri Jan 20, 2012 6:08 pm

Re: LC 5.02 problem with "screen capture"

Post by raulvelazquez » Mon Jan 23, 2012 3:59 am

I did notice that in some very rare occasions, the PNG picture may get corrupt. Does it help if you use a different format, e.g. JPEG?
Hi Mark

The best option is to use JPEG on all graphics?
Is there a pattern to know if a PNG will get corrupted?

shankez
Posts: 15
Joined: Sun Nov 20, 2011 3:25 pm

Re: LC 5.02 problem with "screen capture"

Post by shankez » Mon Jan 30, 2012 2:11 am

Mark wrote:Hi Antonio,

I don't know what caps lock problem you mean, but if you create a native input control, as described in the iOS Release Notes, then you should be able to change the keyboard types.

Best,

Mark
Hi Mark,
I tried with no results to create a useful iOS native input control, can you provide me a very simple stack with a working iOS native input control, so I can customize it by changing properties and keyboard type? I know is asking much, but - believe - me I really got lost :)
Thank you!!!

shankez
Posts: 15
Joined: Sun Nov 20, 2011 3:25 pm

Re: LC 5.02 problem with "screen capture"

Post by shankez » Mon Jan 30, 2012 2:36 am

teacherguy wrote:
shankez wrote:Hi Mark, I mean that when the keyboard appears, it has capital letters locked, and it seems there is no way to change it.
Antonio
Same for me
Hi! Have you resolved the issue? I cannot resolve it, I don't understand if it is a bug of LC or if there is a way to handle the capitalization in text field entries... or if it is a bug o me ;)
Anyway pls, if you have found a solution, share it...
Antonio

Dixie
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 1336
Joined: Sun Jul 12, 2009 10:53 am

Re: LC 5.02 problem with "screen capture"

Post by Dixie » Mon Jan 30, 2012 3:03 am

Shankez...

If you are using 'ordinary' text fields in conjunction with the keyboard then, no you can't control the 'capitalization', however if you elect to use UITextField in your app then you have control over the 'caps'... Read page.58 of the iOS release notes... the 'autoCapitalization' property of the UITextfield will allow you to determine when the shift-key is automatically enabled.

Be well

Dixie

teacherguy
Posts: 379
Joined: Thu Dec 08, 2011 2:43 am

Re: LC 5.02 problem with "screen capture"

Post by teacherguy » Mon Jan 30, 2012 2:46 pm

Thank you for the tip, which led me to find this lesson:

http://lessons.runrev.com/s/lessons/m/4 ... ols-on-ios

Funny, I had sent an email to support about the caps issue, and they said there was no way to deal with it.

Post Reply