Patterns

Patterns

Pattern filters repeat a single image layer many times across its canvas. Two filters are available:

  • grid fills the whole canvas with an all-over pattern, such as a straight grid, a brick layout or a honeycomb.

  • bord places the copies along the edges of the canvas to produce a border or a wreath.

Both are filter commands and are enabled using the fx command, see Filter options.

The canvas in question is the canvas the layer is rendered into: either the main image canvas or, if the layer belongs to a group, the group canvas. To fill a masked product area, such as a phone case, render the pattern layer into a group of the desired size and apply the mask to the group, see Group options.

Size and spacing

All copies of a pattern share the same size. The canvas is divided into square slots, one per copy, and every copy is centered in its slot.

  • s sets the slot size as a fraction of the shorter side of the canvas, so s:0.25 places four slots across the shorter side. The default value is 0.2. The value is limited to the range between 0.02 and 2.

  • g sets how many times the copy fits into its slot. The image is scaled so that its longer side equals the slot divided by g, while its proportions are preserved. With g:1 the copies touch, with g:2 each copy takes up half of its slot and the rest is empty. The default value is 1.3.

Because both values are relative to the canvas, the same pattern definition produces a consistent look on canvases of different resolutions, and the number of copies across does not change with g.

Grid pattern (grid)

Grid pattern arranges the copies on a regular lattice that is symmetric about the canvas center. The number of copies across is the number of slots that fit across the canvas, rounded to the nearest whole number. With an odd count one copy sits on the center; with an even count the copies straddle the center instead, so that a canvas two slots wide shows two whole copies rather than one whole copy and two halves. Rows follow the same rule. Copies that cross the canvas edge are clipped.

For example: fx=grid(s:0.2)

https://fx.images.drivecommerce.com/api/v1/drive/image/?layer=0&src=CZ-BOX2000X2000CFFFFFFFF&&layer&src=dog-sticker&fx=grid(s:0.2)

patterns-grid-default-20260929-004213.png

Spacing (g, sx, sy)

The same slots with smaller copies in them: fx=grid(s:0.2;g:2)

https://fx.images.drivecommerce.com/api/v1/drive/image/?layer=0&src=CZ-BOX2000X2000CFFFFFFFF&&layer&src=dog-sticker&fx=grid(s:0.2;g:2)

patterns-grid-spacing-20260929-004215.png

Slot width and height can differ. sx and sy multiply the slot size along one axis, so sx:0.6 packs the columns closer together while the rows keep their spacing: fx=grid(s:0.2;g:1.2;sx:0.6)

https://fx.images.drivecommerce.com/api/v1/drive/image/?layer=0&src=CZ-BOX2000X2000CFFFFFFFF&&layer&src=dog-sticker&fx=grid(s:0.2;g:1.2;sx:0.6)

patterns-grid-sx-20260929-004216.png

Layouts (t)

The t parameter selects one of the common repeat layouts:

  • grid — straight rows and columns, the default

  • brick — every other row is shifted by half a slot, like a brick wall

  • drop — every other column is shifted by half a slot, the classic half-drop repeat

  • hex — a honeycomb, where rows are shifted like bricks and packed closer together vertically

Brick layout: fx=grid(s:0.2;t:brick)

https://fx.images.drivecommerce.com/api/v1/drive/image/?layer=0&src=CZ-BOX2000X2000CFFFFFFFF&&layer&src=dog-sticker&fx=grid(s:0.2;t:brick)

patterns-grid-brick-20260929-004210.png

Half-drop layout: fx=grid(s:0.2;t:drop)

https://fx.images.drivecommerce.com/api/v1/drive/image/?layer=0&src=CZ-BOX2000X2000CFFFFFFFF&&layer&src=dog-sticker&fx=grid(s:0.2;t:drop)

patterns-grid-drop-20260929-004213.png

Honeycomb layout: fx=grid(s:0.2;t:hex)

https://fx.images.drivecommerce.com/api/v1/drive/image/?layer=0&src=CZ-BOX2000X2000CFFFFFFFF&&layer&src=dog-sticker&fx=grid(s:0.2;t:hex)

