Channel editing

Here everybody can post his problems with PhotoLine
cathodeRay
Mitglied
Beiträge: 151
Registriert: So 15 Nov 2015 12:37

Channel editing

Beitrag von cathodeRay »

Despite what it says in the manual(!), I often find myself looking at individual channels to see which has the best data and/or making use of data specific to a particular channels. I've cracked how to do a luminosity mask in LAB mode (and related whole channel stuff) but am stumped when it comes to working/editing part of a channel. Take this particular repair I am working on, where a blue-ish stain/damage has affected a localised area (a few % if that of the whole frame):
blue_damage.jpg
Now, it's on the edge of the frame so I could just crop it off but there is a lot of historical interest in the OK not very focused careened ships, so I want to keep this part of the image, and so get rid of that blue blemish. I could do hours of work with the patch/healing brush (BTB I think the patch tool may still be in beta - often behaves oddly) tools but what about looking at and using the channel data?

Unsurprisingly, the blue channel is most affected, the green channel moderately so, and the red channel hardly affected at all. It seems to me if I could copy the red channel data to the blue and green channels then the affected areas would darken and tend towards grey - possibly making them much less visible, and easier to touch in. If you copy the image and open it in PL and look at the channels you will see what I mean.

So I made a relevant selection (as seen above), and working in channels and selecting the red channel went to edit > copy: no dice. Even if I had been able to copy the selected part of the red channel, the only paste options are as layer/document. I can't paste directly into the blue/green channels. I'm not even sure if I can simply paint on a single channel. In effect, the channel view seems to be 'view only', with the only way to do anything with it is whole channel > layer and then do layerly things with that layer.

Is working on (selected parts of) individual channels as the actual channel (rather than an added layer) a no-no in PL or am I missing something?

A couple of other observations/thoughts:

1. Would be useful having/being able to set keyboard shortcuts for moving between channels in channel panel.

2. The cursor/crosshairs often become very difficult/impossible to see against mid-toned/greyish backgrounds - would be useful if it lightened/darkened as needed to make it easier to see in these areas.

cathodeRay
Du hast keine ausreichende Berechtigung, um die Dateianhänge dieses Beitrags anzusehen.
bkh
Betatester
Beiträge: 3674
Registriert: Do 26 Nov 2009 22:59

Re: Channel editing

Beitrag von bkh »

cathodeRay hat geschrieben:So I made a relevant selection (as seen above), and working in channels and selecting the red channel went to edit > copy: no dice. Even if I had been able to copy the selected part of the red channel, the only paste options are as layer/document. I can't paste directly into the blue/green channels.
You can use "Tool -> Channel Mixer" to mix the red channel into the blue/green channels, also works as a non-destructive adjustment layer (so you can adjust the selection afterwards).

