Excluding a layer from Camera DOF

Well, I think my lurking days are over lol.
So let’s get to the subject. I’m trying to remove a single layer from the Depth of Field of my composition camera and the only way of acomplishing that (that I can come up with) is putting the layer in another comp with the same camera properties but without the DOF.
Anyone know any normal way of getting the same result?

p.s. I was looking for the “Start new thread” button for 10 minutes X_X

Yep… that’s about it. You’d need to make a new comp, with a linked or duplicated camera in it and drop that into your main comp (not collapsed) as an overlay.

It can no longer respond to comp lights in the main comp or embed itself inside the 2.5D space.

You might also consider soloing it and rendering out just that layer with alpha channel with DOF off or with draft 3D settings, then importing the pre-render into your main comp.

Same effect as a above.

If you really wanted to embed it in the scene, you could use expressions to turn layers on or off, based on whether they are nearer to or further away from the active camera than your layer.

Something like this on opacity…

C = thisComp.activeCamera;
L = thisLayer;
L1 = thisComp.layer("embed layer"); // the layer you want to embed

myDist = C.toComp(C.fromWorld(L.toWorld(L.anchorPoint)))[2];
L1Dist = C.toComp(C.fromWorld(L1.toWorld(L1.anchorPoint)))[2];


tOpacity = value*(myDist > L1Dist); // show if further away

//or

tOpacity = value*(myDist <=L1Dist); // show if nearer


Then you could render three separate layers and composite them together afterwards. You could even use a central switch to select whether nearer layers or further away layers are displaying. And you could also do this using live compositions… A spiralling world of insanity awaits you…

My only question to you though is…

Why?

-f.

“A spiralling world of insanity awaits you….” It’s already here.

Thanks for the wide responce felt. Thought there’s gonna be a button like “Affect by DOF/or not” for this one.

Why? Well, I’m using a DOF with big numbers which is focused on my videoholder and my textholder is not in the focus distance of the camera. I’ll go with a new comp just for the text with no dof.