2.2. Kanaldialogen

Figur 15.10. Kanaldialogen

Kanaldialogen

Kanaldialogen er staden du bruker for å utføre arbeid direkte på kanalane, både å redigere og gjere andre endringar. Kanalane vert brukte på to måtar. Det er difor dialogen er delt i to. Den første delen er for fargekanalar og den andre for utvalsmasker.

Color channels apply to the image and not to a specific layer. Basically, three primary colors are necessary to render all the wide range of natural colors. As other digital software, GIMP uses Red, Green, and Blue as primary colors. The first and primary channels display the Red, Green, and Blue values of each pixel in your image.

Next to the channel name is a thumbnail displaying a grayscale representation of each channel, where white is 100% and black is 0% of the primary color. Alternatively, if your image is not a colored but a Grayscale image, there is only one primary channel called Gray. For an Indexed image with a fixed number of known colors there is also only one primary channel called Indexed.

Then there is an optional channel called Alpha. This channel displays transparency values of each pixel in your image (See Alpha Channel in Glossary). In front of this channel is a thumbnail displaying a grayscale representation of the transparency where white is opaque and visible, and black is transparent and invisible. If you create your image without transparency then the Alpha channel is not present, but you can add it from the Layers dialog menu. Also, if you have more than one layer in your image, GIMP automatically creates an Alpha channel.

[Notat] Notat

GIMP har ikkje støtte for fargemodellane CMYK og YUV

Figur 15.11. Biletkomposisjon med kanalar

Biletkomposisjon med kanalar

Raudkanal

Biletkomposisjon med kanalar

Grønkanal

Biletkomposisjon med kanalar

Blåkanal

Biletkomposisjon med kanalar

Alfakanal

Biletkomposisjon med kanalar

Alle kanalane


Biletet heilt til høgre er sett saman av dei fire kanalane, raud, grøn, blå og alfa. Sjakkbrettmønsteret viser gjennomsiktige område. Sidan kvit farge i den brukte fargemodellen er sett saman av alle primærfagane, vil kvit vere kvitfarga (100 %) i alle kanalane. Svart er mangel på farge, og vil difor visast som svart (0 %) i alle kanalane. Den raude hatten er synleg i raudkanalen, men ikkje i dei andre. Dette gjeld for alle reine grøne eller blå fargar også. Dei er berre synlege i respektive kanalar.

2.2.1. Aktivering

Dette er ein dialog som kan limast inn i andre dialogvindauge. Sjå nærare om dette i Del 2.3, «Dialogar og samlevindauge («dokker»)».

Du har tilgang til dialogvindauget

  • frå biletmenyen via VindaugeDialogvindaugeKanalar

  • eller frå fanemenyen ein annan dialogmeny ved å klikke på fanen og velje Legg til faneKanalar

Dersom minst eitt dialogvindauge er ope, kan du i menyen Vindauge finne ei liste over løyste vindauge. Du kan i tilfelle løfte banedialogen frå biletmenyen: VindaugeKanalar.

2.2.2. Using the Channels dialog

2.2.2.1. Oversyn

The channels at the top are the color channels and the optional Alpha channel. They are always organized in the same order and they cannot be removed. In the middle are two lock buttons, that show the lock status for the currently selected channel in the bottom area. The bottom area shows a list of selection masks. Every channel appears in the list with its attributes, including a thumbnail and its name. A right-click in a channel list entry opens the channel context menu.

2.2.2.2. Channel lock attributes

Above the list of selection mask channels are two check boxes that show the lock attributes state of the currently selected mask channel.

Lås pikslar

The paintbrush icon shows whether «lock pixels» is enabled (highlighted) for the current channel. When this is enabled, the channel is locked for any action that changes the pixels, meaning there will be no changes done to this channel.

Lock position and size

The cross-with-arrows icon shows whether «lock position and size» is enabled (highlighted) for the current channel. When this is enabled, the channel is locked for any action that changes the position or size.

2.2.2.3. Kanaleigenskapane

Kvar kanal vert vist i lista saman med attributta for kanalen. Dette er nokså likt det som er brukt for lagattributta:

Endra elementvisinga

I utgangspunktet er alle kanalane, og såleis også alle fargane, synlege. Dette vert vist med eit augesymbol. Klikk på symbolet for å slå av maska, eller på den tomme plassen for å slå maska på.

Lenk saman kanalar

The channels representing selection masks (in the lower part of the channel list) may be grouped using the button with the «chain» symbol. All channels that have the chain enabled will be affected in the same way by operations applied to any one of them.

Primary color channels (the default channels in the upper part of the channel list) may be grouped too. By default, all color channels (and the alpha channel) are selected, their list entries are highlighted. Operations will be performed on all channels. By clicking on a channel list entry you can deactivate this channel. Operations like colorizing a layer will then be applied to the selected («grouped») channels only. Clicking on the deactivated list entry will activate the channel again.

Miniatyr

A small preview icon represents the effect of the channel. This preview can be enlarged by holding down the left mouse button on it.

Kanalnamn

