StandardGeometryShader
An example of a geometry shader with Unity's standard lighting model support.
Install / Use
/learn @keijiro/StandardGeometryShaderREADME
Standard Geometry Shader Example

This is an example that shows how to implement a geometry shader that is compatible with the standard lighting model in Unity.
Writing geometry shaders is hard
Implementing a geometry shader in Unity is not easy as it seems because surface shaders don't allow geometry stage customization -- This means that you have to implement the whole lighting passes by yourself without the help of surface shaders.
This example shows the minimum implementation of vertex/geometry/fragment shader set that provides a custom geometry modification along with the standard lighting features.
Limitations
To make the example as simple as possible, some features are intensionally omitted from the shader.
- No forward rendering support (!)
- No lightmap support
- No shadowmask support
- No motion vectors support
- No GPU instancing support
- It hasn't been tested with XR.
It's not impossible to add these features to the shader, that might be pretty troublesome though.
License
Copyright (c) 2017 Unity Technologies
This repository is to be treated as an example content of Unity; you can use the code freely in your projects. Also see the FAQ about example contents.
Related Skills
openhue
344.1kControl Philips Hue lights and scenes via the OpenHue CLI.
sag
344.1kElevenLabs text-to-speech with mac-style say UX.
weather
344.1kGet current weather and forecasts via wttr.in or Open-Meteo
tweakcc
1.5kCustomize Claude Code's system prompts, create custom toolsets, input pattern highlighters, themes/thinking verbs/spinners, customize input box & user message styling, support AGENTS.md, unlock private/unreleased features, and much more. Supports both native/npm installs on all platforms.
