
我正在嘗試將此命令用於 ImageMagick:
convert "c:\users\****\My Documents\test.png" -transparent white test2.png
但是,我不斷收到兩個如下所示的錯誤:
convert.exe: unable to open image `c:\users\****\My':
No such file or directory @ error/blob.c/OpenBlob/2641.
convert.exe: no decode delegate for this image format `c:\users\****\My'
@ error/constitute.c/ReadImage/550.
我將 ImageMagick 安裝到我的c:\
目錄中。
這是什麼意思?
答案1
我不是 Windows 專家,但導致此問題的截斷c:\users\****\My
看起來像是我在 Linux/Unix/Mac OS X 中嘗試類似操作時看到的基本字元轉義問題。試著像這樣逃離空間:
convert c:\users\****\My^ Documents\test.png -transparent white test2.png
注意^
要避開空格。
答案2
當然,看起來My
和之間的空格Documents
被轉換程式用作參數分隔符號。
身為 Windows 專家,我不知道你會如何逃離這個空間。
實際上,我會說將 test.png 移動到不包含特殊字元的目錄字串,然後對其運行轉換。