patterns-grid-hex-20260929-004214.png

The layouts are shortcuts for two lower-level parameters, which can be used directly to build custom arrangements:

  • o shifts every other row by the given fraction of the slot width

  • oy shifts every other column by the given fraction of the slot height

For instance, t:brick is equivalent to o:0.5, while a one-third brick offset would be o:0.33. Explicit values override the layout defaults.

Rotation (r)

The r parameter rotates the whole lattice around the canvas center by the given angle in degrees. The copies themselves stay upright. Rotating a straight grid by 45 degrees produces a diamond layout: fx=grid(s:0.2;r:45)

https://fx.images.drivecommerce.com/api/v1/drive/image/?layer=0&src=CZ-BOX2000X2000CFFFFFFFF&&layer&src=dog-sticker&fx=grid(s:0.2;r:45)

image-20261009-131613.png

To rotate every copy instead, use the layer rotate command, which is applied to each copy individually: fx=grid(s:0.2;t:hex)&rotate=-15

https://fx.images.drivecommerce.com/api/v1/drive/image/?layer=0&src=CZ-BOX2000X2000CFFFFFFFF&&layer&src=dog-sticker&fx=grid(s:0.2;t:hex)&rotate=-15

patterns-grid-rotate-layer-20260929-004214.png

Partial copies (clip)

Copies along the canvas edge are usually cut off, which is the expected look of an all-over pattern. The clip parameter controls what happens to them:

  • allow — partial copies are drawn and clipped by the canvas, the default

  • hide — copies that would be clipped are left out, so only whole copies remain

  • fit — copies whose center lies on the canvas make up the pattern. The pattern is scaled down around the canvas center just far enough to make them whole, provided the result covers more of the canvas than leaving the partial copies out, and only whole copies are drawn. Copies beyond the edge that turn out whole at the chosen size are added, which completes the rows of staggered layouts. The pattern never shrinks below half of the requested cell size, and it keeps the centering that the number of slots at the requested size dictates, so a canvas two slots wide fits as two-up rather than as one large or three small copies

  • fitloose — the same as fit, except that once the size is settled the partial copies along the edges are drawn as well, as long as at least 5% of a copy lies inside the canvas. The fitted copies stay whole while the edges are filled as with allow

The check uses the actual outline of each copy, so a copy rotated by the layer rotate command or by rotation jitter counts as clipped as soon as one of its corners crosses the edge.

Default: fx=grid(s:0.28;g:1.2)

https://fx.images.drivecommerce.com/api/v1/drive/image/?layer=0&src=CZ-BOX2000X2000CFFFFFFFF&&layer&src=dog-sticker&fx=grid(s:0.28;g:1.2)

image-20261009-131821.png

Whole copies only: fx=grid(s:0.28;g:1.2;clip:hide)

https://fx.images.drivecommerce.com/api/v1/drive/image/?layer=0&src=CZ-BOX2000X2000CFFFFFFFF&&layer&src=dog-sticker&fx=grid(s:0.28;g:1.2;clip:hide)

image-20261009-131910.png

Scaled to fit: fx=grid(s:0.28;g:1.2;clip:fit)

https://fx.images.drivecommerce.com/api/v1/drive/image/?layer=0&src=CZ-BOX2000X2000CFFFFFFFF&&layer&src=dog-sticker&fx=grid(s:0.28;g:1.2;clip:fit)

image-20261009-132229.png

Fitting is most useful with staggered layouts, where the extra row completes the zigzag: fx=grid(s:0.28;g:1.2;t:hex;clip:fit)

https://fx.images.drivecommerce.com/api/v1/drive/image/?layer=0&src=CZ-BOX2000X2000CFFFFFFFF&&layer&src=dog-sticker&fx=grid(s:0.28;g:1.2;t:hex;clip:fit)

image-20261009-132253.png

The same applies to the half-drop layout, where the alternating columns end up with a different number of whole copies: fx=grid(s:0.28;t:drop;clip:fit)

https://fx.images.drivecommerce.com/api/v1/drive/image/?layer=0&src=CZ-BOX2000X2000CFFFFFFFF&&layer&src=dog-sticker&fx=grid(s:0.28;t:drop;clip:fit)

