gm-mio

Graphicsmagick with an extra function for scale-cropping images:

Usage no npm install needed!

<script type="module">
  import gmMio from 'https://cdn.skypack.dev/gm-mio';
</script>

README

gm-mio

Graphicsmagick with an extra function for scale-cropping images:

var gm = require('gm-mio');
    
gm('/tmp/lol.png').scaleCrop(256, 128, 50); // scale to 256 * 128, slicing off the top 50 pixels

Useful for slicing images into pixelated banners. Extremely useful. Will change your life.