When working with Unreal Engine materials, understanding the difference between Actor Position and Object Position nodes can make a huge difference in how you manipulate object locations in your shaders. In this guide, we'll break down what these nodes do, how they differ, and how you can use them to enhance your Unreal Engine materials.
Watch the full tutorial on YouTube
Actor Position & Object Position Nodes
In Unreal Engine, you can find these nodes by right-clicking in the Material Editor and searching for “Position.” Both output a three-vector representing the world-space coordinate of the object using the material, but they differ in behavior: the Actor Position node outputs the world location of the actor the material is assigned to, while the Object Position node outputs the center of the object's bounding box.
Key differences: Actor Position outputs the actor's transform location, while Object Position outputs the center of the bounding box. Object Position is useful for approximations, especially with non-uniform objects. And Actor Position is affected by actor hierarchy: child objects inherit the parent's position.
Visualizing the Difference
To better understand these nodes, enable Show Bounds in the viewport. When you select an object, you'll see a bounding box and sphere representation. Actor Position returns the pivot point's location, while Object Position returns the center of the bounding box.
Unreal Engine Material Editor with Actor Position and Object Position nodes
How Rotation Affects Object Position
When rotating a mesh, the bounding box updates, causing the Object Position node's output to change dynamically. This makes Object Position useful for procedural adjustments but unreliable for fixed placements.
Using These Nodes in Materials
You can connect these nodes to a material's Base Color input to visualize their values: moving an object on the X-axis increases the red channel, the Y-axis increases green, and the Z-axis increases blue. If an object is entirely black, its location or bounds center is at the origin (0,0,0).
Color variations in Unreal Engine based on object position
Example: Creating a Local Gradient Material
You can create a local gradient material by subtracting Object Position from World Position, letting the gradient stick to the object instead of world space: add an Object Position node and a World Position node, subtract Object Position from World Position, multiply by a scaling parameter to control the gradient sharpness, then connect it to Base Color.
Unreal Engine local gradient material
Material graph setup for a local gradient using Object Position
Actor Position & Object Position with Attachments
When an actor is attached to another actor, the Actor Position node returns the parent's position, useful when you need the absolute world position of an object rather than its pivot point. For per-instance control, consider Component Pivot Location or Object Pivot Point instead, which provide accurate pivot positions without the limitations of Actor Position.
Using Camera Relative World Position
Both nodes have an Origin option: Absolute World Position (default) uses the world's origin (0,0,0) as the reference, while Camera Relative World Position uses the camera's position as the origin instead.
Origin options on the Actor Position and Object Position nodes
Final Thoughts
Understanding the Actor Position vs Object Position nodes can significantly improve your material workflows in Unreal Engine. Whether you're working with procedural materials, world-aligned effects, or object-specific shaders, these nodes give you the control you need.