Vivian Høxbro, Shadow Knitting, Interweave Press, 2004
Margaret Radcliffe, The Essential Guide to Color Knitting Techniques: Multicolor Yarns, Plain and Textured Stripes, Entrelac and Double Knitting, Stranding and Intarsia, Mosaic and Shadow Knitting, 150 Color Patterns, 2nd Edition 2015
Most are hand knitting patterns where it’s easy to knit or purl. I used the garter carriage on a Brother 940 and drew the pattern in DAK.
cast on 66 st with T=5, then knit with GC and T=6
mirror setting Variation key 2
Yarn color is changed every second row on left, 2 rows light color, 2 rows dark color. black in chart are selected needles, white non selected.
The illusion is visible when seen from the side, from the top only stripes are seen.
This picture is from the website. Knitting starts at bottom with each row knitted 4 times, 2x in light color and 2x in dark color. The description says to alway knit the front row and to either knit or purl the back row. For the shaded areas that should look dark the back row is knitted with the dark color, making a purl bump that will be visible. For the light colored shading the back row is knitted with the light color.
Here is the DAK pattern
To knit this with garter carriage. Cast on from right to left in light color. Then knit row 1 and 2 with garter carriage. As there are no selected needles on the first 2 rows, both rows knit normally. Then for the 2 dark color rows, the first row is knitted, the second row all stitches are turned with garter carriage. This corresponds to knitting the back row by hand, instead of purl. These first 4 rows show as a dark ridge from the other side (away from knitter). In the next 12 rows (4x3rows) the second light color rows has the stitches turned with garter carriage, so this shows as 3 white bumps, the white piano keys.