Export (0) Print
Expand All
0 out of 4 rated this helpful - Rate this topic

Bitmap.Bitmap(Int32, Int32, Int32, PixelFormat, IntPtr) Constructor

Initializes a new instance of the Bitmap class with the specified size, pixel format, and pixel data.

Namespace: System.Drawing
Assembly: System.Drawing (in system.drawing.dll)

public Bitmap (
	int width,
	int height,
	int stride,
	PixelFormat format,
	IntPtr scan0
)
public Bitmap (
	int width, 
	int height, 
	int stride, 
	PixelFormat format, 
	IntPtr scan0
)
public function Bitmap (
	width : int, 
	height : int, 
	stride : int, 
	format : PixelFormat, 
	scan0 : IntPtr
)
Not applicable.

Parameters

width

The width, in pixels, of the new Bitmap.

height

The height, in pixels, of the new Bitmap.

stride

Integer that specifies the byte offset between the beginning of one scan line and the next. This is usually (but not necessarily) the number of bytes in the pixel format (for example, 2 for 16 bits per pixel) multiplied by the width of the bitmap. The value passed to this parameter must be a multiple of four..

format

The PixelFormat enumeration for the new Bitmap.

scan0

Pointer to an array of bytes that contains the pixel data.

The caller is responsible for allocating and freeing the block of memory specified by the scan0 parameter, however, the memory should not be released until the related Bitmap is released.

Windows 98, Windows Server 2000 SP4, Windows CE, Windows Millennium Edition, Windows Mobile for Pocket PC, Windows Mobile for Smartphone, Windows Server 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP SP2, Windows XP Starter Edition

The Microsoft .NET Framework 3.0 is supported on Windows Vista, Microsoft Windows XP SP2, and Windows Server 2003 SP1.

.NET Framework

Supported in: 3.0, 2.0, 1.1, 1.0
Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback

Community Additions

ADD
Show:
© 2014 Microsoft. All rights reserved.