Simulates an image shadow.
function shadowImage($image_path)
{
    $imagick = new \Imagick(realpath($image_path));
    $imagick->shadowImage(0.4, 10, 50, 5);
    header("Content-Type: image/jpg");
    echo $imagick->getImageBlob();
}