I am running into a problem, I want to intensify the red pixels but i cant seem to do so each time i try it brightens the majority of the pixels. How do i fix this?
Code.
Shader "Custom/Shader_12" {
Properties {
_Color ("Color", Color) = (1,1,1,1)
_MainTex ("Albedo (RGB)", 2D) = "white" {}
_Cubemap("Cube Map", CUBE) = "" {}
_ReflAmount("Reflection Amount", Range(0.1, 1)) = 0.5
_CMredC("CM Red Channel", Range(0,255)) = 0
}
SubShader {
Tags { "RenderType"="Opaque" }
LOD 200
CGPROGRAM
// Physically based Standard lighting model, and enable shadows on all light types
#pragma surface surf Lambert
// Use shader model 3.0 target, to get nicer looking lighting
#pragma target 3.0
sampler2D _MainTex;
samplerCUBE _Cubemap;
float _ReflAmount;
float _CMredC;
struct Input {
float2 uv_MainTex;
float3 worldRefl;
};
fixed4 _Color;
void surf (Input IN, inout SurfaceOutput o) {
// Albedo comes from a texture tinted by color
fixed4 c = tex2D (_MainTex, IN.uv_MainTex) * _Color;
float3 CM = texCUBE(_Cubemap, IN.worldRefl).rgb * _ReflAmount;
o.Emission = CM * _CMredC.r;
o.Albedo = c.rgb;
o.Alpha = c.a;
}
ENDCG
}
FallBack "Diffuse"
}