Skip to content

leonelv/deno-imagemagick

master
Switch branches/tags
Code
This branch is 3 commits ahead, 506 commits behind dlemstra:main.
Contribute

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
 
 
lib
 
 
 
 
 
 
 
 
 
 
 
 

deno-imagemagick

Ported from Magick.WASM

This is a beta, there's a lot of features missing, but is a starting point

Example

import {
  initializeImageMagick,
  ImageMagick,
  MagickImage
} from "https://deno.land/x/deno_imagemagick/mod.ts"

await initializeImageMagick(); // make sure to initialize first!

const lena: Uint8Array = await Deno.readFile('lena.jpg');

ImageMagick.read(lena, (img: MagickImage) => {
  img.blur(20, 6);
  img.resize(200, 100);

  img.write((data: Uint8Array) => {
    // do something
  }, MagickFormat.Jpeg);
});

Live Example

Make sure to have denon installed.

$ cd demo
$ denon start

About

Deno port of the WASM library for ImageMagick

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • TypeScript 100.0%