public function cropImage($x, $y, $width, $height, $rotate)
    {
        $DS = DIRECTORY_SEPARATOR;
        $savePath = Yii::getAlias($this->_savePathAlias);
        $imageSrc = $this->owner->{$this->_imageAttribute};
        $fullImagePath = $savePath . $DS . $imageSrc;

        $imageComponent = static::getImageComponent();
        /* @var $image Image_GD|Image_Imagick */
        $image = $imageComponent->load($this->getOriginalImagePath());

        $image->crop($width, $height, $x, $y);
        $image->rotate($rotate);

        $image->save($fullImagePath);

        $sizes = $this->getImageSizes();
        unset($sizes['']);

        $pathParts = explode('/', str_replace('\\', '/', $imageSrc));
        $filename = array_pop($pathParts);

        // Make resize
        return static::resizeAndSave($savePath . $DS . implode($DS, $pathParts), $filename, $sizes);
    }