ImageMagick with Execute Command Arguments

Post Reply
User avatar
Terkelsen
Advanced member
Posts: 297
Joined: Thu Sep 08, 2011 5:08 pm
Contact:

ImageMagick with Execute Command Arguments

Post by Terkelsen »

I hope someone can explain to me how this works with Execute Command.

I have made a simple flow that converts Tiff-files with an AdobeRGB profile to sRGB JPG. I'm using ImageMagick and Execute Command in Switch.

It all works fine when using this Argument:
"%1[0]" -profile "C:/WINDOWS/System32/spool/drivers/color/sRGB.icc" "%2"

However, when using this:
"%1" -profile "C:/WINDOWS/System32/spool/drivers/color/sRGB.icc" "%2"

...Switch messages returns this: Cannot complete sendToSingle() for 'C:/Users/Erik/AppData/Roaming/Enfocus/Switch Server/temp/73/ScriptElement/22/51/ExecuteComandResult/T1038_7343__1F.jpg'

Can someone explain the difference between "%1[0]" and "%1"? What does [0] do?

Properties are set like this
Skærmbillede 2018-11-08 kl. 10.28.43.png
Skærmbillede 2018-11-08 kl. 10.28.43.png (35.77 KiB) Viewed 4422 times
jan_suhr
Advanced member
Posts: 586
Joined: Fri Nov 04, 2011 1:12 pm
Location: Nyköping, Sweden

Re: ImageMagick with Execute Command Arguments

Post by jan_suhr »

[0] tells ImageMagic to use the first layer in the TIFF
Jan Suhr
Color Consult AB
Sweden
=============
Check out my apps
User avatar
Terkelsen
Advanced member
Posts: 297
Joined: Thu Sep 08, 2011 5:08 pm
Contact:

Re: ImageMagick with Execute Command Arguments

Post by Terkelsen »

Thank you, Jan.

Strange however, since the Tiff-file only contains one layer. It is named "Layer 1" rather than just "Background", which might be the reason?
jan_suhr
Advanced member
Posts: 586
Joined: Fri Nov 04, 2011 1:12 pm
Location: Nyköping, Sweden

Re: ImageMagick with Execute Command Arguments

Post by jan_suhr »

Yes maybe, you could try with [1] which will take the next layer
Jan Suhr
Color Consult AB
Sweden
=============
Check out my apps
Post Reply