The name of the channel, which must be unique within the image. Double-clicking on the name of a selection mask channel will allow you to edit it. The names of the primary channels (Red, Green, Blue, Alpha) can not be changed. Double-clicking on the preview icon will open a dialog where you can set all channel attributes.

[Obs] Obs

Activated channels appear highlighted in the dialog. If you click on a channel in the list you toggle activation of the corresponding channel. Disabling a color channel red, blue, or green has severe consequences. For instance if you disable the blue channel, all pixels from now on added to the image will not have a blue component, and so a white pixel will have the yellow complementary color.

2.2.2.4. Handtering av kanalane

Below the channel list is a set of buttons allowing you to perform some basic operations on channel list.

Ny kanal

This creates a new channel. A dialog will open where you can set the Channel name, the Color tag, the channel attributes and lock attributes, and finally the Opacity and color used for the mask in the image window. A click on the color button displays the GIMP color selector where you can change the mask color. If you press the Shift key while clicking the New Channel button, the New Channel Dialog will not be opened. Instead the new channel will be created with the same settings as used previously. This new channel is a channel mask (a selection mask) applied over the image. See Selection Mask

Løft kanalen

Only available for selection masks: here you can move the channel up in the list. Press Shift key to move the channel to the top of the list.

Senk kanalen

This moves the channel down in the list. Press the Shift key to move the channel to the bottom of the list.

Kopier kanalen

This allows you to create a copy of the active channel. The name of the new channel is suffixed with a number.

[Tips] Tips

Du kan også kopiere ein fargekanal eller alfakanalen. Denne kopien kan du så bruke som eit utval i biletet.

Replace the Selection with this Channel

Here you can transform the channel to become a selection. By default the selection derived from a channel replaces the active selection. You can change this by using control keys.

  • Shift: the selection derived from a channel is added to the active selection. The final selection is merged from both.

  • Ctrl: the final selection is the subtraction of the selection derived from a channel from the active selection.

  • Shift+Ctrl: the final selection is the intersection of the selection derived from a channel with the active one. Only the selected parts common to both are kept.

Slett kanalen

Only available for selection masks: this allows you to delete the active channel.

2.2.2.5. Lokalmenyen kanalar

Figur 15.12. Kanalmenyen

Kanalmenyen

Oversyn

You can get the channel context menu by right clicking on a channel. Several of the operations on channels are also available through buttons at the bottom of the channels list. Those operations are documented there.

Ny kanal, Løft kanalen, Senk kanalen, Kopier kanalen, Slett kanalen

Sjå kanalhandtering.

Edit Channel Attributes...

Only available for selection masks. Here you can change the Channel name, the Color tag, the channel attributes and lock attributes, and finally the Opacity and color used for the mask in the image window. A click on the color button displays the GIMP color selector where you can change the mask color.

Color tag

Only available for selection masks. This allows you to assign a color tag to a channel. If you have a lot of channels this can make it easier to identify them by giving related channels the same color tag. To remove the color tag choose None.

Kanal til utval

The selection derived from a channel replaces the previously active selection.

Legg til i utvalet

The selection derived from a channel is added to the active selection. The final selection is merged from both.

Trekk frå utvalet

The final selection is the subtraction of the selection derived from a channel from the active selection.

Snitt med utvalet

The final selection is the intersection of the selection derived from a channel with the active one. Only the selected parts common to both are kept.

2.2.3. Utvalsmasker

Figur 15.13. Eit utval laga av kanalar

Eit utval laga av kanalar

Du kan bruke kanalar for å lagre og henta fram igjen utval. I kanaldialogen kan du sjå ein miniatyr som viser utvalet. Utvalsmaskene er ein metode for lage utvalet om til ein gråskalakanal der kvite punkt er utvalde og svarte punkt ikkje er utvalde. Grå punkt er delvis utvalde. Du kan sjå på desse som ein mjuk overgang frå utvalde til ikkje utvalde område. Dette er viktig for å unngå den stygge «pikseleringseffekten» (hakkete overgangar) som kan oppstå når du fyller utvalet med farge eller bruker viskeleret på utvalet.

Å opprette utvalsmasker

Utvalsmaska kan aktiverast på fleire måtar.

  • Frå biletmenyen via UtvalSlå snarmaska av/på dersom det finst eit aktivt utval i biletet.

  • In the image window the bottom-left button creates a Quick Mask; the content will be initialized with the active selection.

  • Frå kanaldialogen når du trykker på knappen Ny kanal eller frå lokalmenyen. Når utvalsmaska er oppretta, vert ho synleg i kanaldialogen med namnet «Ny kanal», eventuelt med eit tal dersom det er fleire kopiar. Du kan endre namnet ved å høgreklikka på kanalen.

2.2.3.1. Å bruke utvalsmasker

Once the channel is initialized, selected (highlighted in blue), visible (eye-icon in the dialog), and displayed as you want (color and opacity attributes), you can start to work with all the paint tools. The colors used are important. If you paint with some color other than white, gray, or black, the color Value (luminosity) will be used to define a gray (medium, light, or dark). When your mask is painted, you can transform it to a selection by clicking on the button (Channel to Selection) or from the context menu.

