Error while Converting JPG to PNG with fuzz parameter

Questions and postings pertaining to the usage of ImageMagick regardless of the interface. This includes the command-line utilities, as well as the C and C++ APIs. Usage questions are like "How do I use ImageMagick to create drop shadows?".
Post Reply
alex_ig
Posts: 2
Joined: 2018-03-06T15:38:27-07:00
Authentication code: 1152

Error while Converting JPG to PNG with fuzz parameter

Post by alex_ig » 2018-03-06T15:46:44-07:00

Hi, I'm new to ImageMagic and have a very basic question but can't figure out the issue myself. I have a bunch of JPG images sitting in a folder and I need to apply a transparent background and make them PNG. Below is a command that I have in a BAT file:

for %%i in (*.jpg) do ( convert "%%i" -fuzz 5%% -transparent white "%%~ni.png" )

When I run that I'm getting this error:

Invalid Parameter - -fuzz

I would appreciate any help.

Thanks.

snibgo
Posts: 10565
Joined: 2010-01-23T23:01:33-07:00
Authentication code: 1151
Location: England, UK

Re: Error while Converting JPG to PNG with fuzz parameter

Post by snibgo » 2018-03-06T16:25:18-07:00

"Invalid Parameter" means you are not running ImageMagick convert.exe, but a Microsoft Windows program with the same name.
snibgo's IM pages: im.snibgo.com

alex_ig
Posts: 2
Joined: 2018-03-06T15:38:27-07:00
Authentication code: 1152

Re: Error while Converting JPG to PNG with fuzz parameter

Post by alex_ig » 2018-03-06T21:27:08-07:00

Thanks for your help! I added a full path to the magick.exe and it works now.

Thanks again.

Post Reply