2. Diálogos relacionados con la estructura de la imagen

Los diálogos siguientes le permiten controlar y manipular las estructuras de la imagen, como con capas, canales, o rutas.

2.1. Diálogo de capas

Figura 15.1. Diálogo de capas

Diálogo de capas

El diálogo Capas es la interfaz principal para editar, modificar y administrar sus capas.

2.1.1. Activar el diálogo

Este diálogo es un diálogo empotrable; consulte la Sección 2.3, “Diálogos y empotrables” para obtener ayuda sobre su uso.

Puede acceder:

  • from the main menu: WindowsDockable DialogsLayers;

  • from the Tab menu in any dockable dialog by clicking on and selecting Add TabLayers,

  • desde el atajo de teclado (predeterminado): Ctrl+L.

In the Windows menu, there is a list of detached windows which exists only if at least one dialog remains open. In this case, you can raise the Layers dialog from the main menu: WindowsLayers.

2.1.2. Usar el diálogo de capas

Visión general

Cada capa aparece en el diálogo con la forma de una miniatura. Cuando una imagen tiene múltiples capas como componentes, aparecen como una lista. La capa superior de la lista es la primera que se ve, y la capa inferior es la última visible, el fondo. Sobre la lista puede encontrar características relacionadas con cada capa en particular. Bajo la lista hay botones para gestionar la lista de capas. Una pulsación derecha sobre la miniatura de una capa abre el menú contextual de la capa.

Layer list

Each entry in the list is a layer along with its attributes:

Visibilidad de la capa

Clicking this icon toggles whether the layer is visible or not. (Shift-clicking on the icon causes all other layers to be hidden.)

Bloquear

Clicking on the empty checkbox in the lock column of a layer opens a menu with the following options:

  • Lock pixels: When this toggle button is enabled, you cannot use any brush-based tool (Paintbrush, Pencil, Eraser etc.), the Airbrush or the Ink tool on the currently selected layer. This may be necessary to protect them from unwanted changes.

  • Lock position and size: This toggle button enables or disables protection of layers from moving them around or transforming them. When this is enabled, then you cannot use any transform tool (Rotate, Shear, Perspective and others) or move it.

  • Lock visibility: This toggle button controls the Lock setting for the visibility of the layer. If this is enabled, the layer visibility cannot be changed.

  • Lock alpha channel: This toggle button controls the Lock setting for the transparency of the layer. If this is enabled, the alpha channel for the layer is locked, and no manipulation has any effect on it. In particular, nothing that you do to a transparent part of the layer will have any effect.

Figura 15.2. Ejemplo de canal alfa bloqueado

Ejemplo de canal alfa bloqueado

La capa activa tiene tres tiras verdes horizontales y opacas sobre un fondo transparente. Se pinta una tira roja vertical. Bloquear desmarcado: las áreas opacas y transparentes de la capa activa se pintan con rojo.

Ejemplo de canal alfa bloqueado

Bloquear marcado: sólo las áreas opacas de la capa activa se pintan con rojo. Se preservan las áreas transparentes.


[Sugerencia] Sugerencia

Si un nombre de capa en el diálogo de capas está en negrita, esta capa no tiene canal alfa.

Miniatura de la capa

The layer content is represented in a thumbnail. Maintaining left-click for a second on this thumbnail makes it larger. The border color of the layer depends on whether the layer is active or inactive.

Nombre de la capa

You can change the name of the layer by double-clicking on it. You can also use the Edit Layer Attributes dialog in the context menu that you get by right-clicking on the layer.

[Nota] Nota

In the case of an animation layer (GIF or MNG), the name of the layer can be used to specify certain parameters: Layer_name (delay in ms) (combination mode), for example Frame-1 (100 ms) (replace). The delay sets the time during which the layer is visible in the animation. The combination mode sets whether you combine the layer with the previous layer or replace it: the two modes are (combine) or (replace).

Características de las capas

Above the layer list, it is possible to specify some properties for the active layers. The active layers are highlighted. The properties are:

Modo

