Blur effect Flip the image upside down

Hello, i’m doing a game with sequences inside the water, and i put the blur effect when on it. With one camera, no problem. With 2 cameras for optimise, the image flip… When i use 2 cams, the near cam is in “depth only” and the far cam in “skybox” (clear flag). I was using this for optimise many of my games, and never happend any problem… until now. I tink that “depth only” flip the image when Blur is on.

i was trying to change the clear flag, and seems that only “skybox” and “solid color” support the Blur effect. But for a multicamera i need that my first cam is in “depth only” (or another solution ?)

I was searching everywhere before posting and find nothing that realy helps… so i prefere to ask.

What about using a single cam and transform the other in a simple helper and just move the cam to the helper when needed?

what do you mean by Helper? Can you be more precise?

I will give another information for precise myself too, the multicamera i use is for only see some objects that are in specified layers and until a certain distance. The front camera see from 0.3 to 300, and the far camera see from 300 to infinite. In the water i was putting fog, so we don’t see over 300 meters. Like this i can put all the heavy elements in a specific layer that will not calculate them over 300 meters of distance. (but underwater, my multicam don’t work because of the blur effect…:()

A helper is a simple object that has position and rotation coordinates, and empty object but I see you don’t need this in your case.

What you are trying to achieve is pretty heavy into the rendering stuff of Unity, so I can’t help you :smile:

Thank you anyway :slight_smile:

So if there is no solution for the flip back effect of the blur, does someone know another effect similar that can be more fonctionnaly?

Are you using custom-written shaders?
This might help
http://docwiki.unity3d.com/index.php?n=Main.SL-PlatformDifferences

Well, i know that is a mess, but i was never touching the shaders. I was finding http://forum.unity3d.com/threads/76256-post-processing-dream-shader that show a shader that is exactly what i need but in black and white. The good new is that this shader works with the “depth only” so i just need to be able to disable the black and white effect from this shader. Is someone can find in wich line it is :

Shader "Hidden/Dream" {
Properties {
	_MainTex ("Base (RGB)", 2D) = "white" {}
}

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 sampler2D _MainTex;

			float4 frag (v2f_img i) : COLOR {
				float4 c = tex2D(_MainTex, i.uv);
				c += tex2D(_MainTex, i.uv+0.001);
				c += tex2D(_MainTex, i.uv+0.003);
				c += tex2D(_MainTex, i.uv+0.005);
				c += tex2D(_MainTex, i.uv+0.007);
				c += tex2D(_MainTex, i.uv+0.009);
				//c += tex2D(_MainTex, i.uv+0.011);
				
				c += tex2D(_MainTex, i.uv-0.001);
				c += tex2D(_MainTex, i.uv-0.003);
				c += tex2D(_MainTex, i.uv-0.005);
				c += tex2D(_MainTex, i.uv-0.007);
				c += tex2D(_MainTex, i.uv-0.009);
				//c += tex2D(_MainTex, i.uv-0.011);
				c.rgb = float3((c.r+c.g+c.b)/3.0);
				c = c / 9.5;
				return c;
			}
		ENDCG

	}
}

Fallback off

}