Announcement

Collapse
No announcement yet.

Histogram should exclude alpha channel

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Histogram should exclude alpha channel

    When an image with an alpha channel is opened in IrfanView, the alpha (transparent) channel is displayed as the same color as IrfanView's background. Then IrfanView includes this new alpha-color in the histogram. However, the new alpha-color shouldn't be included since it's not part of the original image.

    Example --
    In the attached image, the alpha channel is everything except the quarter round (alpha channel created by PhotoScissors). This can be viewed by \Image\Show channel\Alpha.

    Click image for larger version

Name:	PhotoScissors__quarter_round_with_alpha_channel__1a.png
Views:	376
Size:	26.2 KB
ID:	95949

    If this image is opened when IrfanView has a red background, the histogram is different than if the image is opened when IrfanView has a green background (or any other background). However, the original image only has one true histogram.

    Secondary request -- Display alpha channel as checkerboard pattern as is done in other graphic programs (see the following GIMP image that was captured by IrfanView) rather than as IrfanView's background color.

    Click image for larger version

Name:	GIMP__quarter_round_showing_checkerboard_alpha_channel__1a.png
Views:	293
Size:	36.4 KB
ID:	95950

    #2
    Not seeing the actual PhotoScissors attachment in my original post so trying again here.
    Attached Files

    Comment


      #3
      You could write to IrfanView and ask for support for the alpha channel. Maybe if enouh people ask, it will be added. Currently the program essentially applies and forgets the transparency upon opening. Other simple programs (FastStone, XnView) show the color of the masked area, even if it is invisible. You should forget about doing any operations with transparent images in IrfanView. Use those other tools, PixelFormer or Photoshop. They each have some benefits. In XnView you can hide the alpha, in PixelFormer, you can paint on the color and alpha independently if you want, Photoshop is good all round, but decoupling the baked alpha is very tedious.

      I think Irfan would have to do a lot of work to make sure all his filters treat the masked pixels reasonably, or many bug reports will come in.

      Comment


        #4
        I have FastStone, XnView, and GIMP. All of these can show the transparency as checkerboard. However, I'm looking for a simple (light) program that will show a histogram while ignoring the background/transparency. Faststone doesn't have a histogram. XnView's histogram is visually poor. GIMP's is just OK but GIMP isn't simple. IrfanView's is the best (visually) but doesn't give correct results since it includes the alpha channel (as background color) in its calculation of the histogram.

        Comment


          #5
          Right now the program doesn't have a special marking for the transparent area. If it blended the image with a checkerboard pattern, then white and grey would appear on the histogram. A related modification I would like to see is an exclusion of pure black and white, or normalization to the highest remaining value. This would still show the color of the semitransparent edge, but help with a variety of images like scanned, predominantly white pages.

          You need to write an e-mail to Irfan to ask for changes because he doesn't visit this forum.

          Comment

          Working...
          X