El modo de capa determina cómo interactúa la capa con las otras capas. Desde esta casilla puede acceder a todos los modos proporcionados por GIMP. Los modos de capas se describen en detalle en la Sección 2, “Modos de capa”.

Opacidad

Al mover este deslizador le da más o menos opacidad a la capa. Con un valor de opacidad de cero, la capa es transparente y completamente invisible. No confunda esto con la máscara de capa, que establece la transparencia píxel por píxel.

Gestión de las capas

Debajo de la lista, un conjunto de botones le permiten realizar algunas operaciones básicas con la lista de capa.

Create new layer

Aquí puede crear una capa nueva. Se abre un diálogo, que se describe en Capa nueva.

Pulse la tecla Mayús para abrir una capa nueva con los últimos valores utilizados.

Create new layer group

Aquí puede crear un grupo de capas nuevo. Se crea una capa nueva, sobre la que puede poner capas.

Los grupos de capas se describen en Grupos de capas.

Elevar la capa

Aquí puede subir un nivel a la capa de la lista. Presione la tecla Mayús para mover la capa a la cima de la lista.

Bajar a la capa

Aquí puede bajar la capa un nivel en la lista. Presione la tecla Mayús para mover la capa al fondo de la lista.

[Sugerencia] Sugerencia

Para bajar una capa al fondo de la lista, primero puede ser necesario añadir un canal de transparencia (también llamado canal alfa) a la capa del fondo. Para hacer esto, pulse con el botón derecho sobre la capa de fondo y seleccione Añadir canal alfa en el menú.

Duplicate layers

Here you can create a copy of the selected layers. Name of new layer is suffixed with "copy".

Unir capas Anclar la capa

Antes de GIMP-2.10.18, este botón era solamente para el anclaje. Ahora, se convierte en un ancla solo cuando se crea una selección flotante (ancla la selección flotante a la capa activa anterior). Si no, hay un icono de Fusionar capas con varias posibilidades:

  • Merge these layers with the first visible layer below it.

  • Pulsar Mayús: combinar las capas del grupo de capas en una capa normal.

  • Pressing Ctrl: merge all visible layers into one layer.

  • Pulsar Mayús+Ctrl: fusionar todas las capas visibles con los últimos valores utilizados.

Add masks to layers

Add masks to selected layers.

Select layers by patterns

Select layers by patterns and store layer sets.

Allows you to group layers for operations on more than one layer at a time (for example with the Move tool).

Delete layers

Here you can delete the active layers.

Más operaciones sobre las capas

Other functions about layer size are available in the Layer context menu you get by right clicking on the Layer Dialog. You can find them also in the Layer submenu of the main menu.

You will find merging layers functions in the Image main menu.

Pulsar y arrastrar las capas

Al pulsar y mantener sobre la miniatura de una capa: se agranda y la puede mover arrastrando el ratón.

  • Con esto puede colocar la capa en algún otro lugar de la lista de capas.

  • También puede llevar la capa a la caja de herramientas: se crea una imagen nueva que contiene sólo esta capa.

  • Por último, puede llevar la capa hacia otra imagen: esta capa se añade encima de las capas existentes en su lista de capas.

2.1.3. The Layer dialog context menu

Figura 15.3. Context Menu for the Layers Dialog

Context Menu for the Layers Dialog

By right-clicking in the layer dialog, or by opening the Layers Menu from the tab menu, a context menu for the Layers dialog will open.

Most of the commands in this menu have already been documented above, or elsewhere:

Edit Layer Attributes…

Except for Width, Height, and Fill with, this dialog is the same as the New Layer Dialog. For information about the layer attributes we therefore refer to the documentation for that dialog.

Blend Space submenu

See Blend space in the New Layer dialog.

Composite Space submenu

See Composite space in the New Layer dialog.

Composite Mode submenu

See Composite mode in the New Layer dialog.

Color Tag submenu

See the Color tag documentation in the New Layer dialog.

New Layer, New Layer Group, Duplicate Layer, Merge Down, Anchor Layer, Delete Layer

