The project is very simple. It should allow me to crop a image and output BitmapData of the cropped area.
The component should have a canvas wrapper which loads the image and fits the image into the canvas.
The cropper mask size must be relative to the image and NOT the canvas wrapper.
I need a AS3 class that performs the following tasks:
PUBLIC METHODS ---------------------------
imageSource(imageURL:String)
loads the "image URL" into the cropper component. Dispatches IOErro, Progress and Complete events.
setCropRectangle(rec:Rectangle)
allows to set the cropping area RELATIVE TO THE IMAGE.
SETTERS ----------------------------------------
displayHandler:Boolean
displays/hides the cropping box resize handles. If false, cropping box can only be moved but not resizes.
if true, handles on the 4 corners are displayed allowing the cropping box to be resized.
IMPORTANT: resize boundaries should be equal to the uploaded image.
maskColor:UINT
defines the color of the overlay mask.
handleColor:UINT
color of the handles
handleAlpha
alpha for the handle.
outlineColor:UINT
color of mask's outline border (1px)
outlineAlpha:Number
outline's alpha
maintainAspectRation:Boolean
if true, maintain ratio of the current mask size.
GETTER ----------------------------------------------------
getCropArea():BitmapData
- it returns the actual cropped area in BitmapData.
IMPORTANT: output BitmapData MUST support transparency (0x00FFFFFF)
===========================================
That's it. My budget for this project it's 30GBP.
References (although these samples are all free, I need the copyrights for this project and not license):
[login to view URL]
[login to view URL]