Infinity Px

   1979   3   1
User Avatar
Member
33 posts
Joined: 1月 2015
Offline
I'm rendering out a scene as an EXR and adding a fog effect in After Effects.
So far so good, except that I'd like to set the farthest point as an arbitrary Px value instead of 0. Say 1000. The reason is I'm also rendering the Environment Light as the background and it'd be neat if it could all render in one shot.

I've tried to do this by creating a large sphere but it either renders as a solid and I get the Px value I want, or I make it 0 opacity and then I get no Px value.
It seems Px is absolutely tied to the visibility of an object.

Is there a way around this other than doing two passes? A custom shader maybe?
User Avatar
スタッフ
2540 posts
Joined: 7月 2005
Offline
Can you render the sphere as a matte object? Just toggle on Matte shading in the Render/Shading tab. Matte objects are blockers and show up in Pz but do not contribute to alpha.

Mantra culls geometry with 0 opacity or is fully transparent for efficiency btw.
There's at least one school like the old school!
User Avatar
Member
33 posts
Joined: 1月 2015
Offline
I'm afraid matte doesn't work as it just renders it as solid black. I'm trying to get it to register as a solid object the Pz channel only but otherwise be invisible to C and Alpha.

Alternately, I'd put some kind of code in the renderer along the lines of : IF Pz == 0 THEN Pz = N where N is an imaginary distance of where the sky would be.
User Avatar
Member
33 posts
Joined: 1月 2015
Offline
In the meantime, I've discovered volumes and fog & smoke shaders and that looks better than anything after effects can do with Z maps, although it does hit the render times considerably
  • Quick Links