Strange Shader problem

this code works on another project, but when i started new and added this, it renders everything up-side-down.

I took this originally from other image based effects and altered it.

Here is the Shader:

Shader "Hidden/Fade Effect" {
Properties {
	_MainTex ("Base (RGB)", RECT) = "white" {}
	_Fade("FadeAmount", Float ) = 1.0
}

SubShader {
	Pass {
		ZTest Always Cull Off ZWrite Off
		Fog { Mode off }
				
		CGPROGRAM
		#pragma vertex vert_img
		#pragma fragment frag
		#pragma fragmentoption ARB_precision_hint_fastest 
		#include "UnityCG.cginc"

		uniform samplerRECT _MainTex;
		uniform float _Fade;

		float4 frag (v2f_img i) : COLOR
		{
			float4 original = texRECT(_MainTex, i.uv);
			float3 fade;
			fade.rgb = _Fade * original.rgb;
			float4 output;
			output.rgb = fade.rgb;
			output.a = original.a;
			return output;
		}
		ENDCG
	}
}

Fallback off

}

And here is the CS:

using UnityEngine;

[ExecuteInEditMode]
[AddComponentMenu("Image Effects/Fade")]
public class FadeEffect : ImageEffectBase {
	
	public float fade = 1.0f;

	// Called by camera to apply image effect
	void OnRenderImage (RenderTexture source, RenderTexture destination) {
		
		material.SetFloat( "_Fade", fade );
		ImageEffects.BlitWithMaterial (material, source, destination);
	}
}

I’m don’t completely understand these Unitys own shader things, but i’m learning.

I would assume that your other project was a 2.5 project while this one now is 2.6?

some stuff has changed to bring in consistency over platforms and between dx and opengl
ensure you reimport the pro assets that come with 2.6 shouldn’t you have done that yet, so your base effect is the correct one

thanks dreamora, that did the trick. :wink: