I want to render the normals of a scene in Blender, and I'm doing this with the the 'normals' matcap texture. It seems to be mostly correct. At least in some simple test cases, the pixel intensities matched my calculated values.

However, I animated a 360-degree camera spin, and at one point many of the pixels turn grey. This is super weird to me since in the frame before and after (where the camera angle is slightly different), the colors are strongly red or blue. Is this a bug or is this expected behavior?

Here are the frames before and after the greying.

Left -> Middle - all grey -> Right


If you are using Blender Render and a texture with Normal Coordinates (as opposed to the viewport MatCap), the grey pixels apparently come from the image sampling.

In the Texture properties, try setting Extension to 'Clip'.

Or use the OpenGL render with the Normal matcap, which works well.

This happens because when your camera view vector is normal to the faces' normal vectors (in other words, when the face normals are at 90°), the texture is sampled at its border. If the surface is vertical or horizontal (eg. walls and floors) AND the texture repeats, it is sampled at both the left and right borders (respectively top and bottom for floors and ceilings), resulting in an averaged grey.

  • $\begingroup$ Setting tex.extension = 'CLIP' did the trick! Thanks very much for suggesting the fix and also for explaining what caused the original problem. $\endgroup$ – Sasha Jan 4 '17 at 22:09

If you want a 360 view of the environment you can also try to render a single 360° image ( which can be done like this )

enter image description here

it won't be viewable from the viewport but once you render it is a complete 360° picture which can be animated as a camera spin in editing.

  • $\begingroup$ This doesn't make much sense for a normal render. $\endgroup$ – Pisurquatre Jan 3 '17 at 10:56
  • $\begingroup$ Thanks for taking the time to answer. This is a good tip but doesn't address the problem that the normals are incorrect. $\endgroup$ – Sasha Jan 4 '17 at 22:11

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.