I'm trying to do a fast blur operation by resizing an image (layer) smaller and then back to the exact original size. Since I apply the resize command to images of different sizes, I can't set a specific size in the argument for resize.
I tried it without success:
Code: Select all
convert 0.jpg -set origsize "%Wx%H" \( +clone -scale 20% -resize "%[origsize]" \) -composite 1.jpg
> convert 0.jpg -set origsize '%Wx%H' -format '%[origsize]!' info:
> 205x128!
The same command should run on both Linux and Windows, so the following does not help:
> convert 0.jpg -scale 20% -resize `convert 0.jpg -format '%Wx%H!' info:` 1.jpg
Is it possible at all to use the key/value as argument for resize? (Did I just do it wrong?)
Alternatively, is there an option that stretches the layer to the canvas size?