Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Windows 11: No decode delegate for this image format #6783

Open
blueridgetog opened this issue Oct 14, 2023 · 17 comments
Open

Windows 11: No decode delegate for this image format #6783

blueridgetog opened this issue Oct 14, 2023 · 17 comments

Comments

@blueridgetog
Copy link

ImageMagick version

7.1.1-20

Operating system

Windows

Operating system, version and so on

Windows 11

Description

Hi. I am struggling here. I appreciate the help and kindness - and direction on how to fix this so I can restore my photographic workflow.

I've used Imagemagick inside Lightroom Classic for many years to help with image exports, applying filenames to proofs among other awesome things. I recently upgraded my xRite color calibration software and it broke Imagemagick's decode deletages (and several other programs). I've removed xRite and fixed the other issues, but Imagemagick still cannot find the delegates. I've downloaded several versions of IM and uninstalled/reinstalled the Windows 11 packages (several versions, include 6.9.12 and 1.1.1-20) to no avail.

No matter how I access IM, using either Lightroom or the IMDisplay utility, I get the same message "no decode delegate for this image format 'JPEG'". I've tried multiple image formats all with the same issue.

When I run the "magick -list format", it doesn't list any files.

What can I do to get IM to find the delegates? I see examples online for Linux and Mac, but nothing to help in Windows.

I appreciate any advice or help!

image

Thanks so much!

Steps to Reproduce

Installed ImageMagick (multiple versions)
Open IMDisplay Utility
Drag a JPEG or PNG file into the display utility
Get the error message
Uninstall Imagemagick
Reboot laptop
Repeat with same results.

Run "magick -list format" and I don't see any delegates available.

Images

No response

@blueridgetog blueridgetog changed the title Windows 11 Windows 11: No decode delegate for this image format Oct 14, 2023
@fmw42
Copy link

fmw42 commented Oct 14, 2023

If you do not see any delegates, then you did not install properly. Use the binary from Imagemagick to install. See https://imagemagick.org/script/download.php#windows. Use the install window/GUI to do the install.

@snibgo
Copy link

snibgo commented Oct 14, 2023

You may have multiple installations of IM. Type this command: where magick. That will list the installations that are in your path. The first is the one that is executed when you run magick.

I suggest removing each installation, then re-install from https://imagemagick.org/script/download.php#windows

@blueridgetog
Copy link
Author

blueridgetog commented Oct 14, 2023

If you do not see any delegates, then you did not install properly. Use the binary from Imagemagick to install. See https://imagemagick.org/script/download.php#windows. Use the install window/GUI to do the install.

That's what I thought, too. I have uninstalled the program multiple times and reloaded from the binary from different versions. Each time I get the same results. I've confirmed the uninstallation and rebooted - even waiting several days due to being busy - before trying the installation again from files named like this: ImageMagick-7.1.1-20-Q16-HDRI-x64-dll.exe and ImageMagick-6.9.12-98-Q16-HDRI-x64-dll.exe.

Thanks for your suggestion, and I appreciate any other ideas!

@blueridgetog
Copy link
Author

You may have multiple installations of IM. Type this command: where magick. That will list the installations that are in your path. The first is the one that is executed when you run magick.

I suggest removing each installation, then re-install from https://imagemagick.org/script/download.php#windows

I wish that was the case. I have completely removed IM from the system multiple times, including just last night. When I run the "where magick" command, it returns:
image

I have reinstalled multiple versions including version 7 and 6 to try and fix this issue.

Thanks for your suggestion: I welcome other ideas! :)

@fmw42
Copy link

fmw42 commented Oct 14, 2023

What do you get from

magick.exe -version

@blueridgetog
Copy link
Author

What do you get from

magick.exe -version

Just installed it again from Version: ImageMagick-7.1.1-20-Q16-HDRI-x64-dll.exe

I get this response:

Version: ImageMagick 7.1.1-20 Q16-HDRI x64 98bb1d4:20231008 https://imagemagick.org
Copyright: (C) 1999 ImageMagick Studio LLC
License: https://imagemagick.org/script/license.php
Features: Channel-masks(64-bit) Cipher DPC HDRI Modules OpenCL OpenMP(2.0)
Delegates (built-in): bzlib cairo flif freetype gslib heic jng jp2 jpeg jxl lcms lqr lzma openexr pangocairo png ps raqm raw rsvg tiff webp xml zip zlib
Compiler: Visual Studio 2022 (193532217)

And then when I load the IM Display tool, I still get this:
image

@fmw42
Copy link

fmw42 commented Oct 14, 2023

Sorry, I am not a Windows users. So wait for one of them to answer. I know nothing about the IMDisplay. It looks like all the delegates are there to me.

@blueridgetog
Copy link
Author

Sorry, I am not a Windows users. So wait for one of them to answer. I know nothing about the IMDisplay. It looks like all the delegates are there to me.

Thanks for your thoughts and advice.

@snibgo
Copy link

snibgo commented Oct 14, 2023

Check that IMdisplay help (click the "?") gives the expected version number.

Do the following work?

magick rose: r.jpg

magick r.jpg r.png

There might be a problem with your Windows registry.

