Houdini 21.0 Nodes APEX nodes

transform::ClampedLookAtPorthole

Limits the rotational range of a LookAt to a porthole on a sphere’s surface.

On this page
Since 21.0

This subgraph adds additional functionality to transform::LookAt to limit the range of the resultant LookAt to a circular porthole on the surface of a sphere. It also computes local UV coordinates that describe the offset of the resultant LookAt within the porthole’s available range.

Inputs

xform: Matrix4

The input matrix.

lookat: Matrix4

The position of this matrix determines the look at direction.

lookup: Matrix4

The position of this matrix determines the look up direction.

lookataxis: Vector3

The local axis of the xform matrix that points toward the lookat transform. Defaults to (1, 0, 0).

lookupaxis: Vector3

The local axis of the xform matrix that aligns with the lookup transform. Defaults to (0, 1, 0).

angle: Float

The maximum radial angle at which the rotation of the lookataxis is clamped. The angle is given in degrees, and has a default value of 180, representing the full range.

Outputs

xform: Matrix4

The input matrix with the rotational range limited.

u: Float

A normalized longitude value in the range [0, 1] that represents the point’s horizontal position in the UV window.

v: Float

A normalized latitude value in the range [0, 1] that represents the point’s vertical position in the UV window.

delta: Float

A normalized value in the range [0, 1] that represents the magnitude of the angular offset between the porthole’s center and the porthole’s maximum angle.

See also

APEX nodes