Hey
I just tried the similar thing - but using text labels. Basically I was adding text labels to a group, one below the other, then took the screen capture using display.capture.
Here is my code. It iterates over a table (it has 8 elements in this case) and just adds the text labels to the group. Then it makes the screen capture of this group.
local grp = display.newGroup () local ov = display.newGroup () local lastX, lastY = 0, 0 for \_, m in pairs ( models ) do local md = display.newText ({ text = "This is line number " .. \_, fontSize = 28, font = "assets/28 Days Later.ttf", }) md:setFillColor ( 0 ) md.x, md.y = 20, lastY lastY = lastY + md.contentHeight + 60 lastX = math.max ( lastX, md.x + md.contentWidth ) md.anchorX, md.anchorY = 0, 0 grp:insert ( md ) end local bg = display.newImageRect ( "graphics/Background.png", lastX, lastY) bg.anchorX = 0 bg.anchorY = 0 grp.anchorX, grp.anchorY = 0, 0 bg.x, bg.y = 0, 0 ov:insert ( bg ) ov:insert ( grp ) grp.x, grp.y = 0, 0 ov.y = 0 display.save ( ov , { isFullResolution = true, filename = "xx.jpg" } )
I use isFullResolution and it works in a way that it doesn’t cut out the background image on the screen edge. However, whatever label is FULLY outside of the screen doesn’t get to the screen capture. The resulting image looks like this. You can see that there are no texts below the “line number 5”, but the background extends for the next 3 lines…