Du kan arbeide på utvalsmaska med andre verktøy enn teikneverktøya. For eksempel kan du bruke utvalsverktøya for å fylle eit område av maska med fargeovergangar eller mønsterelement. Det er såleis mogleg å komponera svært komplekse utval ved å kombinera ulike utvalsmasker.

[Obs] Obs

Så lenge utvalsmaska er aktiv, arbeider du på denne og ikkje på biletet. Skal du arbeide på biletet, må du deaktivere alle utvalsmaskene. Gløym heller ikkje å skjule maskene ved å klikke på augeikonet. Det er også ein god ide å kontrollera at alle RGB- og alfakanalane er aktiverte og vert viste i biletet.

2.2.4. Snarmaske

Figur 15.14. Dialogen for Snarmaske

Dialogen for Snarmaske

Ei Snarmaske er ei utvalsmaske tenkt brukt temporært for å teikne på eit utval. Med temporært meiner ein her at, ulikt vanlege utvalsmasker, vert snarmaska ikkje lagra i lista etter at ho er omforma til eit utval. Når du arbeider med svært komplekse bilete, kan det hende at utvalsverktøya møter grensene sine. I slike høve er snarmaska god å ty til, ofte med svært godt resultat.

2.2.4.1. Aktivering

Snarmaska kan hentast fram på fleire måtar:

  • Frå biletmenyen via UtvallSlå snarmaska av/på

  • ved å klikke på den vesle knappen nede i venstre hjørne av biletvindauget, som vist på skjermbiletet

  • eller med tastesnarvegen Shift + Q.

2.2.4.2. Å lage ei snarmaske

For å setja opp Snarmaske klikkar du på knappen nede til venstre i biletvindauget. Dersom det finst eit aktivt utval i biletet, vil dette vere uforandra, men alt rundt vert dekka av ein raud, gjennomsiktig film. Dersom biletet ikkje har noko utval, vert heile biletet dekka med filmen. Klikk ein gong til på knappen for å slå av snarmaska.

Frå kanaldialogen kan du klikke på namnet eller på miniatyren for å redigere innstillingane for Snarmaske. Du kan endre Dekkevne og filmfargen. Du kan når som helst gøyme maska ved å klikke på symbolet framføre Snarmaske.

Maska bruker gråtoner, så du må bruka kvitt eller grått for å minske området eller svart for å gjere området større. Område som er teikna med mørk eller lys grå vert omformingsområda for mjuke kantar i utvalet. Når maska er ferdig, klikk ein gong til på knappen nede til venstre i biletet for å fjerna snarmaska frå kanallista og gjera ho om til eit utval.

Føremålet med snarmaska er å kunne bruke teikneverktøya for å markere utval og overgangar utan å bry seg med utvalsmaska. Snarmaska er ein god måte å isolere eit objekt i eit bilete fordi når utvalet er gjort, kan du berre fjerne innhaldet, eventuelt etter å ha invertert maska dersom objektet er inne i markeringa.

2.2.4.3. Å bruke snarmaske med ein fargeovergang

Beskriving

  1. Biletvindauget med aktivert snarmaske. Alle operasjonar vert gjort på snarmaska. Snarmaska er fylt med ein fargeovergang frå svart (venstre) til kvit (høgre).

  2. Snarmaska er nå kopla ifrå og det er blitt laga eit utval frå den snarmaska som var fylt med fargeovergangen. Du kan sjå skiljet mellom meir og mindre enn 50 % dekkevne for utvalet midt i biletet.

  3. Det vert nå påført eit strøk i det tilgjengeleg utvalet. Underleg! Sjølv om fargeovergamgen ikkje er synleg, er han nå aktiv over heile biletet, både i markerte og umarkerte område!

Etter at du har trykt på knappen for snarmaske vert det laga ein mellombels 8-bits (0 - 255) kanal der fargeovergangen vert lagra. Dersom det finst eit utval i biletet når maska vert laga, vil maska hente data frå dette utvalet. Når snarmaska vert aktivert, vert dei områda som ikkje er utvalde markerte med ei raud, halvgjennomsiktig hinne. Du kan bruka alle teikneverktøya for å lage utval på snarmaska. Sidan snarmaska berre vert påverka av gråtoner, er det enklast å teikne med ulike gråtoner for å lage ulike grader av utveljing. Bruk kvit farge der du kan kome til å legge inn andre grader av utveljing seinare. Utvalet vert gjeldande så snart du slår av snarmaska, men den mellombels kanalen forsvinn for alltid.

[Tips] Tips

Dersom du ønskjer å lagra utvalet, kan du bruke UtvalLagra til kanal i biletmenyen.

2.2.4.4. Bruk
  1. Opna eit bilete, eller lag eit Nytt.

  2. Aktiver snarmaska ved å trykkja på knappen i biletvindauget. Dersom det finst eit utval i biletet, vert maska laga med data frå denne.

  3. Vel eit teikneverktøy og bruk dette med gråtoner på snarmaska.

  4. Deaktiver snarmaska med knappen i biletvindauget.