Present and zoom large images on iOS without CATiledLayer

和自甴很熟 提交于 2019-12-04 21:09:39

I guess you can have two views: one ImageView with a low res image, and on top a custom view with a CaTiledLayer, with transparent background and hidden at the beginning.

So, when zooming (you'll need to apply zoom to both views) and you need extra resolution, just show the catiledlayered view, so it will load tiles while showing the lowres (and pixelated) on not loaded tiles.

Apple's PhotoScroller and ScrollViewSuite samples show how to do this and more.

There's also a 2010 WWDC video titled "Designing Apps with Scroll Views" that explains PhotoScroller.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!