MIT License

项目介绍

ChiliMilk/URP_Toon 是一个托管在 GitHub 上的开源项目,主要使用 C# 编写,采用 MIT License 许可证,目前获得 1.4k 个 Star、104 次 Fork。

仓库全名
ChiliMilk/URP_Toon
开源许可证
MIT License
Star 数
1.4k
Fork 数
104

README 摘要

URP Toon Shader Introduction Properties SurfaceOptions Base Shadow Specular Rim Outline AdvancedOptions Multi Pass Batch Reference Licenses Introduction Simple toon shader in unity universal pipeline. Genshin Impact Style(Model and Texture from miHoYo) Properties SurfaceOptions Base Shadow ShadowType DoubleShade Adjustable two-layer shadow.(Reference UTS) RampMapShadow Shadows based on rampmap. SDFFaceShadow…

完整内容见 GitHub 原始 README 或本页 。

常见问题

URP_Toon 用什么语言开发?

主要使用 C# 编写,采用 MIT License 许可证,目前有 1.4k 个 Star。

URP_Toon 可以免费商用吗?

仓库采用 MIT License 许可证,可免费使用与修改,商业使用请遵守许可证条款(例如保留版权声明与许可声明)。

如何获取 URP_Toon 的源码?

可以直接克隆仓库:git clone https://github.com/ChiliMilk/URP_Toon.git,默认分支为 master;安装与运行步骤见仓库 README。

URP_Toon 最近还在维护吗?

仓库最近一次更新为 2024年2月16日,当前没有未关闭的 Issue;Star 数为 1.4k,可作为社区活跃度的参考。

简要分析

热度分
1580
价值分
845
活跃状态
活跃

README

URP Toon Shader

Introduction

Simple toon shader in unity universal pipeline.

image-UnityChan

Genshin Impact Style(Model and Texture from miHoYo)

image-Genshin_Sample

Properties

SurfaceOptions

image-SurfaceOptions

Base

image-Base

Shadow

image-Shadow

ShadowType
DoubleShade

Adjustable two-layer shadow.(Reference UTS)

RampMapShadow

Shadows based on rampmap.

SDF_FaceShadow (Reference Genshin Impact)

Used for face shadow, sample a precomputed shadow mask to generate shadows. Limit:symmetrical face uv.

image-SDFMask

Need to add a script to the object, set the forward and left direction(ObjectSpace).

image-SDFScript

About how to generate sdf shadow mask. Node:Generate mask in r16 format(antialiasing).

https://zhuanlan.zhihu.com/p/389668800

SSAO (Add “ScreenSpaceAmbientOcclusion” RenderFeature)

Control SSAO strength.

CastHairShadowMask (Add “RenderFrontHairShadowMaskFeature” RenderFeature)

Cast a shadow mask in screen space for face shadow.(Check it on front hair material or something)

ReceiveHairShadowMask

Sample “CastHairShadowMask” for shadow.(Check it on face material)

Specular

image-Specular

Rim

image-Rim

  • RimBlendShadow

image-BlendRim

1:RimBlendShadow=0 2:RimBlendShadow=1 3:RimBlendShadow=1 RimFlip=1

  • RimFlip

Flip RimBlendShadow

Outline

image-Outline

AdvancedOptions

image-AdvancedOptions

Multi Pass Batch

In the default URP, if render multiple pass shaders(outline), the Rendering order like this:
Object1.Pass1-
Objcet1.Pass2-
Object2.Pass1-
Object2.Pass2…
image-BeforeBatch
It will stop SPRBatch.
image-NotSupportBatch
We can change the Rendering order like this by using RenderFeature:
Object1.Pass1-
Objcet2.Pass1-
Object1.Pass2-
Object2.Pass2…
image-AfterBatch

Reference

https://github.com/unity3d-jp/UnityChanToonShaderVer2_Project
https://github.com/Jason-Ma-233/JasonMaToonRenderPipeline
https://github.com/you-ri/LiliumToonGraph
https://github.com/Kink3d/kShading
https://unity.cn/projects/china-unity-tech-week_linruofeng

Licenses

MIT

“Assets/UnityChan/License”

© Unity Technologies Japan/UCL

评论

暂无评论