shader-programming

A guide to writing small programs that run on the graphics processor to control how game objects are shaped, textured, colored, and lit. It explains shared ideas in GLSL and their equivalents in HLSL, two common shader languages.

In plain words
What is it for?
Use it to build tinting, scrolling textures, dissolves, outlines, rim lighting, vignettes, color grading, and other vertex or pixel effects.
Why use it?
It helps explain effects in terms that work across different game engines and avoids confusing vertex work with pixel work. It also helps when translating an effect from one shader language or engine to another.

Skill for Claude CodeCodex

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/ukanwat/aaabench/shader-programming
Any agent
npx skills add ukanwat/aaabench --skill shader-programming
Clone the repo
git clone --depth 1 https://github.com/ukanwat/aaabench

Made for: Claude Code, Codex.

Per session 95 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,857 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin 100% copy Near-identical to another mod in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00095 $0.01857
Opus 5 $0.00048 $0.00928
Sonnet 5 $0.00019 $0.00371
Haiku 4.5 $0.00010 $0.00186

Measured 3d ago against content hash 5e8011dceb84, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

shader-programming scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 3d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

Origin

This is a copy

100% identical to shader-programming — 6 lines differ, which has more behind it and is treated as the original. This page carries a canonical link to it rather than competing with it.

.claude/skills/shader-programming/SKILL.md · 158 lines

How it starts

The opening of the file, as written. The whole thing — 158 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Shader programming (cross-engine)

Shaders are small programs that run per vertex and per pixel on the GPU. The concepts — the pipeline, coordinate spaces, UVs, and how common effects are built — port across engines; only the language dialect and built-in variable names change. This skill teaches those portable fundamentals in GLSL with HLSL equivalents; use godot-shaders (or Unity/Unreal material docs) for the exact engine syntax and built-ins.

When to use

  • Use to understand or write vertex/fragment shaders and to reason about UVs, coordinate spaces, and the GPU pipeline.
  • Use to build common effects: tint/recolor, scrolling textures, dissolve, outlines, fresnel/rim light, vignette, color grading.
  • Use to translate a shader concept between GLSL and HLSL, or between engines.

When not to use: for an engine's exact shader language and built-ins, use godot-shaders (Godot shading language) or the engine's material docs. For full particle VFX systems, see unreal-niagara. For post-process stacks, defer to the engine's renderer settings.

Core workflow

  1. Know which stage you're in. The vertex shader transforms each vertex into clip space and passes data (UVs, normals) onward; the fragment/pixel shader runs per rasterized pixel and outputs a color. Most game effects live in the fragment stage.
  2. Track coordinate spaces. Positions move model → world → view → clip space; normals belong in world or view space. Mixing spaces is the most common bug.
  3. Drive effects with UVs and time. UVs are 0..1 texture coordinates; offset, scale, or distort them, and animate with a time uniform.
  4. Work per pixel, branch-light. Prefer mix, step, smoothstep, and clamp over if where possible; GPUs run pixels in lockstep and dislike divergent branches.
  5. Pass data via uniforms (constant per draw) and varyings (interpolated vertex→fragment). Keep texture samples few; they dominate cost.
  6. Verify visually and on target hardware. Shaders that look right on desktop can break on mobile (precision, missing features). Test where it ships.

Read the full file on GitHub · 158 lines

Files

What ships with it

1 file beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 3d ago First seen · 158 lines · 95 tokens per session scan A 5e8011dceb84

Subscribe to this mod's changes

shader-programming is a skill published in the GitHub repository ukanwat/aaabench (378 stars, last pushed 19d ago), licensed MIT. It adds 95 tokens to every session and 1,857 once invoked, about $0.0005 per session on Opus 5. A static security scan graded it A with 0 findings. It is 100% identical to shader-programming, differing in 6 lines, and is treated as a copy.

Related

Other skills, from other repositories

unreal-pie

Domain skill - Unreal Engine Play-In-Editor (PIE) closed-loop verification. Provides PIE lifecycle control (enter/pause/resume/exit), controlled input injection (no OS dependency), viewport screenshot capture, output log snapshot, performance sampling, and Automation Test execution with async job polling. Use for…

dcc-mcp/dcc-mcp-unreal · 74 tokens

unreal-playtest-agent

Domain skill - run screenshot-light PIE playtest episodes with structured entity observations, bounded semantic actions, transition polling, and in-memory traces for QA and external policy or RL runners.

dcc-mcp/dcc-mcp-unreal · 41 tokens

unreal-actors

Domain skill - Unreal Engine actor management: list, spawn, transform, and delete level actors. Use when inspecting or editing actors in the current Unreal Editor level. Not for Content Browser asset import/export - use unreal-assets for that.

dcc-mcp/dcc-mcp-unreal · 51 tokens

unreal-cinematics

Domain skill — Sequencer shot and keyframe orchestration, camera cut tracks, and Movie Render Queue job setup. Use when creating or editing Level Sequences, authoring camera animation, or preparing an MRQ job in Unreal Engine 5. Not for Blueprint scripting (unreal-blueprints) or runtime playback (unreal-runtime).

dcc-mcp/dcc-mcp-unreal · 72 tokens

unreal-fab-assets

Acquire free Fab marketplace content through Unreal Engine's official Fab integration, then verify the imported Content Browser assets. Use when the user asks to find, download, add, or import Fab or Unreal Marketplace assets. Not for arbitrary file imports - use unreal-assets instead.

dcc-mcp/dcc-mcp-unreal · 58 tokens

unreal-metasound

Unreal Engine MetaSound Source authoring through the reflected Builder API: create sources, add typed inputs and exact registered nodes, connect opaque vertex handles, set defaults, inspect nodes, build, save, and validate. Use for procedural audio graphs in Unreal Engine 5.4+. Not for arbitrary asset management or…

dcc-mcp/dcc-mcp-unreal · 72 tokens