[UIColor colorWithPatternImage:] can occupy a very large amount of memory when working with a large number of lines. In the end, I created one kind of image that was one line larger than the whole view using [UIColor colorWithPatternImage:] , and then shifted that view up or down the line, if necessary, to view the scrolling frame by frame. Since the view was moved only at line boundaries, the performance was much better than I expected.
However, the best option would be to create a pool of individual UImageViews using [UIColor colorWithPatternImage:] and split them, similar to what UITableView will do table cells.
Apple has sample code that illustrates this technique in the ScrollView Suite sample project and Designing Apps videos with a scroll list from WWDC 2010.
Scott Ahten
source share