Scrolling a very large image on iOS

Neil Roger neil at runrev.com
Wed Nov 27 10:05:19 CET 2013


Hi Gerry,

This could be an image cache issue. By default it is set to 64MB but 
this can be increased to 256MB via the following script-

on preOpenStack
set the imageCacheLimit to 268435456
end preOpenStack

Kind Regards,

Neil Roger
--
RunRev Support Team ~ http://www.runrev.com
LiveCode – Realize fast, compile-free coding
-- 


On 27/11/2013 08:55, Gerry wrote:
> Dear LiveCode hive mind
>
> I have an image that is 55000 pixels wide by 1250 pixels high. It contains 44 square photographs, evenly spaced across the image. The image is an imported jpeg that is about 9.5mb on disk.
>
> I’m scrolling it in a native iOS scroller that is 1250 x 1250 pixels. Paging is set to true (so as the user swipes the image snaps into position) - the scrolling group and image are positioned correctly so that swipes across the image positions each photograph correctly as the user swipes back and forth. As the image snaps into position, I grab the hScroll of the scroller and display it in a field.
>
> The scrolling group has it’s layer mode set to scrolling. The large image within the group has it's layermode set to dynamic. On preopencard I’m setting acceleratedrendering to true and the compositorType of the stack to “OpenGL".
>
> Works well on an iPad 3…until I reach position 26 (hScroll = 32502). If I try to scroll to position 27 the image disappears (on both the device and the simulator). The scroller keeps working, however - if I keep scrolling I can see the hScroll value going up. And when I scroll back to position 26…the image re-appears.
>
> I’m thinking this is a memory problem. Is there any way I can improve the performance of this scroller (besides reducing the quality of image)?
>
> Cheers
>
> Gerry
> _______________________________________________
> use-livecode mailing list
> use-livecode at lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode




More information about the use-livecode mailing list