image-20261009-132319.png

Fitting leaves the edges empty where partial copies were dropped. fitloose fills them again with clipped copies while the fitted copies stay whole: fx=grid(s:0.2;t:drop;clip:fitloose)

https://fx.images.drivecommerce.com/api/v1/drive/image/?layer=0&src=CZ-BOX2000X2000CFFFFFFFF&&layer&src=dog-sticker&fx=grid(s:0.28;t:drop;clip:fitloose)

image-20261009-132342.png

Border pattern (bord)

Border pattern places the copies along the outline of the canvas and leaves the middle empty. The copies touch the canvas edge, the four corners are always occupied, and each side receives a whole number of evenly spaced copies. The spacing along a side may therefore differ slightly from the slot size.

For example: fx=bord(s:0.15)

https://fx.images.drivecommerce.com/api/v1/drive/image/?layer=0&src=CZ-BOX2000X2000CFFFFFFFF&&layer&src=dog-sticker&fx=bord(s:0.15)

image-20261009-132358.png

Copy size and inset (g, in)

The g parameter shrinks the copies within their slots without changing the spacing, in the same way as for grids: fx=bord(s:0.15;g:1.8)

https://fx.images.drivecommerce.com/api/v1/drive/image/?layer=0&src=CZ-BOX2000X2000CFFFFFFFF&&layer&src=dog-sticker&fx=bord(s:0.15;g:1.8)

image-20261009-132414.png

The in parameter moves the border inwards, away from the canvas edge. The value is measured in slots, so in:0.5 leaves half a slot of empty space between the copies and the edge: fx=bord(s:0.15;in:0.5)

https://fx.images.drivecommerce.com/api/v1/drive/image/?layer=0&src=CZ-BOX2000X2000CFFFFFFFF&&layer&src=dog-sticker&fx=bord(s:0.15;in:0.5)

image-20261009-132431.png

Rounded corners and circles (rc)

Many products have rounded corners, or are round altogether. The rc parameter sets the corner radius of the canvas outline as a fraction of its shorter side, and the border follows the resulting shape. With the maximum value of 0.5 the outline becomes a circle on a square canvas, or a pill shape on a rectangular one.

Rounded corners: fx=bord(s:0.15;rc:0.3)

https://fx.images.drivecommerce.com/api/v1/drive/image/?layer=0&src=CZ-BOX2000X2000CFFFFFFFF&&layer&src=dog-sticker&fx=bord(s:0.15;rc:0.3)

image-20261009-132449.png

Circle: fx=bord(s:0.15;rc:0.5)

https://fx.images.drivecommerce.com/api/v1/drive/image/?layer=0&src=CZ-BOX2000X2000CFFFFFFFF&&layer&src=dog-sticker&fx=bord(s:0.15;rc:0.5)

image-20261009-132503.png


With small radii, where a rounded corner is shorter than the spacing between copies, each corner keeps its copy and the sides are spaced independently, just like on a sharp border. Once the corner is longer than the spacing, the copies are distributed evenly around the whole outline instead, starting from the top center, so that the result stays symmetric.

Following the outline (f)

By default all copies keep their orientation. Setting f:1 rotates each copy to follow the outline, so that the top of the image always faces outwards. On a circle this produces a wreath, while on a sharp border the corner copies face diagonally.

Wreath: fx=bord(s:0.15;rc:0.5;f:1)

https://fx.images.drivecommerce.com/api/v1/drive/image/?layer=0&src=CZ-BOX2000X2000CFFFFFFFF&&layer&src=dog-sticker&fx=bord(s:0.15;rc:0.5;f:1)

image-20261009-132542.png

Frame: fx=bord(s:0.15;f:1)

https://fx.images.drivecommerce.com/api/v1/drive/image/?layer=0&src=CZ-BOX2000X2000CFFFFFFFF&&layer&src=dog-sticker&fx=bord(s:0.15;f:1)

image-20261009-132554.png

Sides (sides)

