php - Resizing image using Imagine bundle blurs Image -


i have following code:

        $imagine = new \imagine\gd\imagine();         $image = $imagine->open($src);         $image_size = $image->getsize();         $image_height = $image_size->getheight();         $image_width = $image_size->getwidth();         $ratio = 1;            $resized_image = $image;          $ratio = $image_width / $desired_width;          $this->resizedheight = $image_height / $ratio;         $this->resizedwidth = $image_width / $ratio;             // thumbnaildir doesn t exist         if(!is_dir(dirname($des)))                 mkdir(dirname($des), 0777, true);          $resized_image = $image->resize(new box($this->resizedwidth, $this->resizedheight));           $options = array(             'resolution-units' => imageinterface::resolution_pixelsperinch,             'resolution-x' => 500,             'resolution-y' => 500,             'flatten' => false         );          $resized_image->save($des, $options); 

for reason resized image bit blurry, can see resized image here , original image here , here's resized image. running out of ideas why is. idea why?

when re-size image become blur cant anything.
make copy of original image, use display.
or
find code resize.


Comments

Popular posts from this blog

java - activate/deactivate sonar maven plugin by profile? -

python - TypeError: can only concatenate tuple (not "float") to tuple -

java - What is the difference between String. and String.this. ? -