Captured Moments » Eventually interesting stuff about Linux, Programming, Software, Photography.

Tags

  Linux     GPS     Bibble     Panorama     Web     Hugin     C++     Live     Windows     Software     Gimp     Photography     Programming     Nikon     Ubuntu     PHP     UFRaw     Qt     Sony     Usability     Weather     Work     Photoblog     Plugin     F-Spot      

My Flickr Photos

Books on blurb.com

aus der ev. Kirche Sulzbach (Ts.)
Julia und Paul
Wellner Bou

Admin area

With the new versions of GIMP there is a menu called “GEGL Operation…” with a bunch of more or less interesting image operations. GEGL will be the graphics library for the future GIMP releases and brings 16bit support among other features to GIMP, when the transition will be completed.

c2g.pngGEGL c2g dialog with default settings

Within those GEGL Operations there is one operation called simply c2g (color2gray). Applying c2g is quite slow, but the results are at least interesting. It seems to be similar to the HDR and tone mapping hype of over-processing images and the results are similar, as this is a kind of tone mapping, just with black and white conversion applied.

There are a lot of bad examples tagged c2g on Flickr. Have look at this images. Doesn’t it remind you of the HDR groups in Flickr (or wherever)? Horrible halos, overall dull pictures as the high contrast and lighting is the same in all areas of the image. Aggressive, because of the high contrasts and because of the business of the subjects.

This method was tested by Rolf in his Meet The Gimp Podcast and Joel Cornuz is blogging in his Linux Photography Blog about it with the title “Could this be the ultimate black and white converter??”.

Of course it is not!

wengen_original_in_color.jpgOriginal color photo used
for this c2g conversion

But there is an interesting use case for this GEGL operation. Especially with landscape photography it helps to get out structure and contrast out of the sky, which in most cases is a good thing.

How to use c2g

Unfortunately, there is very few documentation. But on the GEGL site the most important parameters are explained. So, leaving the technical explanations aside, I am trying to give a short introduction on how to apply the c2g parameters and which effects they have on the result.

Radius

As explained on the GEGL site, the radius is the radius in pixel which will be taken into account while tone mapping. This means, that with a smaller radius the tone mapping and halo effects will be much more visible. You can imagine the radius as the size of an area of your image which will be modified so that you will have tones between real black and real white. Increasing the radius, the tone mapping and halo effects won’t be so strong any more. A small radius will give you small structures, abrupt and very contrasty edges, a busy appearance. A bigger radius the opposite, more calm, a more consistent impression.

Following examples are calculated with an image size of 1800×1200 with default settings but different radiuses and reduced before uploading. In the first photo a radius of 100 is used, in the second one a radius of 384 (default setting) and the third one is processed with a radius of 1100 pixels.

wengen_r0100-s03-i23.jpgwengen_r0384-s3-i23.jpgwengen_r1100-s03-i23.jpgEffects on using different radiuses

You can see very clearly here, that a radius of 100 pixel is way to small. The clouds in the lower part of the photo for example are dark in the middle, which should not occur. So I have to increase the radius at least to a size which covers the clouds including a part of the darker areas below and above the clouds, too.

Of course, the value of the radius you use depends on the image size and the size of the subjects you have in your image. It should be large enough to cover important dark or bright areas in your photo which should remain bright or dark.

Samples

wengen_r384-s50-i23.jpg50 samples per iteration

More samples will smooth the contrasts more. The local differences between brighter and darker areas won’t be so high any more. You can avoid halos by increasing the number of samples. The overall look of the photo will be much more consistent. Using more samples will dramatically reduce the noise caused by c2g.

Iterations

wengen_r384-s03-i60.jpg60 iterations

More iterations don’t make a lot of difference. It will smooth the noise and the artifacts caused by c2g a bit, but won’t change much more in the image. Compare the following example with the default settings (see above).

Some recommendations

  • Avoid halos! Using a larger radius, more samples and don’t exaggerate it with the strength slider.
  • Be sure to keep darker and brighter areas in your photograph which are big enough to have any effect on the observer. You should not use a radius value which is smaller than those areas in your photo. Otherwise the overall brightness of your photo will be the same (causing dull and boring photos), although there are huge contrasts in small areas (causing aggressive and busy photos).
  • Be cautious. Especially in this case it helps if you wait one or two days before publishing your tone mapped photo as after a while you won’t be dazzled by the high contrast impressing effect any more.
  • Pixels do count here. Even if you are planning to resize the image later, use a higher resolution to process it. The quality will improve.
  • Use few iterations for preview, increase this value when producing the final photo as the noise and the artifacts (some lines similar to fingerprint lines) will reduce.
  • Use as much samples as possible: as much as your desired result tolerates. This will smooth your photo a little bit, reduce noise and remove any artifacts caused by c2g.
  • Be patient. c2g is slow, especially if you use higher values for radius, samples and iterations. Don’t publish bad images just because you don’t want to wait for a better result.

In this case, my final version (Flickr Link) is a combination with the version processed with a lot of interations and the versions processed with a lot of samples. The smoother one is used as background and the more contrasty version as top layer with reduced opacity. Additionally I created a layer mask reducing the halo effect on the lower left roof.

wengen_final_bw.jpgFinal black and white version

This c2g operation will become much more interesting when GIMP will be able to do this on 16bit images!

  1. Mathias

    Hi,
    this is Mathias from www.MeetTheGimp.org or www.Gedankenquirl.de .
    Thank you for those neat insights into this tool!
    No criticism about your opinion that there is no perfect tool for anything. As many other stuff it has some cool features that might give great outputs if you use it in the right way. How you will destroy images be using it too intensely was well shown with the Flickr link. That’s horrible!
    Thanks again and have fun gimping!
    Mathias

  2. nico

    Thank you, great work on c2g’s parameters. I hope this will help me, when doing experiments with c2g.

  3. elfriede

    thanks for your explanations,
    is there any differences for Black and White portraits? meaning how to impress with portraits? anyway thanks for this great tutorial. btw nice pics!

  4. paul

    What do you mean?

  5. elfriede

    mean any advice in do’s and donts when coverting color to b/w portraits.

  6. paul

    There is no do and don’t, this is a question of your creativity, the aims of your work and last but not least the presentation.

    But especially with portraits you can use the channel mixer to influence the expression of your portrait. As the skin has a relatively high part of red color, boosting or decreasing the red channel may change the expression totally and give you more or less contrast.

    Add comment

    Fill out the form below to add your own comments

    User data





    Add your comment