function Scale($newWidth, $newHeight)
    {
        
        $dstImg = \imagecreatetruecolor($newWidth, $newHeight);
        
        \imagecopyresampled($dstImg, $this->resource, 0, 0, 
                0, 0, $newWidth, $newHeight, $this->Width(), $this->Height());
        
        $this->AssignResource($dstImg);
    }