# ToonShaderWithOutline
**Repository Path**: mokefyni/ToonShaderWithOutline
## Basic Information
- **Project Name**: ToonShaderWithOutline
- **Description**: A toon shader with detail outline effect.
- **Primary Language**: Unknown
- **License**: MIT
- **Default Branch**: master
- **Homepage**: None
- **GVP Project**: No
## Statistics
- **Stars**: 0
- **Forks**: 0
- **Created**: 2020-04-24
- **Last Updated**: 2020-12-19
## Categories & Tags
**Categories**: Uncategorized
**Tags**: None
## README
Toon Shader With Outline
=======


I use 2 extra shaders to generate screen space uv & normal map textures.
Then. use *Roberts operator* to do the edge detection for normal, uv, depth.
Each texture's samping result can be toggled on/off.
How To Use
-------------------
- Create an empty object and add *ToonCamera* component to it.
- Specific the toon layer on the *ToonCamera*. Only the selected layer will render by the camera's that generate uv/normal textures.

Credits
======
The edge detection are mainly inspired by [Roystan Ross's blog], please go check it.
Also. thanks to [Thomas Poulet's Ni No Kuni 2: frame analysis] article.
[Roystan Ross's blog]: https://roystan.net/articles/outline-shader.html
[Thomas Poulet's Ni No Kuni 2: frame analysis]: https://blog.thomaspoulet.fr/ninokuni2-frame/