Search found 4 matches

by akr
2011-12-17T23:37:09-07:00
Forum: Bugs
Topic: "convert -level 20%,100%,0.5" doesn't preserve black
Replies: 8
Views: 18064

Re: "convert -level 20%,100%,0.5" doesn't preserve black

It is not surprised that the min is 0
because the pixel at x=42 to x=60 in dst.pgm is value 0.

The problem is the pixel at x=0 to x=41 is not value 0.
by akr
2011-12-17T22:23:41-07:00
Forum: Bugs
Topic: "convert -level 20%,100%,0.5" doesn't preserve black
Replies: 8
Views: 18064

Re: "convert -level 20%,100%,0.5" doesn't preserve black

I see.

I try to explain the problem again using the 256 pixel image.

I made a single line gradation image, src.pgm, from black to white (using Ruby).
The pixel value is 0 to 255. The value of leftmost pixel is 0.

I convert it using ImageMagick: convert -level 20%,100%,0.5 src.pgm dst.pgm

I ...
by akr
2011-12-17T20:34:22-07:00
Forum: Bugs
Topic: "convert -level 20%,100%,0.5" doesn't preserve black
Replies: 8
Views: 18064

Re: "convert -level 20%,100%,0.5" doesn't preserve black

I agree that several black pixels are exist in dst.pgm.

But that is not correspond to the black pixel in src.pgm.

I simplified the test to a single pixel black image.

The result image contains a pixel which color is grey11.

% ruby -e 'STDOUT.binmode; print "P5\n1 1\n255\n\0"' > src.pgm ...
by akr
2011-12-17T19:26:57-07:00
Forum: Bugs
Topic: "convert -level 20%,100%,0.5" doesn't preserve black
Replies: 8
Views: 18064

"convert -level 20%,100%,0.5" doesn't preserve black

I found "convert -level 20%,100%,0.5" doesn't preserve black.

I made a simple PGM file which is gradation from black to white (using Ruby).
The leftest pixel is black (value 0) and the rightest pixel (value 255) is white.

"convert -level 20%,100%,0.5" converts the black pixel to a dark gray (value ...