The sides parameter limits the border to some of the canvas edges. The value is any combination of the letters t, r, b and l for the top, right, bottom and left side. A copy that sits in a corner is kept if either of its adjacent sides is enabled.

For example, rails along the left and right edges only: fx=bord(s:0.15;sides:lr)

https://fx.images.drivecommerce.com/api/v1/drive/image/?layer=0&src=CZ-BOX2000X2000CFFFFFFFF&&layer&src=dog-sticker&fx=bord(s:0.15;sides:lr)

image-20261009-132611.png

Fixed count (n)

Instead of deriving the number of copies from the spacing, the n parameter requests an exact total. The copies are distributed evenly along the outline; s and g then only set the copy size. On a sharp border the corners stay occupied, and the remaining copies are shared between the sides in proportion to their length.

For example: fx=bord(s:0.15;rc:0.5;n:12)

https://fx.images.drivecommerce.com/api/v1/drive/image/?layer=0&src=CZ-BOX2000X2000CFFFFFFFF&&layer&src=dog-sticker&fx=bord(s:0.15;rc:0.5;n:12)

image-20261009-132628.png

Rotation jitter (d, di, ds, dmin, dmax, dseed)

Both pattern filters can give each copy a slightly different rotation, which makes a pattern feel hand-placed. The parameters mirror the “dancing” letter options of text layers:

  • d:1 enables the jitter

  • dmin and dmax limit the rotation angle in degrees, -15 and 15 by default

  • ds is the step between the possible angles, 15 by default. Angles are picked from the grid formed by the step within the limits, and two neighboring copies never receive the same angle

  • di is the angle of the first copy, 0 by default

  • dseed selects one particular random arrangement

For example: fx=grid(s:0.2;t:hex;d:1)

https://fx.images.drivecommerce.com/api/v1/drive/image/?layer=0&src=CZ-BOX2000X2000CFFFFFFFF&&layer&src=dog-sticker&fx=grid(s:0.2;t:hex;d:1)

image-20261009-132640.png

Finer steps and a wider range on a border: fx=bord(s:0.15;rc:0.3;d:1;dmin:-20;dmax:20;ds:10;dseed:7)

https://fx.images.drivecommerce.com/api/v1/drive/image/?layer=0&src=CZ-BOX2000X2000CFFFFFFFF&&layer&src=dog-sticker&fx=bord(s:0.15;rc:0.3;d:1;dmin:-20;dmax:20;ds:10;dseed:7)

image-20261009-132652.png


The arrangement is deterministic: the same parameters and the same source image always produce the same result, which keeps the output cacheable. When dseed is omitted, the seed is derived from the source image reference. To offer a “shuffle” option, change the seed value: fx=bord(s:0.15;rc:0.3;d:1;dmin:-20;dmax:20;ds:10;dseed:8)

https://fx.images.drivecommerce.com/api/v1/drive/image/?layer=0&src=CZ-BOX2000X2000CFFFFFFFF&&layer&src=dog-sticker&fx=bord(s:0.15;rc:0.3;d:1;dmin:-20;dmax:20;ds:10;dseed:8)

image-20261009-132706.png

Combining with other effects

Other filters and effects of the layer apply to every copy. Drop shadows, glows and color adjustments can be combined with a pattern in the same fx command: fx=grid(s:0.2;t:hex),sdw(x:10;y:10;b:5;c:000000;o:0.5)

https://fx.images.drivecommerce.com/api/v1/drive/image/?layer=0&src=CZ-BOX2000X2000CFFFFFFFF&&layer&src=dog-sticker&fx=grid(s:0.2;t:hex),sdw(x:10;y:10;b:5;c:000000;o:0.5)

image-20261009-132721.png

A pattern replaces the layer’s own placement. Layer position, anchor, skew, design surface (osize, oscale, opos) and 3D transform commands have no effect on a pattern layer, while rotate and orotate rotate every copy. A design placed on a print area with osize can therefore be turned into a pattern by adding the filter alone; the copies are sized by s rather than by oscale.


Pattern filters can be applied only to image layers. To repeat a text layer, render the text into a group first, and then apply the pattern to the group image.