Allowing to crop to larger image size than the original image

Sometimes you want to make it "just work" for the end user and not to bother them about the image size or similar. So I've built in the ability to upscale images (only if $upscale is set to true, otherwise the script won't change in behavior).