mirror of
https://github.com/EsotericSoftware/spine-runtimes.git
synced 2026-02-06 07:14:55 +08:00
[unity] URP Skeleton Lit shader does not apply GI in shadow areas. Closes #2343.
This commit is contained in:
parent
5a7360d39c
commit
d9d836d5e5
@ -144,9 +144,6 @@ VertexOutput vert(appdata v) {
|
||||
#endif // !defined(_LIGHT_AFFECTS_ADDITIVE)
|
||||
|
||||
color.rgb *= LightweightLightVertexSimplified(positionWS, normalWS, shadowedColor);
|
||||
#if defined(SKELETONLIT_RECEIVE_SHADOWS)
|
||||
o.shadowedColor = shadowedColor;
|
||||
#endif
|
||||
|
||||
// Note: ambient light is also handled via SH.
|
||||
half3 vertexSH;
|
||||
@ -155,10 +152,14 @@ VertexOutput vert(appdata v) {
|
||||
#else
|
||||
OUTPUT_SH(normalWS.xyz, vertexSH);
|
||||
#endif
|
||||
color.rgb += SAMPLE_GI(v.lightmapUV, vertexSH, normalWS);
|
||||
half3 bakedGI = SAMPLE_GI(v.lightmapUV, vertexSH, normalWS);
|
||||
color.rgb += bakedGI;
|
||||
o.color = color;
|
||||
|
||||
#if defined(SKELETONLIT_RECEIVE_SHADOWS)
|
||||
shadowedColor += bakedGI;
|
||||
o.shadowedColor = shadowedColor;
|
||||
|
||||
VertexPositionInputs vertexInput;
|
||||
vertexInput.positionWS = positionWS;
|
||||
vertexInput.positionCS = o.pos;
|
||||
|
||||
@ -2,7 +2,7 @@
|
||||
"name": "com.esotericsoftware.spine.urp-shaders",
|
||||
"displayName": "Spine Universal RP Shaders",
|
||||
"description": "This plugin provides universal render pipeline (URP) shaders for the spine-unity runtime.\n\nPrerequisites:\nIt requires a working installation of the spine-unity runtime, version 4.1.\n(See http://esotericsoftware.com/git/spine-runtimes/spine-unity)",
|
||||
"version": "4.1.19",
|
||||
"version": "4.1.20",
|
||||
"unity": "2019.3",
|
||||
"author": {
|
||||
"name": "Esoteric Software",
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user