possible bug -compose blend IM 6.7.8.8 Q16

Post any defects you find in the released or beta versions of the ImageMagick software here. Include the ImageMagick version, OS, and any command-line required to reproduce the problem. Got a patch for a bug? Post it here.
Post Reply
User avatar
fmw42
Posts: 25562
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

possible bug -compose blend IM 6.7.8.8 Q16

Post by fmw42 »

IM 6.7.8.8 Q16 Mac OSX Snow Leopard.

-compose blend is not working correctly as far as I can tell just now in IM 6.7.8.8, though it works fine in IM 6.7.8.7 and below

Input:
Image



Test1 -- using mix of 100% should produce simply the blurred image.

IM 6.7.8.8
convert lena3.jpg \( +clone -blur 0x2 \) -define compose:args=100% -compose blend -composite lena3_im_100.jpg
Image


IM 6.7.8.7
imt convert lena3.jpg \( +clone -blur 0x2 \) -define compose:args=100% -compose blend -composite lena3_imt_100.jpg
Image




Test2 -- using mix of 0% should produce simply the input image.

IM 6.7.8.8
convert lena3.jpg \( +clone -blur 0x2 \) -define compose:args=0% -compose blend -composite lena3_im_0.jpg
Image


IM 6.7.8.7
imt convert lena3.jpg \( +clone -blur 0x2 \) -define compose:args=0% -compose blend -composite lena3_imt_0.jpg
Image
User avatar
magick
Site Admin
Posts: 11064
Joined: 2003-05-31T11:32:55-07:00

Re: possible bug -compose blend IM 6.7.8.8 Q16

Post by magick »

You want 100%x instead of 100%. Recall we standardized how percentages work in the geometry and 100%x is now equivalent to the older buggy geometry parser of 100%.

Why? I would though the geometry parser would return just 100 for rho, and the flags percent, and 'x' (depending on which of the two was given.

For Border, the geometry should be checked further.

I think it may be better to put it back, and we go with IMv7 percent escape for all operation args.
(still working on escapes in settings, but was side tracked by personal life!)
User avatar
fmw42
Posts: 25562
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

Re: possible bug -compose blend IM 6.7.8.8 Q16

Post by fmw42 »

magick wrote:You want 100%x instead of 100%. Recall we standardized how percentages work in the geometry and 100%x is now equivalent to the older buggy geometry parser of 100%.
OK. I did not know all that carried over everywhere, especially to blend!

But I did not recall that we changed the meaning of a single value without the x? I thought all we did was make Wx% and xH% behave similarly?

The meanings of one and two value %, in -border and -compose blend, seem to me to need to be handled differently.

In -border one value should apply to each dimension. In -blend, one value should not be used for both images, but should be equivalent to image1% x (100-image1%).

Please clarify how single value % are being treated with and without the x for things like blend, dissolve, displace, etc!

I am likely going to have to go back and fix about 20 scripts, if this is the case.
Post Reply