lumeland / imagemagick-deno

Deno port of the WASM library for ImageMagick
https://deno.land/x/imagemagick_deno
Apache License 2.0
44 stars 3 forks source link

Is there a way to pass in raw flags? #2

Closed reggi closed 1 year ago

reggi commented 1 year ago

Similar to this example here?

 const command = [
    "convert",
    "-background",
    "lightblue",
    "-fill",
    "blue",
    "-font",
    "baby-cruffy.ttf",
    "-pointsize",
    "72",
    "label:Anthony",
    "label.gif"
  ];
  console.log({ command: command.join(", "), content: inputFiles[0].content });
  //debugger;
  const processedFiles = await Magick.Call(inputFiles, command);

Or should I just use the node module? wasm-imagemagick?

Sorry I just realized there is two wasm implementations, this is the one used here @imagemagick/magick-wasm.

Can I call this in Deno directly and pass raw flags? https://deno.land/x/imagemagick_deno@0.0.19/src/wasm/magick.ts?source

reggi commented 1 year ago

I'm also realizing that the underlying wasm code isn't a conversion of the command line, it's the code beneath it? Is it possible to do things like nesting side-image parenthesis the way the CLI does?