I’m using a decorative png file with a window in it to mask the player’s view of the image behind it. the masked area looks something like this:
XXXXXXXXXX
XXXBBBBXXX
XXXBBBBXXX
XXXXXXXXXX
XXXXXXXXXX
X = area with graphic
B is a masked area that allows a window into what is behind it. The object behind it can be dragged through this window. The object will detect touches so that the object behind it can only be accessed through the window.
I am using a solid image and an image mask applied using setMask(). The black and white mask image has a 4 pixel black border ( I did that because I thought it might resolve the issue but it hasn’t).
The problem occurs when the device is rotated. The mask rotates and is applied as expected, however the touch area is not rotated, it is basically in the same spot as it was in when the device was vertical.
Everything is in a group together so I am just rotating the group. Again, it appears to work visually but the touch area of the masking image is not changing.
Any advice on how to fix this?
I am considering removing the mask and reapplying it to the image each time the device is rotated, but I figure there has to be a better way than that. [import]uid: 191108 topic_id: 32843 reply_id: 332843[/import]