object.maskRotation

Type Number
Object DisplayObject
Library display.*
Revision 2017.3145
Keywords mask, rotation, image mask, masking, clipping, bit mask
See also graphics.newMask()
object.rotation

Overview

Retrieve or set the rotation of the display object's corresponding mask object, if one exists.

Example

-- Image to be masked
local image = display.newImageRect( "image.png", 768, 1024 )
 
-- Mask
local mask = graphics.newMask( "circlemask.png" )
image:setMask( mask )
image.maskRotation = 180