dynamic image scaling: positioning problem

Hi

I am attempting image scaling but only a portion of my images are appearing. I have the background image in two file sizes: 

background.jpg (360 x 570)  and background@4x.jpg (720 x 1140)   

The only line in my  main.lua right now is l

local flashImage = display.newImageRect(“background.jpg”,360,570)

my config.lua has

application = {

    content = {  width = 360,  height = 480,   scale = “letterBox”,    

        

        imageSuffix = {

            ["@4x"] = 1.5,

        }

},

}

My problem is that only the bottom right quadrant of these images are being displayed, although corona is choosing the right file for the right device. See screenshot

thanks for the help.

David

The rectangle’s reference point by default is the center of the rectangle, and so when created the center is automatically placed at 0,0 (the upper left corner of the screen).  You can move the rectangle to the center of the screen using

flashImage.x = display.contentCenterX
flashImage.y = display.contentCenterY

Thanks!

The rectangle’s reference point by default is the center of the rectangle, and so when created the center is automatically placed at 0,0 (the upper left corner of the screen).  You can move the rectangle to the center of the screen using

flashImage.x = display.contentCenterX
flashImage.y = display.contentCenterY

Thanks!