- 1
- 0
У меня есть шейдер для unity но он у меня белый
Вот шейдер
Shader "Alternativa/LayersStandard" {
Properties {
_Color ("Color", Vector) = (1,1,1,1)
[NoScaleOffset] _Masks ("Layer Masks", 2D) = "white" {}
_MainTex1 ("Albedo Layer 1", 2D) = "white" {}
_MainTex2 ("Albedo Layer 2", 2D) = "white" {}
_MainTex3 ("Albedo Layer 3", 2D) = "white" {}
_SmoothnessStrength1 ("Smoothness Layer 1", Range(0, 1)) = 0.5
_SmoothnessStrength2 ("Smoothness Layer 2", Range(0, 1)) = 0.5
_SmoothnessStrength3 ("Smoothness Layer 3", Range(0, 1)) = 0.5
[Gamma] _Metallic1 ("Metallic Layer 1", Range(0, 1)) = 0
[Gamma] _Metallic2 ("Metallic Layer 2", Range(0, 1)) = 0
[Gamma] _Metallic3 ("Metallic Layer 3", Range(0, 1)) = 0
[ToggleOff] _SpecularHighlights ("Specular Highlights", Float) = 1
[ToggleOff] _GlossyReflections ("Glossy Reflections", Float) = 1
_BumpScale1 ("Scale1", Float) = 1
_BumpScale2 ("Scale2", Float) = 1
_BumpScale3 ("Scale3", Float) = 1
_BumpMap1 ("Normal Map Layer 1", 2D) = "bump" {}
_BumpMap2 ("Normal Map Layer 2", 2D) = "bump" {}
_BumpMap3 ("Normal Map Layer 3", 2D) = "bump" {}
[NoScaleOffset] _ParallaxMap1 ("Height Map(B)", 2D) = "white" {}
[NoScaleOffset] _ParallaxMap2 ("Height Map(B)", 2D) = "white" {}
[NoScaleOffset] _ParallaxMap3 ("Height Map(B)", 2D) = "white" {}
_Parallax1 ("Height Scale 1", Range(0.005, 0.08)) = 0.02
_Parallax2 ("Height Scale 2", Range(0.005, 0.08)) = 0.02
_Parallax3 ("Height Scale 3", Range(0.005, 0.08)) = 0.02
_OcclusionStrength1 ("Occlusion Strength 1", Range(0, 1)) = 1
_OcclusionStrength2 ("Occlusion Strength 2", Range(0, 1)) = 1
_OcclusionStrength3 ("Occlusion Strength 3", Range(0, 1)) = 1
_Layer2 ("", Float) = 0
_Layer3 ("", Float) = 0
_ParallaxMapDef_1 ("", Float) = 0
_ParallaxMapDef_2 ("", Float) = 0
_ParallaxMapDef_3 ("", Float) = 0
[Enum(UV0,0,UV1,1)] _UVSec ("UV Set for secondary textures", Float) = 0
[HideInInspector] _Mode ("__mode", Float) = 0
[HideInInspector] _SrcBlend ("__src", Float) = 1
[HideInInspector] _DstBlend ("__dst", Float) = 0
[HideInInspector] _ZWrite ("__zw", Float) = 1
}
//DummyShaderTextExporter
SubShader{
Tags { "RenderType"="Opaque" }
LOD 200
CGPROGRAM
#pragma surface surf Standard
#pragma target 3.0
fixed4 _Color;
struct Input
{
float2 uv_MainTex;
};
void surf(Input IN, inout SurfaceOutputStandard o)
{
o.Albedo = _Color.rgb;
o.Alpha = _Color.a;
}
ENDCG
}
Fallback "VertexLit"
//CustomEditor "LayersStandardShaderGUI"
}
Как это исправить?
Вот шейдер
Shader "Alternativa/LayersStandard" {
Properties {
_Color ("Color", Vector) = (1,1,1,1)
[NoScaleOffset] _Masks ("Layer Masks", 2D) = "white" {}
_MainTex1 ("Albedo Layer 1", 2D) = "white" {}
_MainTex2 ("Albedo Layer 2", 2D) = "white" {}
_MainTex3 ("Albedo Layer 3", 2D) = "white" {}
_SmoothnessStrength1 ("Smoothness Layer 1", Range(0, 1)) = 0.5
_SmoothnessStrength2 ("Smoothness Layer 2", Range(0, 1)) = 0.5
_SmoothnessStrength3 ("Smoothness Layer 3", Range(0, 1)) = 0.5
[Gamma] _Metallic1 ("Metallic Layer 1", Range(0, 1)) = 0
[Gamma] _Metallic2 ("Metallic Layer 2", Range(0, 1)) = 0
[Gamma] _Metallic3 ("Metallic Layer 3", Range(0, 1)) = 0
[ToggleOff] _SpecularHighlights ("Specular Highlights", Float) = 1
[ToggleOff] _GlossyReflections ("Glossy Reflections", Float) = 1
_BumpScale1 ("Scale1", Float) = 1
_BumpScale2 ("Scale2", Float) = 1
_BumpScale3 ("Scale3", Float) = 1
_BumpMap1 ("Normal Map Layer 1", 2D) = "bump" {}
_BumpMap2 ("Normal Map Layer 2", 2D) = "bump" {}
_BumpMap3 ("Normal Map Layer 3", 2D) = "bump" {}
[NoScaleOffset] _ParallaxMap1 ("Height Map(B)", 2D) = "white" {}
[NoScaleOffset] _ParallaxMap2 ("Height Map(B)", 2D) = "white" {}
[NoScaleOffset] _ParallaxMap3 ("Height Map(B)", 2D) = "white" {}
_Parallax1 ("Height Scale 1", Range(0.005, 0.08)) = 0.02
_Parallax2 ("Height Scale 2", Range(0.005, 0.08)) = 0.02
_Parallax3 ("Height Scale 3", Range(0.005, 0.08)) = 0.02
_OcclusionStrength1 ("Occlusion Strength 1", Range(0, 1)) = 1
_OcclusionStrength2 ("Occlusion Strength 2", Range(0, 1)) = 1
_OcclusionStrength3 ("Occlusion Strength 3", Range(0, 1)) = 1
_Layer2 ("", Float) = 0
_Layer3 ("", Float) = 0
_ParallaxMapDef_1 ("", Float) = 0
_ParallaxMapDef_2 ("", Float) = 0
_ParallaxMapDef_3 ("", Float) = 0
[Enum(UV0,0,UV1,1)] _UVSec ("UV Set for secondary textures", Float) = 0
[HideInInspector] _Mode ("__mode", Float) = 0
[HideInInspector] _SrcBlend ("__src", Float) = 1
[HideInInspector] _DstBlend ("__dst", Float) = 0
[HideInInspector] _ZWrite ("__zw", Float) = 1
}
//DummyShaderTextExporter
SubShader{
Tags { "RenderType"="Opaque" }
LOD 200
CGPROGRAM
#pragma surface surf Standard
#pragma target 3.0
fixed4 _Color;
struct Input
{
float2 uv_MainTex;
};
void surf(Input IN, inout SurfaceOutputStandard o)
{
o.Albedo = _Color.rgb;
o.Alpha = _Color.a;
}
ENDCG
}
Fallback "VertexLit"
//CustomEditor "LayersStandardShaderGUI"
}
Как это исправить?