webgl-particle-galaxy
What it does
Creates a visually stunning animation of thousands of bright points spinning together, like a galaxy. This all happens directly in your browser without needing any downloads.
When to use it
- βTo create a futuristic animated background for a website.
- βTo demonstrate complex visual effects on a web page.
- βWhen you need an eye-catching and technically interesting visual element.
Skill link
https://github.com/nexu-io/open-design/blob/main/plugins/_official/examples/webgl-particle-galaxy/SKILL.mdCopy it and paste it into your AI (Claude, ChatGPT or Cursor), asking it to follow the instructions.
How to use
The easiest way: copy the message and paste it into your AI. It reads the skill and follows the instructions.
Ready-to-paste message
For Claude Code, Codex or Cursor: run it in your project folder and the skill gets installed.
Download the SKILL.md and drop it into your agentβs skills folder.
Example of what to ask your AI
βCreate a spinning particle galaxy for my website background.β
5 new skills a week. 1 minute to read.
How it works
It uses a technology called WebGL to draw thousands of points directly on your computer's graphics card. These points move in orbits calculated in real-time, creating the galaxy effect.
Technical content (original SKILL.md)
Original text by the author, straight from GitHub.
Particle Galaxy Skill
Produce a single self-contained index.html that renders a real-time particle system full-screen, with a clean typographic overlay on top. The signature move: compute each particle's position on the GPU so the CPU never loops over particles.
Why this is a powered artifact
OpenDesign detects getContext('webgl2') and renders this file in powered preview β a cross-origin-isolated iframe with allow-same-origin. The full GPU pipeline is available; you do not need to work around the opaque sandbox.
Resource map
webgl-particle-galaxy/
βββ SKILL.md β you're reading this
βββ example.html β a working 50,000-point WebGL2 galaxy (READ FIRST)
Workflow
Step 0 β Read the reference
Read example.html end to end. Note the shape: no vertex buffer β the vertex shader reads gl_VertexID, hashes it into a stable per-particle seed, and derives a log-spiral orbit with an inner-fast rotation curve. Points are drawn with gl.drawArrays(gl.POINTS, 0, N) in one call, additive-blended (blendFunc(ONE, ONE) with premultiplied color) so overlapping points glow.
Step 1 β Pick the motion
Choose a field the vertex shader can express cheaply from gl_VertexID + uTime:
- Spiral galaxy (default): log-spiral arms, rotation curve
speed β k / (r + Ξ΅), thin disk. - Attractor / flow: curl or a strange-attractor step baked as a closed-form function of time.
- Explosion / reform: interpolate between a seeded start and a target shape on a looping clock.
Step 2 β Build index.html
- One file, zero external requests. Bind a VAO even with no attributes (some drivers require it).
- Point size in the vertex shader (
gl_PointSize), clamped and DPR-aware; soft round sprites viagl_PointCoord+ a gaussian falloff in the fragment shader. - Additive blending on a dark clear color; premultiply the fragment color so
blendFunc(ONE, ONE)reads as glow, not double-exposure. - Compile shaders with error logging (
getShaderInfoLog/getProgramInfoLog) so a typo fails loudly.
Step 3 β Overlay + brand
- Map the accent colors to the active DESIGN.md when one is present; otherwise a restrained dark palette with one vivid accent (the reference uses lime
#63fe13for the arms and a white-blue core). - Headline β€ 15ch plus one supporting line. Never bury the particles behind the text.
Step 4 β Self-review (P0)
- Renders continuously at ~60fps; the FPS badge updates.
- Tens of thousands of points in a single draw call (no per-particle CPU loop).
- No WebGL console errors; program links cleanly.
- Resizes crisply on window resize (no stretching / blur).
- Degrades to a message (not a blank page) if
webgl2is unavailable.
FAQ
What are 'particles' in this context?
They are simply small dots of light or color that, together, form the image of the galaxy.
Why is it fast?
Because the movement calculation for each point is done by the graphics card (GPU), which is much faster for this type of task than the main processor (CPU).
Do I need to install anything?
No, everything runs directly in your modern web browser.
Details
Original description by the author
A real-time particle galaxy β tens of thousands of additive-blended GPU points spiraling around a bright core, their orbits solved entirely in the vertex shader (from gl_VertexID), so the whole cloud draws in one call. Rendered as a single self-contained `index.html`. Use when the brief asks for a "particle field", "particle galaxy", "point cloud", "instanced points", "starfield", "GPU particles",
repo: nexu-io/open-design
Popularity
- GitHub stars
- 101k
- Ranking position
- #1061
- License
- Apache-2.0
- Updated
- 10/15/2026
Comments
- β¦
More skills from this repository
sample-plugin
101kMakes your agent create a metadata file for tests. It helps ensure code works correctly in different situations.
aster-atelier
101kHelps your agent create an artistic website with a classic look. It uses elegant imagery, blue skies, and serif fonts for a cinematic feel.
audio-jingle
101kMakes your agent generate audio like jingles and sound effects. It can create music and voices, saving the result as an audio file.
blog-post
101kHelps your agent write long articles or blog posts. It includes space for images, quotes, and author information.
Similar skills
gifgrep
394kLets your agent search GIF libraries, preview results, download a GIF, and pull out a still frame or a contact sheet of frames.
meme-maker
394kLets your agent pick a meme template, add your own captions, and create the meme as an SVG or PNG image.
ios-icon-gen
280kLets your agent generate icons for iOS apps. It uses Apple symbols or icons from other sources to create the correct files.