8

A world position pass is a pass used for composting other elements into the scene after the initial render. In a world position pass the R, G, B values correspond to the X, Y, Z axis (or X, Z, Y). A world position pass could look something like this. (Image form another 3d app)

enter image description here

Is there a way to render out corresponding world space coordinates of each pixel?

David
  • 49,291
  • 38
  • 159
  • 317
Vader
  • 14,680
  • 16
  • 74
  • 110

1 Answers1

14

Yes, this is possible using the following node setup (click for larger image):

enter image description here

As you can see, the coordinates are the same as the channels (click for larger image):

enter image description here

In the screenshot above the RGB values are slightly different from the coordinates displayed in the Properties panel because those coordinates are measured at the object origin and the RGB channels represent the coordinates at the objects surface.

Also note that the colors will be different than in your screenshot because blender uses Z (blue) up and it appears that the screenshot is of a Y (green) up space. Aside from rotating your actual geometry, you can remap the colors in the node setup (click for larger image):

enter image description here

Now the colors will match your screenshot:

enter image description here

Blendfile

gandalf3
  • 157,169
  • 58
  • 601
  • 1,133