Page 2 of 2
Re: Strange results with clip-path in tif-image
Posted: 2007-10-08T12:11:58-07:00
by masterbp
http://www.dortheogbenny.dk/test.tif (11.4Mb)
http://www.dortheogbenny.dk/test.jpg (result of convert)
command line:
convert.exe -clip test.tif test.jpg
Re: Strange results with clip-path in tif-image
Posted: 2007-10-08T18:17:00-07:00
by magick
What exactly is the problem. We tried this command:
- convert test.tif -clip -fill red -draw "color 0,0 reset" test.png
and got a red pillow with the background untouched as expected.
Re: Strange results with clip-path in tif-image
Posted: 2007-10-08T23:05:46-07:00
by masterbp
Well - maybe the problem is my understanding of the -clip option. What is was trying to accomplish was to make the background white (i.e make all pixels outside the clipping path white).
Anyone suggestions how to do that?
Re: Strange results with clip-path in tif-image
Posted: 2007-10-09T06:38:19-07:00
by magick
This command works for us (reset everything outside the clip path to white):
- convert test.tif -colorspace RGB +clip-path #1 -fill white -draw "color 0,0 reset" test.png
Re: Strange results with clip-path in tif-image
Posted: 2007-10-09T06:47:12-07:00
by masterbp
I tried de following command:
Code: Select all
"c:\Program Files\ImageMagick-6.3.6-Q16\convert.exe" test.tif -colorspace RGB +clip-path #1 -fill white -draw "color 0,0 reset" test.png
wich gave me an png image that looked excately like the original (i.e. the clipping was apparently ignored)
Re: Strange results with clip-path in tif-image
Posted: 2007-10-09T06:59:10-07:00
by magick
Don't know what to tell you. We're running ImageMagick 6.3.6-1 under Windows and the command works fine for us (background is white as expected).
Re: Strange results with clip-path in tif-image
Posted: 2007-10-09T08:01:40-07:00
by masterbp
OK - I tried it again on a fairly clean windows install (Xp SP2).
- Downloaded and installed ImageMagick-6.3.6-1-Q8-windows-static.exe
- Downloaded sample file from http://www.dortheogbenny.dk/test.tif
- Ran command
Code: Select all
"c:\Program Files\ImageMagick-6.3.6-Q8\convert.exe" test.tif -colorspace RGB +clip-path #1 -fill white -draw "color 0,0 reset" test.png
The program gave the following warnings:
Code: Select all
convert.exe: test.tif: unknown field with tag 34152 (0x8568) encountered. `TIFFR
eadDirectory'.
convert.exe: Non-conforming drawing primitive definition `color'.
Resulting image can be seen here: http://www.dortheogbenny.dk/test.png
The resulting image does not have any white background.
Any thoughts?
Re: Strange results with clip-path in tif-image
Posted: 2007-10-09T09:01:02-07:00
by magick
Try uninstalling ImageMagick from the Control Panel->Add/Remove Programs. If you know how, make sure c:/Program Files/ImageMagick-6.3.6 folder is deleted. Now download the Q16 dynamic version of the Windows ImageMagick distribution and try your command again. If that works perhaps there is a problem with the Q8 static version of ImageMagick which we will investigate.
Re: Strange results with clip-path in tif-image
Posted: 2007-10-09T09:49:38-07:00
by masterbp
I have now tried with both of the the dynamic versions (Q8 and Q16). Every time uninstalling the previous version and deleting the empy directory. Both version gave the same result as reported in earlier posting.
I tried to run directly from IMageMagick Directory:
Code: Select all
C:\Program Files\ImageMagick-6.3.6-Q16>convert.exe c:\temp\test.tif -colorspace
RGB +clip-path #1 -fill white -draw "color 0,0 reset" c:\temp\test.png
my PATH settings is
Code: Select all
c:\program files\imagemagick-6.3.6-q16;C:\WINDOWS\system32;C:\WINDOWS;
Do you have the binary versions of IMageMagick or do you compile your self?
Re: Strange results with clip-path in tif-image
Posted: 2007-10-09T10:04:46-07:00
by magick
Sorry we can't help. We uninstalled our version of ImageMagick and reinstalled the pre-compiled binaries that are on the ImageMagick web site and issued the command. The result was a pillow with a completely white background as expected.
Re: Strange results with clip-path in tif-image
Posted: 2007-10-09T11:10:23-07:00
by masterbp
Very strange. Could you please post your resulting image so I can see the difference?