Getting the dimensions of an image:

<?lc
put "photo.jpg" into myImage
import paint from file myImage
put the width of last image & "px x " & the height of last image & "px"
?>

Scaling an image

e.g. To scale an image by 50%

<?lc
put "photo.jpg" into myImage
import paint from file myImage
set the resizeQuality of last image to "normal" // can be normal, good or best
put "0.5" into theScale
set the width of last image to the width of last image * theScale
set the height of last image to the height of last image * theScale
set the imageData of last image to the imageData of last image
export last image to file ("resized" && myImage)as JPEG
delete last image
?>

Cropping an image

<?lc
put "photo.jpg" into myImage
import paint from file myImage
crop image myImage to 00,00,100,120 // left,top,right,bottom
export last image to file ("cropped" && myImage) as JPEG
delete last image
?>

Flip an image

<?lc
put "photo.jpg" into myImage
import paint from file myImage
flip image myImage vertical // horizontal or vertical
export last image to file ("flipped" && myImage) as JPEG
delete last image
?>

Rotate an image

<?lc
put "photo.jpg" into myImage
import paint from file myImage
rotate image myImage by 45
export last image to file ("rotated" && myImage) as JPEG
delete last image
?>
Contact Us

We're not around right now. But you can send us an email and we'll get back to you, asap.

Not readable? Change text. captcha txt

Start typing and press Enter to search