Click or drag to resize

BitmapExtensionsConvertToNormalMap Method

Use this function to convert a System.Drawing.Bitmap from a bump to a normal texture

Namespace:  Rhino
Assembly:  RhinoCommon (in RhinoCommon.dll)
Since: 7.5
Syntax
public static Bitmap ConvertToNormalMap(
	this Bitmap bitmap,
	bool bLossyCompressionSource,
	out bool bPositiveZComponent
)

Parameters

bitmap
Type: System.DrawingBitmap

[Missing <param name="bitmap"/> documentation for "M:Rhino.BitmapExtensions.ConvertToNormalMap(System.Drawing.Bitmap,System.Boolean,System.Boolean@)"]

bLossyCompressionSource
Type: SystemBoolean
True if the source of the bitmap is an image with lossy compression (e.g. jpg). False otherwise. The check will be less strict if the image can contain errors due to lossy compression.
bPositiveZComponent
Type: SystemBoolean
True if the image is a normal map with the z-component mapped to the range 0 .. +1. False if the image is a normal map with the z-component mapped to the range -1 .. +1.

Return Value

Type: Bitmap

[Missing <returns> documentation for "M:Rhino.BitmapExtensions.ConvertToNormalMap(System.Drawing.Bitmap,System.Boolean,System.Boolean@)"]

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type Bitmap. When you use instance method syntax to call this method, omit the first parameter. For more information, see Extension Methods (Visual Basic) or Extension Methods (C# Programming Guide).
See Also