Reading (as opposed to measuring) camera height above terrain?

Started by PabloMack, April 16, 2014, 03:12:42 PM

Previous topic - Next topic

PabloMack

Does anyone know of a trivial way to know how far the camera is from the terrain below? This would be the distance between camera and terrain along a line that is defined by the camera's position and the center of the planet (i.e. normal to the planet's sphere). I know I can make the camera look down and then mouse over the terrain below but this would not give an exact value. This value is so important in compositing two 3D spaces (real and/or virtual) that it would be very useful to be able to read it somewhere rather than to try to measure it.

Oshyan

On the View menu open 3D Preview Location. Look for Vheight. This shows the camera height above terrain for the current 3D preview camera position (which may be different than the actual camera position if you have moved the camera in 3D preview since the last Set Camera).

- Oshyan

PabloMack

That's great. I see it doesn't actually update the panel with numbers until you mouse over the preview area. This is exactly what I need. Thanks.

Also, it appears that the cursor "looks through" any objects you are mousing over and just measure the terrain except for when you actually point to the object's marker. This tells me that you can't measure the Vheight from the surface of an object (which you can't actually see its image anyway) but just the underlying terrain. The numbers stop changing when you point to the object's marker so I presume that the values that the numbers set to when this happens is where the origin of the local object's coordinate system has been placed by TG on the terrain. Is this a correct understanding? Thanks.

jo

Hi,

Yes, that's correct. All measurements and distances you see in various things related to the 3D Preview, such as the preview location, coordinate readouts under the preview and measurements using measure mode, are done based on the parts of the scene under the mouse excluding objects. For example mousing over the terrain surface and the sky will give valid measurements but mousing over an object won't. As you've seen, the measurement in that case will be based on the terrain under the mouse and not the object. At some point we should change it so objects are considered in this too, but that's the way it works for now.

When you mouse over an object's handle (or anything else which has a handle, like some shaders) the coordinate readouts lock to the position of the object. To put it simply, they show what you'd see in the object's position parameter.

Regards,

Jo