Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
Delt06 committed Jun 3, 2021
2 parents 1ca894c + f9a54f5 commit 9c4bc6c
Showing 1 changed file with 45 additions and 3 deletions.
48 changes: 45 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,16 +5,18 @@ A toon shader compatible with the Universal Rendering Pipeline.
![Main](Showcase/main.png)

## Shader Capabilities
- 2 or 3-step ramp with configurable thresholds and smoothness- Ramp Texture
- 2 or 3-step ramp with configurable thresholds and smoothness
- Ramp textures
- Main and additional lights
- Main light
- Additional lights (per-vertex or per-pixel, depending on URP settings)
- Casting and receiving shadows
- Configurable shadow color
- Emission
- Rim lighting (Fresnel effect) and specular highlights with HDR color support (e.g. for bloom)
- Fog
- SSAO
- SRP Batcher compatibility
- GPU Instancing

## Extras
- Depth+Normals+Color-based outline render feature
Expand All @@ -31,5 +33,45 @@ Add the following line to `Packages/manifest.json`:
"com.deltation.toon-shader": "https://github.com/Delt06/urp-toon-shader.git?path=Packages/com.deltation.toon-shader",
```

## Performance
Lit vs. URP Toon Shader vs. Toony Colors Pro (Hybrid)

> The results are obtained with Mali Offline Compiler.
Shader Type | Vertex Shader Cycles (L/S) | Fragment Shader Cycles (L/S)
--------------------------|----------------------------|-----------------------------
Lit | 9 | 15
URP Toon Shader | 12 | 10
Toony Colors Pro (Hybrid) | 7 | 15

> L/S = Load/Store.

### Configuration
```
Hardware: Mali-G78 r1p1
Architecture: Valhall
Driver: r25p0-00rel0
```

### Enabled keywords
Lit:
```
Global Keywords: FOG_LINEAR _ADDITIONAL_LIGHTS _ADDITIONAL_LIGHT_SHADOWS _MAIN_LIGHT_SHADOWS _MAIN_LIGHT_SHADOWS_CASCADE _SHADOWS_SOFT
Local Keywords: _EMISSION
```

URP Toon Shader:
```
Global Keywords: FOG_LINEAR _ADDITIONAL_LIGHTS _ADDITIONAL_LIGHT_SHADOWS _MAIN_LIGHT_SHADOWS _MAIN_LIGHT_SHADOWS_CASCADE _SHADOWS_SOFT
Local Keywords: _ADDITIONAL_LIGHTS_ENABLED _ENVIRONMENT_LIGHTING_ENABLED _FOG _FRESNEL _RAMP_TRIPLE _SPECULAR
```

Toony Colors Pro (Hybrid)
```
Global Keywords: FOG_LINEAR TCP2_HYBRID_URP _ADDITIONAL_LIGHTS _ADDITIONAL_LIGHT_SHADOWS _MAIN_LIGHT_SHADOWS _MAIN_LIGHT_SHADOWS_CASCADE _SHADOWS_SOFT
Local Keywords: TCP2_REFLECTIONS_FRESNEL TCP2_RIM_LIGHTING_LIGHTMASK TCP2_SHADOW_LIGHT_COLOR
```

## Used Assets
- [Animated Mech Pack](https://quaternius.com/packs/animatedmech.html) by Quaternius
- [Animated Mech Pack](https://quaternius.com/packs/animatedmech.html) by Quaternius

0 comments on commit 9c4bc6c

Please sign in to comment.