mirror of
https://github.com/EsotericSoftware/spine-runtimes.git
synced 2026-02-09 08:38:43 +08:00
[unity] Fixed more fragment shader output declarations (from COLOR to SV_Target), fixes ps4 shader compile error. Related to commit e229dab. See #1374.
This commit is contained in:
parent
df81d607cb
commit
617eb38340
@ -56,7 +56,7 @@ Shader "Spine/Special/SkeletonGhost" {
|
||||
return o;
|
||||
}
|
||||
|
||||
fixed4 frag (VertexOutput i) : COLOR {
|
||||
fixed4 frag (VertexOutput i) : SV_Target {
|
||||
fixed4 tc = tex2D(_MainTex, i.uv);
|
||||
tc = fixed4(max(_TextureFade, tc.r), max(_TextureFade, tc.g), max(_TextureFade, tc.b), tc.a);
|
||||
return tc * ((i.color * _Color) * tc.a);
|
||||
|
||||
@ -105,7 +105,7 @@ Shader "Spine/Blend Modes/Skeleton PMA Multiply" {
|
||||
uniform sampler2D _MainTex;
|
||||
uniform fixed _Cutoff;
|
||||
|
||||
float4 frag (v2f i) : COLOR {
|
||||
float4 frag (v2f i) : SV_Target {
|
||||
fixed4 texcol = tex2D(_MainTex, i.uvAndAlpha.xy);
|
||||
clip(texcol.a * i.uvAndAlpha.a - _Cutoff);
|
||||
SHADOW_CASTER_FRAGMENT(i)
|
||||
|
||||
@ -55,7 +55,7 @@ Shader "Spine/Skeleton Fill" {
|
||||
return o;
|
||||
}
|
||||
|
||||
float4 frag (VertexOutput i) : COLOR {
|
||||
float4 frag (VertexOutput i) : SV_Target {
|
||||
float4 rawColor = tex2D(_MainTex,i.uv);
|
||||
float finalAlpha = (rawColor.a * i.vertexColor.a);
|
||||
|
||||
@ -102,7 +102,7 @@ Shader "Spine/Skeleton Fill" {
|
||||
return o;
|
||||
}
|
||||
|
||||
float4 frag (VertexOutput i) : COLOR {
|
||||
float4 frag (VertexOutput i) : SV_Target {
|
||||
fixed4 texcol = tex2D(_MainTex, i.uvAndAlpha.xy);
|
||||
clip(texcol.a * i.uvAndAlpha.a - _Cutoff);
|
||||
SHADOW_CASTER_FRAGMENT(i)
|
||||
|
||||
@ -60,7 +60,7 @@ Shader "Spine/Skeleton Tint" {
|
||||
return o;
|
||||
}
|
||||
|
||||
float4 frag (VertexOutput i) : COLOR {
|
||||
float4 frag (VertexOutput i) : SV_Target {
|
||||
float4 texColor = tex2D(_MainTex, i.uv);
|
||||
|
||||
#if defined(_STRAIGHT_ALPHA_INPUT)
|
||||
@ -105,7 +105,7 @@ Shader "Spine/Skeleton Tint" {
|
||||
return o;
|
||||
}
|
||||
|
||||
float4 frag (VertexOutput i) : COLOR {
|
||||
float4 frag (VertexOutput i) : SV_Target {
|
||||
fixed4 texcol = tex2D(_MainTex, i.uvAndAlpha.xy);
|
||||
clip(texcol.a * i.uvAndAlpha.a - _Cutoff);
|
||||
SHADOW_CASTER_FRAGMENT(i)
|
||||
|
||||
@ -53,7 +53,7 @@ Shader "Spine/Special/Skeleton Grayscale" {
|
||||
return o;
|
||||
}
|
||||
|
||||
float4 frag (VertexOutput i) : COLOR {
|
||||
float4 frag (VertexOutput i) : SV_Target {
|
||||
float4 rawColor = tex2D(_MainTex,i.uv);
|
||||
float finalAlpha = (rawColor.a * i.vertexColor.a);
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user