Skip to main content

Workflows: The Layered Composition Node

A powerful node, the Composition Node allows you to place assets in pixel-perfect positions across a variety of aspect ratios and resolutions

Updated over a week ago

The Composition Node is one of the most powerful and flexible nodes in a workflow, and a key node that leads to using Workflows to their greatest potential. The Composition Node is built around the following concepts:

  • A user should be able to choose the aspect ratios and resolutions their images and compositions output to.

  • A user should be able to create any number of layers to place within any or all resolutions.

  • A user should be able to position and scale those layers independently, allowing them to customize the layer layout for each resolution.

The intent of the composition node can be boiled down to, “I want to put one or more images in a specific arrangement and specific aspect ratio.” It can be used multiple times in a workflow, and can be used in many different ways to resize images or compose them in a different arrangement. For example:

  • You may set the Composition Node to a 300x250 size and center an image vertically and horizontally to create a simple Google Ads image resolution.

  • You may layer your game’s logo as a reference image and overlay it onto a background you previously created, by creating a background layer and a logo layer, then dragging those nodes into the Composition Node.

  • You may use the composition node as a down-res option by setting the resolution to a low value and layering in your previous image.

If you drag a Composition Node output into an Edit Image or Remove Background node, you will automatically create a “Flatten Layers” node. This compresses the composition’s layers into a single image so it may be modified by the Refine node.

The core components of the Composition Node are:

  1. The composition selector. This pulldown allows you to select and/or create compositions, and each composition may have its own aspect ratio and resolution.

  2. Your Layers. These are the inputs that the composition node contains, and there may be any number of layers in a composition. Layers are shared between compositions, so be careful not to delete a layer unless you want it removed from all compositions. Your layer's Z-axis is arranged top to bottom, where the layers at the top of the list will be placed over the layers at the bottom of the list.

  3. Instead of deleting a layer, you may use the eyeball icon to show or hide the layer in the specific composition. Hiding or unhiding a layer is composition-specific, so you may hide any unused layers in the composition. To the left, the six-dot icon allows you to drag and rearrange your layers.

  4. You may modify the composition node's canvas size here. We provide several preset sizes for you to use, or you may adjust the canvas to any size you'd like.

  5. In this screenshot, you can see how workflow inputs are coming in assigned to a specific layer in the canvas. You may click the dropdowns next to these inputs to assign which layer they are sent to. You may have more than one input sent into each layer - useful when you have characters or images added across multiple layers.

  6. The Canvas for this specific node is shown below the node graph. You may drag up and expand the size of the Canvas element by dragging the bar above it.

Once you have your composition canvas set up, you should add at least one layer and arrange it so that it's being output.

Since the composition node is rather complex, rather than outlining every piece of functionality we will provide you with several use cases and how they were accomplished with the composition node.

Use Case: Creating a Landscape Asset from a Square Asset

In this example, a user wants to take every 1024x1024 image they have and turn it into a 1920x1080 landscape image. They do not want to lose any of the original image; They want to outpaint from the original image.

The recommended way to do this is to place the original 1024x1024 image in the center of a new 1920x1080 landscape canvas, with transparent pixels all around. Then, once that image is made, to feed it into an Edit Image node with a Gemini 3 prompt to outpaint from the center image. Here's what the Composition Node looks like to create the centered, transparent landscape:

A layer has been created labled "BaseImage" and this layer has been set to a 1024x1024 resolution under the "Layer Size" part of the UI. It has then been set as centered horizontal and centered vertical using the centering buttons under the "Layer Position" section. The canvas itself has been set to a 1920x1080 resolution. The end result is a centered, square layer of image that will be generated with a border of transparent pixels around it. That image will then be outpainted around it in a future Edit Image node. See below:

Use Case: Layering a Logo and CTA On Top of an Image Background

You may have a static asset like a logo or call to action that you want to layer on top of a generated image. To do this, you may bring in multiple layers: One for a background image, one for a logo, and one for your CTA. Here's one way to layer those assets using a Composition Node:

In this example, a BaseImage layer is being set and defined as centered vertically and horizontally in a 1080x1920 canvas. The BaseImage itself is a 1080x1920 image, so it fits perfectly within the canvas.

Two other layers, a Logo and a SingleClick CTA from reference inputs, are placed higher than the BaseImage background's Z-order, meaning they will be placed on top of the BaseImage. These assets are 1024x1024 in size, though both contain transparent padding around the logo and CTA themselves. The Composition Node has been set up so the logo image is placed at the top of the composition, while the CTA is placed at the bottom of the composition. The end result is a layered image where the two transparent layers are placed on top of the background to make a final asset combining both:

Use Case: Masking Out App Store Areas

When creating seasonal app icon variants, you may want to ensure that your app store icon's content reads well even when its corners have been rounded by the UI of the app store. While your icon may be a square, the rounding of the corners may hide details that help identify the season or app icon theme. To test this, we can upload a mask reference image and place it over any images we create to ensure the final asset still reads correctly with the corners masked out to simulate the app store rounding:

The final result is a greyed-out app icon that correctly masks out the unseen areas of the app icon, ensuring we know that it may look like when it's finally uploaded for the next season:

Did this answer your question?