Agent skill · design visual · erichowens
metal-shader-expert
20 years Weta/Pixar experience in real-time graphics, Metal shaders, and visual effects. Expert in MSL shaders, PBR rendering, tile-based deferred rendering (TBDR), and GPU debugging. Activate
Why this skill is useful
Adds specialized knowledge on Metal shaders and GPU optimization techniques that are not commonly found in public documentation.
What it needs
Requires xcode installed locally. About 3k tokens when loaded. Last updated 2026-07-14. 180 stars on the source repository.
What this skill does
Metal Shader Expert 20+ years Weta/Pixar experience specializing in Metal shaders, real-time rendering, and creative visual effects. Expert in Apple's Tile-Based Deferred Rendering (TBDR) architecture. When to Use This Skill Use for: Metal Shading Language (MSL) development Apple GPU optimization (TBDR architecture) PBR rendering pipelines Compute shaders and parallel processing Ray tracing on Apple Silicon GPU profiling and debugging Do NOT use for: WebGL/GLSL → different architecture, browser constraints CUDA → NVIDIA-only OpenGL → deprecated on Apple since 2018 CPU-side optimization → use general performance tools Expert vs Novice Shibboleths Topic Novice Expert ------- -------- -------- Data types Uses float everywhere Defaults to half (16-bit), float only when precision needed Specialization Runtime branching Function constants for compile-time specialization Memory Everything in device space Knows constant/device/threadgroup tradeoffs Architecture Treats like desktop GPU Understands TBDR: tile memory is free, bandwidth is expensive Ray tracing Uses intersection queries Uses intersector API (hardware-aligned) Debugging Print debugging GPU capture, shader profiler, occupancy analysis Common Anti-Patterns 32-Bit Everything What it looks like Why it's wrong -------------------- ---------------- float4 color, float3 normal everywhere Wastes registers, reduces occupancy, doubles bandwidth Instead: Default to half, upgrade to float only for positions/depth Ignoring TBDR Architecture What it looks like Why it's wrong -------------------- ---------------- Treating Apple GPU like immediate-mode renderer Tile memory reads are free; bandwidth is not Instead: Use [[color(n)]] freely, prefer memoryless targets, avoid unnecessary store Runtime Branching for Constants What it looks like Why it's wrong -------------------- ---------------- if (material.useNormalMap) checked every fragment Creates divergent warps, wastes ALU Instead: Function constants + pipeline specialization …
How to use it
Reference it in AdaL, Claude Code, Cursor or any coding agent — nothing to install:
@skills erichowens/metal-shader-expert