How to zoom in an image? (just the image not the canvas)

Hi guys,

It maybe a stupid question but I want zoom an image but the image needs to stay inside the original canvas size. I know about xScale/yScale but that just increase the size of the image but also the canvas size.

Would appreciate any pointers.

Thanks!

Mo

Put the image in a container. Containers clip images to a certain size.

http://docs.coronalabs.com/api/library/display/newContainer.html

WOW! Thanks so much.  I did not even think about containers. It sounds like a very good solution. The problem it “seems” that container masks the reset of the screen (at least looking at that demo video) I cannot have the rest of the screen with a low alpha. Anyway I can do it on the image size only?

I am not sure I am explaining correctly :frowning:

Thanks again for taking the time.

Mo

Put the image in a container. Containers clip images to a certain size.

http://docs.coronalabs.com/api/library/display/newContainer.html

WOW! Thanks so much.  I did not even think about containers. It sounds like a very good solution. The problem it “seems” that container masks the reset of the screen (at least looking at that demo video) I cannot have the rest of the screen with a low alpha. Anyway I can do it on the image size only?

I am not sure I am explaining correctly :frowning:

Thanks again for taking the time.

Mo