Freeze\Pause happen when using masks, mainly on PC/Android.

Hello.

I’ve complained about this before, but I’ll need to do it again since the problem got worst in the last few daily builds.

So to recap the problem, I’ve noticed that at a point in my project, screen is starting to get lame, and now freeze\thaw when ever I’m using a mask to mask the whole screen, and then use a tween to animate that screen.

If before I had a slight delay with my sliding when I was using the mask and a tween, now there is no sliding at all, and the screens just jump into existence in it’s final place.

Steps:

  1. Create a screen with some graphics on it, and a button, put it all into a nice display group.

  2. At the press of the button, create another screen, some images, graphics, buttons, but create them all off screen, to be tweened into position.

  3. Mask the new screen with a mask that shows most of the screen, except for some off the top, or bottom, or both.

  4. Try to slide the new screen in and the old screen out using tween, and with the problem I’m seeing, which used to be that the slide in of the new screen would happen, but with a slight delay, now does not happen at all, but the screens take the time I set for the tween (1.5 seconds for example) and then the old vanish, the new show up where it supposed to be.

I was trying to make an example file of this, but it would seem that this happens only in “heavy” files… when I create a new file with this example, it works fine, my project file, not working at all, if I “turn” off all the screen masks, works perfectly, I turn on some masks while others are off, those who are on cause the same problem.

I’ve been told you had a problem with masks causing freezing in android before, well, seems like it’s back.

Any notion on what can be done?

P.S.

In screens where I use small masks to mask a single object or a small group of objects, no problems at all, it’s only screen where the mask masks most of the screen.

After doing some experiments, I can tell you the problem is somehow related to the size of my mask file, I took that file, a png, and started making in smaller and smaller in size and testing my app, at 80 percent original size (where original size is a mask which covers the whole screen, so 728x1288, which is the size of my Galaxy S3 screen plus 4 pixels a side for the mask to work) the problem was the same, freeze then show in place instead of slide, when it was 60 percent, it froze, but did show some of the slide in/out, about 50 percent of the animation… when the size of the mask was less then 50 percent of the screen size, it worked without any freeze or problem (which sucks, since I need to mask my whole screen, except for the top/bottom, so I need a screen size mask…

Hi @formatc,

This may be a lot to ask, but can you pinpoint the most recent daily build when it was working better? I don’t think we’ve been tinkering with masks recently, but if I had two points of comparison (two builds), it would be easier to determine what may have changed.

Also, have you investigated Containers in Graphics 2.0? It’s currently in beta, but for your purposes, this will ultimately be the best solution, not a mask.

Best regards,

Brent

Hi Brent. I would have to download older versions and install them and try out until I get the best result.

Also, after some more tests I have changed the order of things as to apply my screen mask to my group before I populate it with the rest of the graphics, this has made a huge improvement, but it still shows a constant small delay of any animated actions that supposed to happen right after the compiling of my off screen screen, the delay is always of 500 milliseconds, and again, if the mask is a small one, there are no problems, if it’s a large one, same problem, I place a timer trace before the setting of the mask, and after the setting of the mask, the mask is over an empty group, always half a second delay/freeze.

This problem was showing only when I used to test the project on my PC, on the mac it wasn’t present, and wasn’t so noticible on the device, but now, in the past few weeks, it shows off also on the mac simulator, and on the android device, but it does not happen when running it on an iOS device (tried on iphone 4/4s/5 with iOS 6 and 7).

About switching to Graphics 2.0, it’s probably a good idea, but my project which is almost done is huge, I wouldn’t make such a change to it at this point unless it was my only and last option.

Yuval.

After doing some experiments, I can tell you the problem is somehow related to the size of my mask file, I took that file, a png, and started making in smaller and smaller in size and testing my app, at 80 percent original size (where original size is a mask which covers the whole screen, so 728x1288, which is the size of my Galaxy S3 screen plus 4 pixels a side for the mask to work) the problem was the same, freeze then show in place instead of slide, when it was 60 percent, it froze, but did show some of the slide in/out, about 50 percent of the animation… when the size of the mask was less then 50 percent of the screen size, it worked without any freeze or problem (which sucks, since I need to mask my whole screen, except for the top/bottom, so I need a screen size mask…

Hi @formatc,

This may be a lot to ask, but can you pinpoint the most recent daily build when it was working better? I don’t think we’ve been tinkering with masks recently, but if I had two points of comparison (two builds), it would be easier to determine what may have changed.

Also, have you investigated Containers in Graphics 2.0? It’s currently in beta, but for your purposes, this will ultimately be the best solution, not a mask.

Best regards,

Brent

Hi Brent. I would have to download older versions and install them and try out until I get the best result.

Also, after some more tests I have changed the order of things as to apply my screen mask to my group before I populate it with the rest of the graphics, this has made a huge improvement, but it still shows a constant small delay of any animated actions that supposed to happen right after the compiling of my off screen screen, the delay is always of 500 milliseconds, and again, if the mask is a small one, there are no problems, if it’s a large one, same problem, I place a timer trace before the setting of the mask, and after the setting of the mask, the mask is over an empty group, always half a second delay/freeze.

This problem was showing only when I used to test the project on my PC, on the mac it wasn’t present, and wasn’t so noticible on the device, but now, in the past few weeks, it shows off also on the mac simulator, and on the android device, but it does not happen when running it on an iOS device (tried on iphone 4/4s/5 with iOS 6 and 7).

About switching to Graphics 2.0, it’s probably a good idea, but my project which is almost done is huge, I wouldn’t make such a change to it at this point unless it was my only and last option.

Yuval.