TextureLoader.ComputeNormalMap Method

Language:

Converts a height map into a normal map.

Overload List

public static void ComputeNormalMap(Texture, Texture, NormalMap, Channel, float);
public static void ComputeNormalMap(Texture, Texture, out PaletteEntry, NormalMap, Channel, float);

Remarks

This method computes the normal by using the central difference with a kernel size of 3x3. The (x,y,z) components of each normal are mapped to the (r,g,b) channels of the output texture. RGB channels in the destination contain biased (x,y,z) components of the normal.

Exceptions
InvalidCallException The method call is invalid. For example, a method's parameter might contain an invalid value.


Send comments about this topic to Microsoft. © Microsoft Corporation. All rights reserved.

Feedback? Please provide us with your comments on this topic.
For more help, visit the DirectX Developer Center