There is also "Tool -> Change Channels" which allows to swap entire channels around (it doesn't respect the selections because you can even turn selections to channels and viceversa).
cathodeRay hat geschrieben: I'm not even sure if I can simply paint on a single channel.
You can. Most of the painting tools allow you to choose the affected channels in the Tool Settings. This even works with virtual channels, so you can work, e.g., on the L channel of an RGB image.
cathodeRay hat geschrieben: In effect, the channel view seems to be 'view only', with the only way to do anything with it is whole channel > layer and then do layerly things with that layer.
Correct.

Cheers

Burkhard.
Benutzeravatar
Hoogo
Betatester
Beiträge: 4031
Registriert: So 03 Jul 2005 13:35
Wohnort: Mülheim/Ruhr

Re: Channel editing

Beitrag von Hoogo »

Ken once started a thread about lens flares, the task should be quite similar.
----------------
Herr Doktor, ich bin mir ganz sicher, ich habe Atom! /Doctor, doctor, I'm sure, I've got atoms!
Benutzeravatar
photoken
Mitglied
Beiträge: 2162
Registriert: Sa 28 Sep 2013 01:25

Re: Channel editing

Beitrag von photoken »

cathodeRay hat geschrieben: I'm not even sure if I can simply paint on a single channel.
Sure. The Paint tool allows you to select the channel(s) to affect.

The Lens Flare Experiment mentioned by Hoogo contains a lot of useful examples for this kind of work. The corrections are even easier now because PL's Brighten and Darken brushes now allow affecting individual channels. In other words, instead of copying the less affected area from one channel to the other channels, simply use the Darken tool to independently correct the area on each channel. One of these days I'll get around to updating that Experiment with examples of using those burn and dodge tools for correcting lens flares and discolorations....
cathodeRay hat geschrieben: Is working on (selected parts of) individual channels as the actual channel (rather than an added layer) a no-no in PL or am I missing something?
If you turn off the visibility of all channels except the one you're interested in so that it's the only one showing in the main editing window and is also the selected channel, all PL's functions will operate on that channel only.
cathodeRay hat geschrieben:2. The cursor/crosshairs often become very difficult/impossible to see against mid-toned/greyish backgrounds - would be useful if it lightened/darkened as needed to make it easier to see in these areas.
Yes. I've already reported this in the beta testing forum.

P.S., You're right about the Patch tool -- it was a beta tool that inadvertently made it into a general release. It's very useful as is (see this post and the subsequent ones: http://www.pl32.com/forum3/viewtopic.ph ... ool#p27543), but it definitely needs a slider to control the amount of feathering, at least.
Ken
Yes, I think it can be eeeeeasily done....
Just take everything out on Highway 61.
cathodeRay
Mitglied
Beiträge: 151
Registriert: So 15 Nov 2015 12:37

Re: Channel editing

Beitrag von cathodeRay »

Thanks for your helpful replies. Unless I'm missing something, the Channel Mixer can put the red data in the blue and green channels (confirmed by inspecting each channel), but the output is always greyscale. On the plus side, if set as an adjustment layer, I can limit the are affected by white painting on black in the adjustment layer mask, so that's good, but the affected area is greyscale...

I had in fact tried Tools > Change Channels (R > clipboard then clipboard > G and B) but had the same problem (which I half expected - if each channel is set to the same value, R=G=B, then it's a greyscale). What I am trying to do is decrease (make darker, move away from 255 towards 0) the blue level in the affected areas in the blue channel.

I did manage to get some darken brush painting to work on the blue channel but the effect was odd - it turned the affected areas yellower (ie a blue to yellow shift seemed to be happening). Maybe it's not that odd... By now, PL was beginning to groan and needed a de-coke so I closed it down and went through Ken's useful Lens Flare tutorial and applied many of the same techniques. Sometimes the patch tool worked (used mainly in the sky), sometimes it didn't. The Healing Brush seemed to draw in from a wider area and affected a wider area than the brush circle covered. But I think it has reached a 'good enough' version, for now at least. Bear in mind is is right at the edge of the whole image, and in fact is probably less than 1% of the total image. I also noticed there is some very odd ghosting (mast x 2) in the original image I posted earlier which I didn't notice at the time! Here is the original image alongside the 'good enough' image:
blue_damage-2.jpg
cathodeRay
Du hast keine ausreichende Berechtigung, um die Dateianhänge dieses Beitrags anzusehen.
Benutzeravatar
Herbert123
Mitglied
Beiträge: 2173
Registriert: Sa 12 Mai 2012 21:38

Re: Channel editing

Beitrag von Herbert123 »

I agree that it would be extremely helpful to be able to select a specific channel and work directly in it: currently the workflow is rather indirect, and often convoluted.

And there are several workflow inconsistencies:
  • when right-mouse clicking on the eye of a channel, no pop-up menu appears, and it is not possible to show the active channel only. But we are allowed to alt-click in the same eye icon? That is inconsistent with how the layer eyes work.
  • with only one channel active and visible, the paint tools activate for only that one channel. However, when I paint in the main view, all channels are affected anyway. That does not make sense to me.
  • with only one channel active and visible, I would expect to be able to copy only parts of that channel in the view, and be able to activate a different channel and paste that information in it. Or at least Photoline would grab the information from the active channel only, and paste that information as a new layer. Alas, this does not work. Photoline does not allow for direct channel manipulation with selections.


I suppose it is all based on the fact that channels are basically "viewing only". just like Ken says. It is a crying shame, because it really complicates the workflow with channels in my opinion. I love how we can paint directly in a channel with the channel buttons - but being able to directly work with the pixel selections in the channels would be incredibly helpful. I used to do that all the time in Photoshop: in Photoline it is quite awkward.

I think this is also due to the fact that we cannot directly select and transform pixels in Photoline: first a new layer must be created, transformed, and merged back into the original. Since it is impossible to directly manipulate pixels with selections in Photoline, I would guess it will likewise be impossible to directly manipulate the pixel information in the channels.
Which is indeed the case, unfortunately.

One solution would be: allow the selection (lasso) tools to work in specified channels, just like the painting tools.
/*---------------------------------------------*/
System: Win10 64bit - i7 920@3.6Ghz, p6t Deluxe v1, 48gb (6x8gb RipjawsX), Nvidia GTX1080 8GB, Revodrive X2 240gb, e-mu 1820, 2XSamsung SA850 (2560*1440) and 1XHP2408H 1920*1200 portrait
Benutzeravatar
Hoogo
Betatester
Beiträge: 4031
Registriert: So 03 Jul 2005 13:35
Wohnort: Mülheim/Ruhr

Re: Channel editing

Beitrag von Hoogo »

cathodeRay hat geschrieben:Thanks for your helpful replies. Unless I'm missing something, the Channel Mixer can put the red data in the blue and green channels (confirmed by inspecting each channel), but the output is always greyscale.
On the top of the dialog there are buttons to choose between different output channels: Luminance, grey, or RGB (or whatever color model your layer has). When you want to output RGB, you have to press each button after the other and adjust all sliders for each separately. For your picture these values looked good enough to me:
Output R: 100/0/0
Output G:45/95/-30
Output B: 90/60/-15
----------------
Herr Doktor, ich bin mir ganz sicher, ich habe Atom! /Doctor, doctor, I'm sure, I've got atoms!
bkh
Betatester
Beiträge: 3674
Registriert: Do 26 Nov 2009 22:59

Re: Channel editing

Beitrag von bkh »

cathodeRay hat geschrieben:Thanks for your helpful replies. Unless I'm missing something, the Channel Mixer can put the red data in the blue and green channels (confirmed by inspecting each channel), but the output is always greyscale. On the plus side, if set as an adjustment layer, I can limit the are affected by white painting on black in the adjustment layer mask, so that's good, but the affected area is greyscale...
If you don't want grey, you'll have to mix the colours in different proportions (for a blueish cast, decrease the amount of original red which goes into the red and green channels). That's another advantage of using the channel mixer. Hoogo's values are probably much better because they retain some of the original colour.

Cheers

Burkhard.
Benutzeravatar
photoken
Mitglied
Beiträge: 2162
Registriert: Sa 28 Sep 2013 01:25

Re: Channel editing

Beitrag von photoken »

cathodeRay hat geschrieben: I did manage to get some darken brush painting to work on the blue channel but the effect was odd - it turned the affected areas yellower (ie a blue to yellow shift seemed to be happening).
Yes, that happened here, too.

My approach to these problem images:
  1. I work on the gray image of each channel, one channel at a time. I use the Darken tool (usually targetting the Midtones) to darken the affected area to match the rest of the channel's values as best as I can. After this step, there's usually discolourization (as you've noticed):
    damage channel work 01.jpg
  2. Then I display the full RGB image and work with the Brighten and Darken tools for the final colour correction and value correction. In this case, the Brighten tool on the blue channel only removed the yellow cast:
    damage channel work 02.jpg
In other words, I find it easier to first do the gross correctons on the gray image of each channel so that I'm not distracted by the colours. Then I can work on the image in full colour to make the final subtle corrections.

I didn't do this next step on this example, but the last step is usually to use the Color Picker to select unaffected colours and paint on the affected areas using a blend mode of "Color" for the final touchup.
Du hast keine ausreichende Berechtigung, um die Dateianhänge dieses Beitrags anzusehen.
Ken
Yes, I think it can be eeeeeasily done....
Just take everything out on Highway 61.
cathodeRay
Mitglied
Beiträge: 151
Registriert: So 15 Nov 2015 12:37

Re: Channel editing

Beitrag von cathodeRay »

Hoogo's Channel Mixer setting do produce a pleasing greyscale image, but neither that (nor a tinted greyscale) is what I am after. The original image is a less than tripod perfect but nonetheless precious (because of content) Kodachrome from the mid 1960s belonging to a friend which I am trying to restore to full colour glory. The old ship even though right at the edge of the frame is of interest because it is a marker of time when the photo was taken, now long since gone (otherwise I would have fixed it in approx one second by cropping it off). I was hoping that because the blue damage was so distinctive in one channel but not another that it might be possible to 'dial out' the damage, and the short answer I think is yes, it can be done, but only to produce a greyscale (or a tinted greyscale). The clue is perhaps in the name: the Channel Mixer mixes the channels to produce a greyscale.

Ken's tool/brush/blend based approach certainly produces results (with the final version in the Lens Flare thread showing what is possible). I presume the 'magical' appearance of the yellow is merely a manifestation of the fact that in world of digital colour subtracting blue really is the same as adding yellow (though I have yet to satisfy myself how this is happening at the RGB numbers level: 0,0,255 > 0,0,128 just gets less blue, no yellow in sight. To get any yellow, I have to add red and green: so somehow, working on only the blue channel - only the blue channel - actually does affect the other channels. This is confirmed by before and after sampling the affected colours: where the bright blue has been reduced and a yellow appeared (by working on only the blue channel) say on part of the car window frame, the RGB values go from 113,158,197 to 131,169,128: yes, the blue has been reduced, but both the red and green have increased - despite working on only the blue channel). Weird, or what (am I missing)?

Baffled of Basildon AKA cathodeRay
cathodeRay
Mitglied
Beiträge: 151
Registriert: So 15 Nov 2015 12:37

Re: Channel editing

Beitrag von cathodeRay »

PS Just discovered the Hue Editor, which seems to be an ordinary Hue/Sat box on steroids, or rather curves. Being curves, effects gradients and transitions are handled more smoothly. The possibilities may be even be infinite...

cathodeRay
Benutzeravatar
Hoogo
Betatester
Beiträge: 4031
Registriert: So 03 Jul 2005 13:35
Wohnort: Mülheim/Ruhr

Re: Channel editing

Beitrag von Hoogo »

cathodeRay hat geschrieben:Hoogo's Channel Mixer setting do produce a pleasing greyscale image...produce a greyscale (or a tinted greyscale).
Now I see. Yes, the result was really very blue without any other color. Color and saturation come from differences between the channels, and the way that I mixed much red into everything and even removed blue reduced these differences a lot. The result goes very well for the car, the sky, the trees, the boat, but terrible for the beach.
For the beach this values are better:
R=100/0/0
G=40/84/29
B=72/33/-11
Just mask the different layers to create the patches, a rough mask should do.
cathodeRay hat geschrieben:This is confirmed by before and after sampling the affected colours...the RGB values go from 113,158,197 to 131,169,128: yes, the blue has been reduced, but both the red and green have increased - despite working on only the blue channel). Weird, or what (am I missing)
There were quite some methods in that thread by Ken. You used the "darken brush"?
----------------
Herr Doktor, ich bin mir ganz sicher, ich habe Atom! /Doctor, doctor, I'm sure, I've got atoms!
bkh
Betatester
Beiträge: 3674
Registriert: Do 26 Nov 2009 22:59

Re: Channel editing

Beitrag von bkh »

cathodeRay hat geschrieben:The clue is perhaps in the name: the Channel Mixer mixes the channels to produce a greyscale.
Not a problem of the channel mixer (which can do a lot more than produce a tinted greyscale), but of your approach – replacing one or two channels by essentially the third loses a lot of colour information.

cathodeRay hat geschrieben: I presume the 'magical' appearance of the yellow is merely a manifestation of the fact that in world of digital colour subtracting blue really is the same as adding yellow (though I have yet to satisfy myself how this is happening at the RGB numbers level: 0,0,255 > 0,0,128 just gets less blue, no yellow in sight. To get any yellow, I have to add red and green: so somehow, working on only the blue channel - only the blue channel - actually does affect the other channels.
Not quite true. You'll almost never find pure blue in an image, in most cases, it contains some red and yellow. In your example, if you change (113,158,197) to (113,158,128) it will turn from blue to greenish.

cathodeRay hat geschrieben:This is confirmed by before and after sampling the affected colours: where the bright blue has been reduced and a yellow appeared (by working on only the blue channel) say on part of the car window frame, the RGB values go from 113,158,197 to 131,169,128: yes, the blue has been reduced, but both the red and green have increased - despite working on only the blue channel).
If you work only on the blue channel (by selecting the blue channel only in the tool), only the blue channel should be affected. Or maybe you are measuring display RGB instead of the RGB value in the layer – if you are using colour management, the two are usually different, what's pure blue in sRGB need not be pure blue for your screen.

Cheers

Burkhard.
maxwell
Mitglied
Beiträge: 222
Registriert: Mo 01 Jul 2013 20:53

Re: Channel editing

Beitrag von maxwell »

Hi,

to repair channels of old images normaly I copy all channels to layers and create a new black and white image, which corresponds to the channel I like to get. E.g.often also blend modes have to be applied. In the last step the resulting image is copied back into the channel which had to be fitted. As I know those of you working a lot with photoline don‘t like to process channels on a layer base, but often I cannot obtain the wanted result in another way. E.g. how can I scale a channel and subtract it from a different channel (blend modes), with standard PL tools.

Cheers

Josef
cathodeRay
Mitglied
Beiträge: 151
Registriert: So 15 Nov 2015 12:37

Re: Channel editing

Beitrag von cathodeRay »

Burkhard - please don't think I'm being critical, I'm not, I'm just reporting on (my) expectations (working on only the blue channel ie it alone is active/selected will affect only the blue channel) and my observations (that a change on only the blue channel does alter the other channels). It seems to me that is something worth being aware of. I also 'get' that the Channel Mixer is a sort of dial-a-recipe for getting a greyscale with different RGB mixes (hence the name, Channel Mixer). The actual sampling I did was on the main image after the relevant channel editing. As noted before, I do appreciate that if you put say the red channel into the green and blue channel (however you go about doing it) you are losing a lot of colour data, hence the greyscale. Once every pixel has R=G=B it is a greyscale.

I'm keeping to the simplest colour management I can. My monitor is calibrated and profiled, but everything is done in sRGB colour space. No fancy wide gamut stuff. What looks like pure white/grey/black on my screen should have R=B=G when colour sampled (generally it does) ie what is white/grey/black in the image/file is white/grey/black on my screen. My scanner is not profiled/calibrated - I figure I am going to be changing colours anyway, so there is no need, in fact all it does is introduce another layer of complication. The most important thing is consistency between my monitor and other monitors, TVs etc (ie the displays the image is likely to be viewed on, most of which will be based on sRGB) and print output (done at the local photographic shop, where they use sRGB as input and turn off all colour correction etc settings so nothing 'corrects the corrections'). So far, the prints have been pretty reasonable, not perfect, but in most cases certainly 'close enough', as in horseshoes and hand grenades.

Hoogo - I used mainly the darken brush on the blue channel (though it was a bit erratic in whether it 'stuck') and got the yellowing effect which Ken confirmed. This is really the manifestation of what I was getting at in the previous paragraph and posts passim: you may think you are editing only blue, but (presumably though I don't know because blue and yellow are opposites) in fact you are also affecting the red and green channels to get some yellow.

The Hue Editor, mentioned earlier, seems very promising. It seems to be to the usual Hue/Sat adjustment dialog what Curves are to Levels. Used in HSV, you can use a curve (with the options to eye-dropper control points, add static/locking control points etc) on hue, saturation and brightness independently. Here's a rough go, having done an 'automask' with a fairly wide tolerance (30%) to select yellow areas before using a Hue Editor Adjustment Layer. Some green has appeared on the beach, but most of the yellow has gone, and just as importantly the transitions are smooth, the colours look 'natural', and no other new artefacts have appeared, apart from the green on the beach. Even better, it only took a minute or so to do, and the adjustments were intuitive, ie I selected yellow and moved it towards blue on the Hue Editor hue curve:
Hue Editor.jpg
cathodeRay
Du hast keine ausreichende Berechtigung, um die Dateianhänge dieses Beitrags anzusehen.