After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 133642 - vertical stripes when converting image to B/W
vertical stripes when converting image to B/W
Status: RESOLVED FIXED
Product: GIMP
Classification: Other
Component: General
1.x
Other All
: Normal normal
: 2.0
Assigned To: GIMP Bugs
GIMP Bugs
Depends on:
Blocks:
 
 
Reported: 2004-02-06 14:06 UTC by Antonio Arauzo Azofra
Modified: 2004-02-07 16:41 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Source image (87.45 KB, image/png)
2004-02-06 14:13 UTC, Antonio Arauzo Azofra
Details
Converted image with the stripes (13.71 KB, image/png)
2004-02-06 14:14 UTC, Antonio Arauzo Azofra
Details

Description Antonio Arauzo Azofra 2004-02-06 14:06:48 UTC
If this image http://ax5.com/selloG.png image is converted to B/W using:
Image -> Mode ->Indexed (BW No dithering)
(zoom in to 100% you will see strange stripes appear)

It doesn't happen when converting from Gray to RGB to indexed.
Comment 1 Antonio Arauzo Azofra 2004-02-06 14:13:04 UTC
Created attachment 24141 [details]
Source image
Comment 2 Antonio Arauzo Azofra 2004-02-06 14:14:50 UTC
Created attachment 24142 [details]
Converted image with the stripes
Comment 3 Dave Neary 2004-02-06 14:32:16 UTC

Confirmed with 2.0pre2. There's definitely something funny going on here.

Dave.
Comment 4 Pedro Gimeno 2004-02-07 03:29:11 UTC
The alpha channel position was incorrectly set under the precise
circumstances of this report. The following patch to
app/core/gimpimage-convert.c fixes it. Will commit later.

@@ -3047,7 +3047,10 @@ median_cut_pass2_no_dither_rgb (Quantize
    *   grayscale drawables through the rgb pass2 functions
    */
   if (gimp_drawable_is_gray (GIMP_DRAWABLE (layer)))
-    red_pix = green_pix = blue_pix = GRAY_PIX;
+    {
+      red_pix = green_pix = blue_pix = GRAY_PIX;
+      alpha_pix = ALPHA_G_PIX;
+    }
 
   has_alpha = gimp_drawable_has_alpha (GIMP_DRAWABLE (layer));
Comment 5 Pedro Gimeno 2004-02-07 10:28:59 UTC
Fixed in CVS. When revisiting the code I noticed the same problem in
the case of fixed dither (Positioned Color Dithering). Fixed as well.

2004-02-07  Pedro Gimeno

	* app/core/gimpimage-convert.c (median_cut_pass2_no_dither_rgb):
	Corrected position for alpha_pix in the case of grayscale images
	with custom or mono palette and no dither. Fixes bug #133642.

	(median_cut_pass2_fixed_dither_rgb): Ditto for fixed dither
	(Positioned Color Dither).