Skip to main content
Version: 5.x

Nodes > Functions > Util > Position From Depth

Position From Depth

Converts a depth value to a position.

Inputs

NameTypeDescription
DepthfloatInput depth to be converted
UV CoordsfloatScreen space UV coordinates for the x and y axes
Near PlanefloatCamera near clip distance. Used with Far Plane to linearize depth when Use Custom Camera is enabled
Far PlanefloatCamera far clip distance. Used with Near Plane to linearize depth when Use Custom Camera is enabled
FOV (Radians)floatField of view in radians. Used to build the projection terms when Use Custom Camera is enabled
Aspect RatiofloatWidth / height of the view. Used with FOV to build the projection terms when Use Custom Camera is enabled
View InversematrixInverse view matrix

Outputs

NameTypeDescription
PositionfloatThe converted output position

Properties

NameTypeDescription
Position SpacedropdownThe space of the position value
CoordsdropdownChoose what source to use for the UV Coordinates. If "UV Coord 0" or "UV1 Coord 1" are selected, the respective surface UV set will be used. If "Custom" is selected, the UV Coords input will be exposed and used instead
Use Custom CameraboolEnables custom camera properties. When checked, the node will use these properties to transform the depth from screen space to world/view space
Was this page helpful?
Yes
No