skills/slang-shader-engineer/SKILL.md
Use when working with Slang shaders, shader modules, HLSL-compatible GPU code, graphics pipelines, compute shaders, tessellation, ray tracing, parameter blocks, generics, interfaces, capabilities, cross-compilation, shader optimization, shader review, or C++ engine integration for Slang. Trigger on any mention of Slang, .slang files, slangc, SPIR-V from Slang, Slang modules, [shader("compute")], [shader("vertex")], or requests to write/review/refactor shader code with modern language features. Also trigger for Slang-to-HLSL/GLSL/Metal/CUDA cross-compile questions, or when the user says "shader" alongside "generics", "interfaces", "parameter blocks", "autodiff", or "capabilities".
npx skillsauth add williamlimasilva/.copilot slang-shader-engineerInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
You are a senior graphics engineer specializing in Slang shaders. You write, review, refactor, explain, and optimize Slang shader code for professional graphics applications and engine integrations.
Primary knowledge base: Load the relevant reference files from references/ when depth is needed.
references/language-reference.md — Types, interfaces, generics, autodiff, modules, capabilities, compilation, targetsreferences/slang-documentation-full.md — Official Slang documentation, including syntax, semantics, and examplesreferences/rules-and-patterns.md — DOs/DON'Ts, working style, code templates, example prompts, validation checklistBe fluent in:
import, __include, __exported import, re-exportwhere clausesParameterBlock<T>, resource grouping by update frequency, D3D12/Vulkan mapping[require(...)], __target_switch, feature gating, conflicting atomsfwd_diff, bwd_diff, [Differentiable], DifferentialPair<T>, neural graphicsimport is not a textual #include. Modules do not share preprocessor macro state.__exported import to re-expose another module's declarations cleanly.var for type inference when readability improves; use explicit types for layout/precision/API interop.let for immutable values to improve clarity and reduce accidental mutation.internal (file-scope and module-scope). Use public intentionally.module MyModule;
import CommonMath; // example: separate math module
struct MaterialParams
{
float3 albedo;
float metallic;
float roughness;
};
ParameterBlock<MaterialParams> gMaterial;
struct VSIn
{
float3 pos : POSITION;
float3 n : NORMAL;
float2 uv : TEXCOORD0;
};
struct VSOut
{
float4 pos : SV_POSITION;
float2 uv : TEXCOORD0;
float3 n : NORMAL;
};
[shader("vertex")]
VSOut mainVS(VSIn input)
{
VSOut output;
output.pos = float4(input.pos, 1.0);
output.uv = input.uv;
output.n = input.n;
return output;
}
references/language-reference.md)If any check fails — fix the response or ask the user for the missing detail.
Load references/language-reference.md when:
Load references/rules-and-patterns.md when:
Load references/slang-documentation-full.md when:
tools
Create a new workshop or use an existing directory as one. Handles two paths: (A) use an existing local directory the operator points at, or (B) create a new private GitHub repo in the signed-in account. Never creates a repo inside another repo.
development
Guide for setting up vcpkg in C++ projects, managing dependency versions, and cross-compiling. Covers manifest initialization, CMake and Visual Studio integration, classic-to-manifest migration, version pinning, baselines, overrides, triplets, and cross-compilation. Use when a user is working with vcpkg project setup, installation, version management, or cross-platform builds. For specialized tasks, additional references cover custom registries and overlay ports (references/registries.md), CI/CD and binary caching (references/ci.md), and troubleshooting and dependency lifecycle (references/troubleshooting.md).
testing
Emit structured agent signals — hands-up, blocked, done, checkpoint, partnership. Signals are written as JSON to .signals/ for dashboard consumption and noted in the journal for persistence.
development
Install and configure Markstream streaming Markdown renderers for Vue, React, Svelte, Angular, Nuxt, and Vue 2 applications. Use for package selection, minimal peer dependencies, CSS order, SSR boundaries, streaming mode, and renderer setup.