Apr 27 2009
Adobe Photoshop Tip– Simple Matrix Code
| Also check out the sequel to this tutorial: The Matrix Code Retooled. It’s a much improved version of the Matrix raining code effect using actual type just like in the films. |

I know why you’re here. I know what you’ve been doing… why you hardly sleep, why you live alone, and why night after night, you sit by your computer. You’re looking for this. I know because I was once looking for the same thing. And when it found me, I realized I wasn’t really looking for it. I was looking for an answer. It’s the question. It’s the question that drives us. It’s the question that brought you here. You know the question, just as I did.
“How do I make that funky green raining code that you see in the Matrix, the Matrix Reloaded and the Matrix Revolutions?”
The answer is right there, and it’s looking for you, and it will find you if you want it to…okay, it won’t really…never mind…here’s the tutorial:
I’m starting with a 5″ square canvas at 300ppi filled with black in RGB mode. We’re going to have at least 4 layers of code that will give our image depth. The first layer (the layer furthest back) will consist of steps that will be used throughout this tutorial. We shall call these steps “the Recipe” Here we go:
Background Layer: Green Rain – Downpour
Using the Background layer, follow the steps of the recipe as described here:
| The Recipe | |
|
Then bring up the Levels Adjustment window (Command-L) and set the Output Levels (the two fields below the histogram) to 0 and 80 and click OK.
Layer 1: Green Rain – Intermittent showers

Make a new layer filled with black on top of the first. Apply the Grain effect from step 1 of the Recipe. Now scale this new layer by hitting Command-T and entering a value of 200% in the width and height fields before applying the scale.
Go ahead and complete steps 2 and 3 of the Recipe on this layer.
Add a layer mask to this layer (Layer > Add Layer Mask > Reveal All) and click on the Quick Mask Mode button in the Tools palette.
Choose Filter > Render > Clouds.
Now go Image > Adjustments > Threshold. Set the threshold to 140 and click OK.
Go Filter > Stylize > Wind. Set the Wind filter to “Wind” and “From the Right” and click OK. Hit Command-F 3 times to apply this Wind effect several more times.
Apply a Motion Blur of 10 pixels at 90? (Filter > Blur > Motion Blur) to smudge the wind lines a little.
Go Edit > Transform > Rotate 90? CCW.
Exit Quick Mask Mode by clicking the Standard Mode button in the Tools palette.
Click on the thumbnail on your layer’s mask in the Layers palette and then hit delete to mask out the “Cloudy-Windy texture” you’ve created.
Deselect All (Command-D)
With the mask thumbnail still selected bring up the Levels Adjustment window (Command-L) and set the three fields above the histogram to 0, 0.10, and 255 and click OK.
Set the Blending Mode of this layer to Screen.
Layer 2: Green Rain – Raining Cats and Dogs

Make another new layer filled with black on top of the other two. Apply the Grain effect from step 1 of the Recipe. Scale this layer as you did with Layer 1, only this time crank it up to 500%.
Because of all the scaling we’ve done, there is a lot of image data that resides beyond the confines of the Canvas and any filters we apply will have to render across this unseen image area. So to save time in applying filters, we’re going to crop off this extra image data. Select All (Command-A) and go Image > Crop the hit Command-D to deselect again.
Apply a Threshold (you remember Threshold from Layer 1) of 128 to this layer
Apply steps 2 and 3 from the the Recipe, but when you get to step 3, use an Edge Width of 2 on the Glowing Edges filter.
Add a Layer Mask to this layer also and, with the layer’s mask thumbnail selected, apply the Clouds filter and then adjust the Levels to 70, 1.00, 190 for the Input Levels and set the Output fields to 0 & 150.
Set the Blending Mode of this layer to Screen.
Layer 3+: Green Rain – Enter the Code

The previous layers have all been less detailed background representations of the text based code that runs through the Matrix. In this section we will be adding text layers to more accurately represent the code.
Select the Vertical Type Tool (in the Tools palette, click and hold on the Type Tool to reveal the Vertical Type Tool). Set the font to Courier (or a mono spaced font of your choosing), set the type size to 9pt, the alignment to “Top Align Text”, and the color to white. Hit the Caps Lock key on your keyboard and type something…anything…be it nonsense or subliminal messages.
Once you’ve typed a few characters, highlight them all, open the Character palette and set the tracking to -150.
Once you have a single vertical line of text (it doesn’t have to stretch from the top to the bottom ó it’s actually better if it floats in the middle a bit). When you’re done typing, click the Gradient Tool and then add a layer mask (Reveal All again). With the Gradient options set to the standard “White to Black”, Normal mode, 100% Opacity settings, click the mouse down on the baseline of the letter second from the bottom of you line of “code” and drag it straight up, releasing your mouse button somewhere slightly beyond the height of the topmost letter.
Repeat this process by creating a few more Vertical Text strings…not too many…just more. You can even Option-Drag your completed code strings to replicate them in various parts of your image.
Final Layer: Adjusting to the Green

Create a Hue/Saturation Adjustment Layer (Layer > New Adjustment Layer > Hue/Saturation) above all your other layers. Set the Hue/Saturation Adjustment Layer to Colorize with settings of 146 Hue, 55 Saturation and -37 Lightness.
Well, there you go that’s it for another Graphics Tip. Stay tuned to MacMerc.com… you never know when we’re gonna bring you another one.

| Also check out the sequel to this tutorial: The Matrix Code Retooled. It’s a much improved version of the Matrix raining code effect using actual type just like in the films. |










5. Under the View menu choose Show>Grid and then under the same menu choose both Snap and Snap to>Grid. If your grid is set to the default, you should see that each character of the Matrix code fall in its own cell in the grid.
11. Select the Background layer in the Layers palette and with the Rectangular Marquee tool make a selection anywhere on your image that follows the bold lines in the grid and envelopes a 2 x 2 group of cells. Now go Edit>Define Brush… and name your brush “Square”. Deselect.
15. Code away! Repeat step 14 and toggle the grid on and off to see what it looks like between strokes. (make sure the grid is visible and that Photoshop is set to snap to the grid when you actually paint the strokes though)

28. Hold down the Shift key and Green Rain 2 straight up about 1/7 of the total image height.
36. Go Filter>Blur>Radial Blur… Set the amount to 3, the Blur Method to Zoom and the Quality to Good. Also click and drag the Blur center to the bottom center of the window and click OK.
