MiniMagick Ruby cropping external images returns the image too small -


i running following code , getting unexpected output external images.

require "mini_magick" image = minimagick::image.open('https://s3.amazonaws.com/dropsitecms/32a0f5e44c6ab32db614e1dbe6e773900708de5f.demo.cloudvent.net/raw/uploads/versions/404-circle-cf2d9a11b44d04de64d68843dd278140---%280-76-266-114-350-150%29---.png')  image.crop "260x112!+0+0" image.write 'image.jpg' system("open image.jpg") 

starting base image:

image

it returns result far small:

untitled-4

i expected result when start local copy of base image:

expected result

your parameter settings wrong, change width/height this,then work, have try :

require "mini_magick" image = minimagick::image.open('aa.png')  image.crop "100x200!+0+0" image.write 'image.png' 

Comments

Popular posts from this blog

javascript - Jquery show_hide, what to add in order to make the page scroll to the bottom of the hidden field once button is clicked -

javascript - Highcharts multi-color line -

javascript - Enter key does not work in search box -