strange problem

So I've been playing some more with Tiled and lime. My interest is mainly in iPad based development. Anyway, I created a test map with layers and added a large png file to the background layer. The PNG file is larger than the map yet it appears on the simulator as scaled down. I've set the config.lua for ipad only with no scaling.
The map is 96 tiles by 24 tiles of 32 size tiles. The background image is a single color PNG. I know the PNG file gets added to the right layer as it shows up behind everything else.

1
2
3
4
5
6
7
8
9
10
11
12
13
display.setStatusBar( display.HiddenStatusBar )
 
local lime = require("lime")
local map = lime.loadMap("96x24.tmx")
 
-- add large image to background layer
local myimage = display.newImage("3072x768.png")
 
local backlayer = map:getTileLayer("Sky")
backlayer:addObject(myimage)
 
lime.createVisual(map)
lime.buildPhysical(map)

I believe that as your image is bigger than the maximum allowed size for Corona that it will get scaled down automatically, you should be able to pass the isFullResolution paramater. I'm not sure what the maximum size limitation is for iPad though - http://developer.anscamobile.com/reference/index/displaynewimage

Thanks Graham. I should have spotted that myself. If the image is larger than 2048x2048 it scales silently. (at least nothing in the terminal window) It works fine with the 1536x768 test PNG

Awesome, glad it got solved! Probably have to just split up the image into two and then place it side by side. Fiddly but not too much of a problem.

views:1563 update:2011/10/13 16:30:09
corona forums © 2003-2011