|
a2Option_FlipX()
This returns a value used by the "options" parameter of the a2DrawImage command.
a2Option_FlipX()
This function has no parameters.
This function returns a value of 1.
This function is used by the "options" parameter of the Advanced 2D a2DrawImage command to indicate that the image is to be drawn horizontally flipped. The original image is not changed. Note that when the image is drawn horizontally flipped, the local x origin is changed by the width of the image, but can be reassigned with the centerX parameter of the a2DrawImage command.
cls 0xFFFFFFFF
a2FillBox 2,2,62,62,0xFFFF0000
font1 = a2CreateFont("ariel", 78, a2Size_Char(), a2Style_Normal())
a2Text font1, 2, -10, "R", 0xFFFFFFFF
get image 1,0,0,64,64,1
cls 0
rem Draw the unflipped image
a2DrawImage 1,150,100,0,0,0,1,0,0xFFFFFFFF
rem Draw the horizontally flipped image, offset by image width
a2DrawImage 1,150,200,0,64,0,1,a2Option_FlipX(),0xFFFFFFFF
rem Draw the vertically flipped image, offset by image height
a2DrawImage 1,250,100,0,0,64,1,a2Option_FlipY(),0xFFFFFFFF
WAIT KEY
a2DrawImage
|