[]
Initializes a new instance of the Bitmap class with the specified size.
public Bitmap(int width, int height)
| Type | Name | Description |
|---|---|---|
| int | width | The width, in pixels, of the new Bitmap object. |
| int | height | The height, in pixels, of the new Bitmap object. |
Intializes a new instance of the Bitmap class with the specified size color format (color planes and bits-per-pixel).
public Bitmap(int width, int height, BitsPerPixel bitsPerPixel)
| Type | Name | Description |
|---|---|---|
| int | width | The width, in pixels, of the new Bitmap object. |
| int | height | The height, in pixels, of the new Bitmap object. |
| BitsPerPixel | bitsPerPixel | The number of bits required to identify the color of a single pixel. |
Intializes a new instance of the Bitmap class with the specified size color format (color planes and bits-per-pixel).
public Bitmap(int width, int height, int planes, BitsPerPixel bitsPerPixel, byte[] data)
| Type | Name | Description |
|---|---|---|
| int | width | The width, in pixels, of the new Bitmap object. |
| int | height | The height, in pixels, of the new Bitmap object. |
| int | planes | Specifies the number of planes for the target device. This value must be set to 1. |
| BitsPerPixel | bitsPerPixel | The number of bits required to identify the color of a single pixel. |
| byte[] | data | The pattern data array. |
public Bitmap(Graphics graphics, int width, int height)
| Type | Name | Description |
|---|---|---|
| Graphics | graphics | A Graphics object. |
| int | width | The width, in pixels, of the new Bitmap object. |
| int | height | The height, in pixels, of the new Bitmap object. |
Initializes a new instance of the Bitmap class.
public Bitmap(Bitmap gdiplusBitmap)
| Type | Name | Description |
|---|---|---|
| Bitmap | gdiplusBitmap | A Bitmap indicates the GDI+ bitmap. |
Initializes a new instance of the Bitmap class.
public Bitmap(Bitmap gdiplusBitmap, Color backgroundColor)
| Type | Name | Description |
|---|---|---|
| Bitmap | gdiplusBitmap | A Bitmap indicates the GDI+ bitmap. |
| Color | backgroundColor | A Color structure that specifies the background color. This parameter is ignored if the bitmap is totally opaque. |