These commands are explained above, see layer characteristics.

New from Visible

See the New from Visible menu command documentation.

Layer Boundary Size…

See the Layer Boundary Size… menu command documentation.

Layer to Image Size

See the Layer to Image Size menu command documentation.

Scale Layer…

See the Scale Layer… menu command documentation.

Add Layer Masks…, Apply Layer Mask, Delete Layer Mask, Show Layer Masks, Edit Layer Mask, Disable Layer Masks, Masks to Selection

See the Layer Mask submenu documentation for these commands.

Add Alpha Channel, Remove Alpha Channel

Only one of these will be enabled. If the current layer does not have an alpha channel, you will be able to add one. If it does, you can remove the alpha channel.

Merge Visible Layers

This command merges all visible layers into one layer.

Flatten Image

This command merges all layers into one layer and removes transparency.

2.1.4. Máscaras de capa

Figura 15.4. El diálogo Añadir máscara

El diálogo “Añadir máscara”

Visión general

A transparency mask can be added to each layer, which defines what parts of the layer are transparent or opaque. We call this a layer mask. A layer mask has the same size and same number of pixels as the layer to which it is attached. Every pixel of the mask can then be coupled with a pixel at the same location in the layer. The mask is a set of pixels in grayscale. The pixels with a value 0 are black and give a full transparency to the coupled pixel in the layer. The pixels with the maximum value (either 1.0 or 255) are white and give full opacity to the coupled pixel in the layer.

To create a layer mask start with a right click on the layer to call the context menu and select Add Layer Masks… in the menu. A dialog appears where you can initialize the content of the mask:

  • Blanco (opacidad completa): la máscara es blanca en el diálogo de capas. Así, todos los píxeles de la capa son visibles en la ventana de la imagen ya que pintar la máscara con blanco hace los píxeles de la capa completamente visibles. Se pintará de negro para hacer los píxeles transparentes.

  • Negro (transparencia completa): la máscara es negra en el diálogo de capas. Así, la capa es completamente transparente ya que pintar la máscara con negro hace los píxeles de la capa transparentes. Pintar con blanco quitará la máscara y hará los píxeles de la capa visibles.

  • Layer's alpha channel: the mask is initialized according to the contents of the layer's alpha channel.

  • Transferir el canal alfa de la capa: hace lo mismo que la opción previa, excepto que también reinicia el canal alfa de la capa a una opacidad completa.

  • Selection: the mask is initialized according to pixel values found in the current selection.

  • Grayscale copy of layer: the mask is initialized according to a grayscale representation of the pixel values of the layer.

  • Canal: la máscara de capa se inicializa con una máscara de selección que ha creado antes, guardada en el diálogo de canales.

  • Invert mask: This checkbox allows you to invert: black turns to white and white turns to black.

When the mask is created, it appears as a thumbnail next to that of the layer itself. You can select the layer or the mask for editing by clicking on their respective thumbnails. The active item has a white border (which may not be clearly visible when you have a white mask).

When working with masks, it is a good idea to keep the Layers Dialog prominently visible, because you can't see, by looking at the canvas, whether the layer or the mask is active.

Pressing Alt (or Ctrl+Alt and clicking on the layer mask thumbnail) is equivalent to the Show Layer Mask command: the layer mask border turns to green. If you press Ctrl the border is red and the result is equivalent to the Disable Layer Mask command. To return to normal view repeat the last operation. These options are for greater convenience in your work.

Ejemplo de máscara de capa

Figura 15.5. Una capa con máscara de capa

Una capa con máscara de capa

Esta imagen tiene una capa de fondo con una flor y otra azul, completamente opaca. Se ha añadido una máscara de capa a la capa azul. En la ventana de la imagen, la capa azul permanece visible porque una máscara blanca hace visibles a los píxeles.


Figura 15.6. Pintar la máscara de capa

Pintar la máscara de capa

La máscara de capa está activa. Pinte con un color negro, que hace transparente a la capa: la capa subyacente se vuelve visible.