Position Gradient
Position Gradient makes a mask from a Position map: a ramp along a direction over the whole object, or a glow out from a point on it. Rust creeps up from the ground, grime gathers toward the bottom, a fade runs from one end of a model to the other. Every texel of the Position map says where that spot sits on the model, so the ramp runs across the object the same way whatever its UV layout.
Search the node palette for “position gradient”, “height”, “ramp”, “bottom” or “rust”.
The quickest start
Section titled “The quickest start”Start from a model baked by Model Maps (see Texture a Model for the whole chain). Add a Position Gradient and wire Model Maps’ Position output into its Position input. The Model node feeding that Model Maps is wired into the gradient’s Model input in the same undo step, when that input is empty. At a new node’s defaults the mask runs from black at the very top of the model to white at its very bottom, over the model’s whole height, whatever its size or shape.
For rust toward the bottom, multiply the gradient by a 3D Noise on the same Position map so its top edge is ragged, sharpen the product with a Levels, and use it as the mask of a fill that lays a rust color and a rough, dull surface over the model. Rust toward the bottom builds it end to end.
Shape picks the gradient’s form: Linear (the default), along a direction across the whole object, or Spherical, out from a point.
Linear: along a direction
Section titled “Linear: along a direction”- Yaw (degrees) and Pitch (degrees) set the direction the gradient runs along, in 3D Render’s camera convention: Pitch -90 (the default) runs straight down, so the top is black and the bottom white; Pitch 90 runs straight up; Yaw turns around the vertical axis, 0 toward the model’s front. The direction ball under the rows aims it in the view of the 3D Render showing the model, as on Directional Mask; the drag is one undo step.
- Start (%) and End (%) place the ramp, in percent of the object’s own extent along the direction, from -50 to 150: 0% is the point of the model farthest against the direction and 100% the point farthest along it. The mask is black at Start and before it, white at End and beyond, with a straight ramp between. The defaults, 0% and 100%, span the whole object. Raise Start to 70% to keep the rust in the lowest third; set Start above End to reverse the ramp.
The extent is measured from the Position map itself every time the node cooks, over every texel whose alpha is above 0.5: all of a Model Maps bake, which is opaque, and only the covered texels of a bake from another app with a transparent background. So the defaults span the whole object on a tall, long, flat or outside-baked model alike. Over a bake that is one map per material, the extent is measured once over every material’s frame together, so the ramp runs over the whole model and each material’s frame takes its own part of it.
Spherical: out from a point
Section titled “Spherical: out from a point”- Center X, Center Y and Center Z place the center in the Position map’s coordinates, 0 to 1 over the object’s bounding sphere; 0.5 on all three (the default) is the middle of the object’s bounds.
- Radius (%) (1 to 200, default 100) is where the gradient reaches black, in percent of the object’s bounding radius: white at the center, a straight ramp to black at Radius and beyond.
Click to set the center. With Shape on Spherical, select the node, show its mask in the Preview’s UV view, and click the model’s map: the center moves to the point on the model under the pointer, and follows it while you hold the button. The press, the drag and the release are one undo step, and a ring marks the picked point. Clicking outside the object does nothing, and the click is off in the On Model view (where a drag orbits the camera), in the All view of a bake that is one map per material, and while the node is bypassed.
See it on the model
Section titled “See it on the model”With a Model node wired into Model, the Preview offers UV and On Model for the mask, as it does for a Model Maps map. Press M over the Preview to switch between the two. The Camera section, collapsed and last in the panel, holds that view’s camera. The Model input serves this view only: the ramp is always measured from the Position map, never from the model.
Inputs, output and messages
Section titled “Inputs, output and messages”- Position takes a Position map in the model’s UVs, 0 to 1 over the model’s bounding sphere, read as data whatever its tags: Model Maps’ own, or one baked in another app in the same convention. Model is optional.
- Mask is a single-channel mask at the document’s bit depth, opaque everywhere: a transparent background in a bake from another app never cuts a hole in it.
- With nothing wired, the node asks for a Position map.
- A Position map with no texel above alpha 0.5 has no object to measure, and the node says so.
- A map that arrives 8-bit warns that positions step, and asks for a 32-bit bake.
Parameters
Section titled “Parameters”Pins
Gradient
The gradient's form.
- Linear: along a direction, across the whole object.
- Spherical: out from a point. Click this node's mask in the Preview's UV view to set the center.
Direction
The direction the gradient runs along, around the vertical axis, as 3D Render turns its camera. Drag the ball under these rows to aim it in the view of the 3D Render showing this model; Shift snaps to 15 degrees
The direction above or below the horizon: -90 runs straight down, so the top is black and the bottom white; 90 runs straight up
Range
Where the gradient is black, in percent of the object's own extent along the direction: 0% is the point of the model farthest against the direction, 100% the point farthest along it. Black before it; Start above End reverses the gradient
Where the gradient is white, in percent of the object's own extent along the direction: 100% is the point of the model farthest along it. White beyond it
Sphere
The center, in the Position map's coordinates: 0.5 on all three is the middle of the object's bounds. Click this node's mask in the Preview's UV view to set it to the point on the model under the pointer
The center's height, in the Position map's coordinates (0 to 1 over the object's bounding sphere)
The center's depth, in the Position map's coordinates (0 to 1 over the object's bounding sphere)
Where the gradient reaches black, in percent of the object's bounding radius: white at the center, black at Radius and beyond. 100% reaches the bounding sphere
Camera
How the camera draws depth.
- Perspective: farther things look smaller, as through a lens.
- Orthographic: parallel lines stay parallel and size does not change with depth, for front, side, top and isometric views. Distance zooms; Focal Length is not used.
Camera rotation around the model, in degrees. 0 looks straight down the front
Camera elevation above the model, in degrees. Positive looks down at it; 90 looks straight down from the top
How far the camera sits from its Target, as a multiple of the auto-fit distance
Lens focal length in millimeters, 35 mm-equivalent (a 36 x 24 mm sensor). 50 is a normal lens; lower is wider, higher is a telephoto
Where the camera looks and orbits, in model sizes from the model's center. Pan and double-click move it; F resets it
Where the camera looks and orbits, in model sizes from the model's center. Pan and double-click move it; F resets it
Where the camera looks and orbits, in model sizes from the model's center. Pan and double-click move it; F resets it
Usage Tips
Section titled “Usage Tips”- Raise Start rather than adding a Levels when you only want the band lower: Start is in percent of the object, so the band stays put when the model changes.
- Multiply by a 3D Noise for a ragged top edge, then sharpen with a Levels.
- Use Spherical for wear around one spot, such as the handle of a tool or the rim a hand grips.
Related Nodes
Section titled “Related Nodes”Examples
Section titled “Examples”One of the example documents in ArcBrush uses this node.
-
Geometry-Aware Texturing
Masks and projections read from where each spot sits on a model and which way it faces: dust settled on the tops of a bronze lion, snow lying in drifts on the lid of an iron-bound chest, rust creeping up a watering can from the ground and a horse statue projected in red granite with no seams.
Open in ArcBrushDon't have ArcBrush? Download