Matrix rain text art
Lays any set of characters out as Matrix-style rain frames: only the falling head is marked with #, the trail picks glyphs deterministically from the seed, and columns, rows, rows-per-frame, trail length, frames and seed are all adjustable. Randomness comes from the published xorshift32 algorithm, so identical parameters always reproduce the identical frame.
Runs in your browserEvery computation happens in your browser — your data never leaves this device.
Matrix rain frame
The first line carries the parameters and counts, then the character grid: # marks the falling head, the rest is the trail.
Enter at least 2 characters as glyphs, or press Example
Cols: 0 · Rows: 0 · Frame: 0 · Seed: 0 · Speed: 0 · Trail: 0 · Visible cells: 0
What this tool does
- Decorate a terminal banner or login screen: copy a fixed-seed rain into a script or blog post and get the exact same picture every time, no screenshot needed.
- Compare glyph sets: swap the glyphs for 01, Chinese characters or symbols and see how dense the rain looks before picking one for your own program.
- Use it as a template when you need reproducible randomness: the seed plus xorshift32 is a published algorithm, so the same parameters give the same frame on any platform.
- Debug frame by frame: change "frames to advance" to see when the columns reach the screen and when they wrap back to the top.
Example
Input
01
Output
32 列 × 12 行 · 第 8 帧 · 种子 20261012 · 速度 1 · 拖尾 4 · 字形 2 个 · 可见单元 78 个
1 0 0 # 0 1
# 0 0 1 1 0 1
1 1 11 1# 1 001
1 10 1 000 0 0 #1 1 #1# 1
1 01 # 1#1 0 1 0 0 1 0 01
1 0# 1 # # 0 1 1 1 # 01
# # # # 1 # # 0#
# #
Frame 8 with the default parameters (32 columns / 12 rows / 8 frames / seed 20261012 / speed 1 / trail 4): the first line holds the parameters and counts, then 12 rows of exactly 32 cells (so the columns line up). # marks a falling head, other characters are the trail and blanks mean the column has not reached that row yet. With 2 frames only 11 cells are visible and with 0 frames the grid is empty.
Frequently asked questions
Where does the randomness come from, and why is the result reproducible?
From Marsaglia's published xorshift32 (2003): x ^= x << 13, x ^= x >>> 17, x ^= x << 5. Its state is fully determined by the seed you enter (20261012 by default), so identical parameters always produce the identical frame — no Math.random call and no clock. Change the seed for a different picture.
How big is the built-in glyph library, and why must the page supply glyphs?
The built-in library holds 45 half-width katakana plus the 10 digits — 55 characters, an approximation of the Matrix end-credit font. The "glyphs" field is required on the page because every distinct character you type becomes one raindrop glyph (2–128 unique characters): 01 gives a binary-looking rain, 你好世界 gives a Chinese one. Only a direct call to the exported txtMatrix without glyphs falls back to the built-in library.
What exactly does "frames to advance" change?
Each frame moves every head down by "rows per frame"; once a head passes the row count plus the trail length it jumps back above the screen with a seed-driven random offset, which is why the columns are out of sync. # marks the current head and the trail length decides how many glyphs follow above it. With the defaults: 0 frames leaves the grid empty, 2 frames shows 11 visible cells and 8 frames shows 78. Frames only describe the current frame — no history is cached.
Which limits apply?
Columns 1–400, rows 2–400, frames to advance 0–10000, rows per frame greater than 0 and at most 20, trail 1 up to the row count, seed an integer from 0 to 4294967295, and 2–128 unique glyph characters. Out-of-range values report which field failed instead of silently falling back to a default.
Can it export an image or a video?
No. The tool outputs plain text grids (optionally copied) — no PNG, GIF or video, and no DOM animation. Feed the text into your own renderer if you need motion.
Keywords:Matrixmatrix rainascii artxorshift32