Vertical Scroller - tiling a background

I’m trying to make a vertical scroller background that repeats a graphic over and over… to avoid having a real big background image. The image I have is capable of being tiled but I just can’t figure out how to tell Corona to repeat the image when the end of the previous image is reached. I did a search but haven’t found any examples… can anyone point me in the right direction?
thanks!
[import]uid: 16901 topic_id: 11405 reply_id: 311405[/import]

Well… I think I got it working. The code can be refined but the basic approach is shown below. I’m not exactly sure why the transitionto time for image 2 must be doubled for everything to stay in sync but it does. This isn’t a never-ending scroll but I don’t really need that anyway.

baseMovementTime=30000

local image1 = display.newImage(“wall320x594.png”);
image1:setReferencePoint(display.TopLeftReferencePoint);
image1height=image1.contentHeight
print(image1height)
image1.x=0
image1.y=0

local image2 = display.newImage(“wall320x594.png”);
image2:setReferencePoint(display.TopLeftReferencePoint);
image2height=image2.contentHeight
image2.x=0
image2.y=-image2height
transition.to(image1, { time=baseMovementTime, delay=15, y= image1height});
transition.to(image2, { time=baseMovementTime*2, delay=15, y= image2height} ) [import]uid: 16901 topic_id: 11405 reply_id: 41321[/import]

Here’s a better version:

[code]
baseMovementTime=30000
for k = 0, 10, 1 do
background[k] = display.newImage(“wall320x594.png”);
background[k]:setReferencePoint(display.TopLeftReferencePoint);
background[k].imageHeight=background[k].contentHeight
background[k].x=0
background[k].y=-k*background[k].imageHeight
print(“K:”,k)
print(“X:”,background[k].x)
print(“Y:”,background[k].y)
print(" ")

transition.to(background[k], { time=baseMovementTime*(k+1), delay=15, y= background[k].imageHeight});

end [import]uid: 16901 topic_id: 11405 reply_id: 41322[/import]

Very interesting, Thanks for sharing your method txmarsh!!
I am having similar background troubles, but in my case I just want to draw a new background when the object goes off screen. Then I would want to move the object back to the top of the screen to fall again. Eventually I’ll figure it out. [import]uid: 12540 topic_id: 11405 reply_id: 41328[/import]