On Windows 11, I have just now downloaded ImageMagick-7.1.1-20-portable-Q16-HDRI-x86.zip . (Note: installing the "portable" version just copies files, and doesn't change the registry.) IMdisplay works fine.

@blueridgetog
Copy link
Author

blueridgetog commented Oct 15, 2023

Check that IMdisplay help (click the "?") gives the expected version number.

Do the following work?

magick rose: r.jpg

magick r.jpg r.png

There might be a problem with your Windows registry.

On Windows 11, I have just now downloaded ImageMagick-7.1.1-20-portable-Q16-HDRI-x86.zip . (Note: installing the "portable" version just copies files, and doesn't change the registry.) IMdisplay works fine.

Here's the response from the suggested command:

magick rose: r.jpg
magick: unable to open image 'rose:': Invalid argument @ error/blob.c/OpenBlob/3573.
magick: no decode delegate for this image format `' @ error/constitute.c/ReadImage/746.

I'll pursue the Windows registry and see if there are any entries there for ImageMagick.
Edit: When I uninstall ImageMagick, I watched the registry key get deleted from the registry... gone without a trace.

Sigh... Thanks for the help and ideas! I really do appreciate it!

@snibgo
Copy link

snibgo commented Oct 15, 2023

On Windows 11, I have downloaded and installed:

15/10/2023  18:50        38,841,752 ImageMagick-7.1.1-20-Q16-HDRI-x64-dll.exe

... and I can't reproduce the problem.

magick rose: r.jpg
magick: unable to open image 'rose:': Invalid argument ...

Yikes! The rose: image is hard-coded into IM, so shouldn't fail. This is the message we get if we try to read an internal image that doesn't exist, such as:

magick qwe: NULL:
magick: unable to open image 'qwe:': Invalid argument @ error/blob.c/OpenBlob/3573.
magick: no decode delegate for this image format `' @ error/constitute.c/ReadImage/746.

To help narrow down the problem, can you also try:

magick xc: x.jpg

magick gradient: x.jpg

Please also show the text output from:

magick -list format

@blueridgetog
Copy link
Author

On Windows 11, I have downloaded and installed:

15/10/2023  18:50        38,841,752 ImageMagick-7.1.1-20-Q16-HDRI-x64-dll.exe

... and I can't reproduce the problem.

magick rose: r.jpg
magick: unable to open image 'rose:': Invalid argument ...

Yikes! The rose: image is hard-coded into IM, so shouldn't fail. This is the message we get if we try to read an internal image that doesn't exist, such as:

magick qwe: NULL:
magick: unable to open image 'qwe:': Invalid argument @ error/blob.c/OpenBlob/3573.
magick: no decode delegate for this image format `' @ error/constitute.c/ReadImage/746.

To help narrow down the problem, can you also try:

magick xc: x.jpg

magick gradient: x.jpg

Please also show the text output from:

magick -list format

I previously have used Magick for years, but the problem started up after I upgraded my color calibration tool a couple weeks ago. I had several issues at the time with image programs (notably Luminar), but narrowed it down to x-rite when I did the magick -list format command and saw a slew of X-rite references. I uninstalled X-Rite and reloaded an older version and Luminar started working, but ImageMagick hasn't recovered.

I did a fresh uninstall/re-install tonight to run the tests you suggested (thank you!), but this is what I am seeing now:

Microsoft Windows [Version 10.0.22621.2428]
(c) Microsoft Corporation. All rights reserved.

C:\Users\xxx>magick
Usage: magick tool [ {option} | {image} ... ] {output_image}
Usage: magick [ {option} | {image} ... ] {output_image}
       magick [ {option} | {image} ... ] -script {filename} [ {script_args} ...]
       magick -help | -version | -usage | -list {option}

magick: invalid argument for option  @ error/magick-cli.c/MagickImageCommand/991.

C:\Users\xxx>magick xc: x.jpg
magick: unable to open image 'xc:': Invalid argument @ error/blob.c/OpenBlob/3573.
magick: no decode delegate for this image format `' @ error/constitute.c/ReadImage/746.

C:\Users\xxx>magick gradient: x.jpg
magick: unable to open image 'gradient:': Invalid argument @ error/blob.c/OpenBlob/3573.
magick: no decode delegate for this image format `' @ error/constitute.c/ReadImage/746.

C:\Users\xxx>magick -list format

C:\Users\xxx>

I appreciate your assistance!

@snibgo
Copy link

snibgo commented Oct 16, 2023

So, magick -list format shows nothing at all? So IM can't read or write files. And rose:, xc: etc don't work, so IM can't even read its own built-in images. None of the coders work.

I'm afraid I have no idea what is wrong. But it is, obviously, catastrophic. Reinstalling IM should fix it, but that hasn't worked.

I assume you are running magick from an ordinary command window (aka "Dos" window), not Docker or something?

I also assume that when you did the installation, you told it the directory to contain the installation. And then you didn't move the installed files to a different directory, or different computer, or anything?

And I assume that the same username installed IM, and is running magick. If that isn't true, there may be a permissions problem.

Please say if these assumptions are right or wrong.

What is the text output from:

magick -list resource

At the command line, where magick will tell you the directory that contains magick.exe. Please post the complete text of dir /s of that directory.

If you have the dll version, magick.exe will be small, eg 25304 bytes, and there will be a subdirectory modules\coders containing many DLL files, eg

08/10/2023  21:36           230,104 IM_MOD_RL_magick_.dll

If you have the portable version, magick.exe will be large, eg

14/10/2023  23:22        20,376,792 magick.exe

... and there will be no subdirectories and no DLL files.

@fmw42
Copy link

fmw42 commented Oct 16, 2023

Are you on a 32-bit or 64-bit architecture? Might you have loaded the wrong Imagemagick for your OS?

@blueridgetog
Copy link
Author

Are you on a 32-bit or 64-bit architecture? Might you have loaded the wrong Imagemagick for your OS?

64 bit. And installed 64 bit version. Wish it would have been that easy though!

@ossnorry
Copy link

ossnorry commented Dec 5, 2023

I'm having this problem too, unusable on w11.

@HekarKET
Copy link

HekarKET commented Apr 5, 2024

I followed the instructions on GitHub and faced a similar issue. The problem persisted until I corrected the MAGICK_CODER_MODULE_PATH to C:\msys64\mingw64\lib\ImageMagick-7.1.1\modules-Q16HDRI\coders from C:\msys64\mingw64\lib\ImageMagick-7.0.6\modules-Q16HDRI\coders ( mentioned in documentation ). This fixed the error for me.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

5 participants