UI.FrameTexture
Index
Properties
readonlyCORNER_BOTTOM_LEFT
Specifies bottom left corner of the frame.
readonlyCORNER_BOTTOM_RIGHT
Specifies bottom right corner of the frame.
readonlyCORNER_TOP_LEFT
Specifies top left corner of the frame.
readonlyCORNER_TOP_RIGHT
Specifies top right corner of the frame.
readonlySIDE_BOTTOM
Specifies bottom side of the frame.
readonlySIDE_LEFT
Specifies left side of the frame.
readonlySIDE_RIGHT
Specifies right side of the frame.
readonlySIDE_TOP
Specifies top side of the frame.
Methods
draw
expand
Expands texture to the specified side, filling the middle with specified color.
Parameters
width: number
height: number
color: number
integer color value produced by android.graphics.Color class
sides: [boolean, boolean, boolean, boolean]
array of booleans marking whether the side should be expanded or not. The order of the sides is FrameTexture.SIDE_LEFT, FrameTexture.SIDE_RIGHT, FrameTexture.SIDE_UP, FrameTexture.SIDE_DOWN
Returns Bitmap
Expanded android.graphics.Bitmap instance with the frame.
expandAndScale
Expands texture to the specified side, filling the middle with specified color.
Parameters
width: number
height: number
scale: number
scale of the created bitmap
color: number
integer color value produced by android.graphics.Color class
sides: [boolean, boolean, boolean, boolean]
array of booleans marking whether the side should be expanded or not. See UI.FrameTexture.expand parameters for details. Default behavior is to scale all sides
Returns Bitmap
Expanded and scaled android.graphics.Bitmap instance.
expandSide
Expands side of the texture by specified amount of pixels.
Parameters
sideId: number
side of the texture, one of the FrameTexture.SIDE_LEFT, FrameTexture.SIDE_RIGHT, FrameTexture.SIDE_UP, FrameTexture.SIDE_DOWN constants
pixels: number
Returns Bitmap
Expanded android.graphics.Bitmap instance with the frame.
getCentralColor
Returns number
Object packed integer color value of the central pixel of the source texture.
getSideSource
Parameters
side: number
side of the texture, one of the FrameTexture.SIDE_LEFT, FrameTexture.SIDE_RIGHT, FrameTexture.SIDE_UP, FrameTexture.SIDE_DOWN constants
Returns Bitmap
Texture side source extracted from the original frame texture source stored in android.graphics.Bitmap instance.
getSource
Returns Bitmap
Original frame texture source stored in android.graphics.Bitmap instance.
Object used to manipulate frame textures.