Re: Camera distance to an object

2013-03-29 Thread Emilio Hernandez
Cool I will try that thanks a lot! 2013/3/29 Andy Moorer > You then need a "distance to plane" calculation... the distance from the > camera to null is the hypotenuse of a right triangle. The angle of that > line versus the z axis of the camera then gives you enough information to > determine

Re: Camera distance to an object

2013-03-29 Thread Andy Moorer
You then need a "distance to plane" calculation... the distance from the camera to null is the hypotenuse of a right triangle. The angle of that line versus the z axis of the camera then gives you enough information to determine the distance to the camera plane the null is on. cos(theta)=a/h where

Re: Camera distance to an object

2013-03-29 Thread Emilio Hernandez
Yes it's working with the null centered. But what if I want the focus on some moving object that is not always in the center of the camera and coming near? It is like a follow focus rig. 2013/3/29 Ben Davis > Makes sense, thanks Tim! > > That means that the info from the "Distance to Output

Re: Camera distance to an object

2013-03-29 Thread Ben Davis
Makes sense, thanks Tim! That means that the info from the "Distance to Output Camera" is doing exactly what you need Emilio, since when centered the ICETree info matches perfectly. -- Ben Davis www.moondog-animation.com +33 6 88 48 54 50 On Fri, Mar 29, 2013 at 10:31 AM, Tim Leydecker wrote

Re: Camera distance to an object

2013-03-29 Thread Tim Leydecker
Hey Ben, the farther offset the null is off center to the center of the camera view the more "off" the DOF would be because the DOF effect is sets in respect to the viewplane of the camera and it would take some Pythagorean theorem (http://en.wikipedia.org/wiki/Hypotenuse) to get the desired majo

Re: Camera distance to an object

2013-03-29 Thread Emilio Hernandez
Thx Ben. The thing is the distance between node output is almost twice the distance reported by the viewport. If I use the value of the Distance Between node, the focus is farther than the expected. I am right now dividing the result by 2 and I think I am getting there and getting the focus plane

Re: Camera distance to an object

2013-03-29 Thread Ben Davis
It looks like "Distance to Output Camera" from the viewport options is spitting out the info from a plane in front of the camera based on the distance from the null if it were in the center of your camera's view. If your null is centered, the values are the same from the ICETree and the viewport in

Camera distance to an object

2013-03-29 Thread Emilio Hernandez
Hello I am trying to rig the camera DOF so I can attach the distance to a null. I am the ICE distance between node. But when I turn on the distance to output camera from the viewer, it gives me a different result. So the Distance to output camera from the viewport options is different than the D