Background img freezing script

Got a LiveCode personal license? Are you a beginner, hobbyist or educator that's new to LiveCode? This forum is the place to go for help getting started. Welcome!

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller

Post Reply
newpie
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 155
Joined: Sat Jun 29, 2013 11:24 pm

Background img freezing script

Post by newpie » Fri Sep 16, 2016 2:11 pm

Hello, I coded a native scroller (lorem) for my group that has an large image using Livecode "8.1". It runs smoothly on android tablet. The issue comes in when I add a background button and fill in with imported png image on separate card. Then it freeze. I am not used to building for mobile.

Is there a trick or something I have to do in order to get this working smoothly again. I prefer to use my imported background images for my button (background). I traced it down to this because I change the background to a solid color and it works fine again.

Thanks for any help.

jacque
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 7393
Joined: Sat Apr 08, 2006 8:31 pm
Contact:

Re: Background img freezing script

Post by jacque » Fri Sep 16, 2016 4:18 pm

I'm not quite sure how the button is involved, but in general a scroller requires acceleratedRendering to be turned on, and the group's layermode should be set to "scrolling".
Jacqueline Landman Gay | jacque at hyperactivesw dot com
HyperActive Software | http://www.hyperactivesw.com

newpie
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 155
Joined: Sat Jun 29, 2013 11:24 pm

Re: Background img freezing script

Post by newpie » Fri Sep 16, 2016 6:19 pm

Thanks jacque for responding. The button is just functions as background with controls in front of it. I included a very simple script to show you what I mean by imported background img.

Thanks
Attachments
backgroundExample.zip
Only shows background difference- no scrolling code
(22.08 KiB) Downloaded 199 times

jacque
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 7393
Joined: Sat Apr 08, 2006 8:31 pm
Contact:

Re: Background img freezing script

Post by jacque » Fri Sep 16, 2016 7:38 pm

I don't usually download files from the forum (screenshots are better) because typically I'm not at my computer when I visit the forums. Regardless of the setup though, I think you do need to experiment with acceleratedRendering and layerMode. Those properties were made specifically to allow smooth animations and scrolling.
Jacqueline Landman Gay | jacque at hyperactivesw dot com
HyperActive Software | http://www.hyperactivesw.com

Klaus
Posts: 14198
Joined: Sat Apr 08, 2006 8:41 am
Contact:

Re: Background img freezing script

Post by Klaus » Sat Sep 17, 2016 3:13 pm

newpie wrote:Thanks jacque for responding. The button is just functions as background with controls in front of it. I included a very simple script to show you what I mean by imported background img.

Thanks
There is no script anywhere in that example stack? 8)

newpie
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 155
Joined: Sat Jun 29, 2013 11:24 pm

Re: Background img freezing script

Post by newpie » Sat Sep 17, 2016 4:47 pm

Thanks Klaus, yes there is no script there. I was just trying to answer the question regarding "how the button is involved". Sorry to confuse.

Klaus
Posts: 14198
Joined: Sat Apr 08, 2006 8:41 am
Contact:

Re: Background img freezing script

Post by Klaus » Sat Sep 17, 2016 5:57 pm

OK, but that may have shown a problem, which I cannot see in the moment.

newpie
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 155
Joined: Sat Jun 29, 2013 11:24 pm

Re: Background img freezing script

Post by newpie » Wed Sep 28, 2016 4:57 pm

Hello, apologize for late reply, I believe it is the android tablet I am using. It is low-level and just can't keep up with the image loading/rendering. Thanks for your help though.

Post Reply