|
Il presente articolo è stato tradotto automaticamente. Passare il puntatore sulle frasi nell'articolo per visualizzare il testo originale. Ulteriori informazioni.
|
Traduzione
Originale
|
Classe Bitmap
Spazio dei nomi: System.Drawing
Assembly: System.Drawing (in System.Drawing.dll)
Il tipo Bitmap espone i seguenti membri.
| Nome | Descrizione | |
|---|---|---|
![]() | Bitmap(Image) | |
![]() | Bitmap(Stream) | |
![]() | Bitmap(String) | |
![]() | Bitmap(Image, Size) | |
![]() | Bitmap(Int32, Int32) | |
![]() | Bitmap(Stream, Boolean) | |
![]() | Bitmap(String, Boolean) | |
![]() | Bitmap(Type, String) | |
![]() | Bitmap(Image, Int32, Int32) | |
![]() | Bitmap(Int32, Int32, Graphics) | |
![]() | Bitmap(Int32, Int32, PixelFormat) | |
![]() | Bitmap(Int32, Int32, Int32, PixelFormat, IntPtr) |
| Nome | Descrizione | |
|---|---|---|
![]() | Flags | |
![]() | FrameDimensionsList | |
![]() | Height | |
![]() | HorizontalResolution | |
![]() | Palette | |
![]() | PhysicalDimension | |
![]() | PixelFormat | |
![]() | PropertyIdList | |
![]() | PropertyItems | |
![]() | RawFormat | |
![]() | Size | |
![]() | Tag | |
![]() | VerticalResolution | |
![]() | Width |
| Nome | Descrizione | |
|---|---|---|
![]() | Clone() | |
![]() | Clone(Rectangle, PixelFormat) | |
![]() | Clone(RectangleF, PixelFormat) | |
![]() | CreateObjRef | |
![]() | Dispose() | |
![]() | Equals(Object) | |
![]() ![]() | FromHicon | |
![]() ![]() | FromResource | |
![]() | GetBounds | |
![]() | GetEncoderParameterList | |
![]() | GetFrameCount | |
![]() | GetHashCode | |
![]() | GetHbitmap() | |
![]() | GetHbitmap(Color) | |
![]() | GetHicon | |
![]() | GetLifetimeService | |
![]() | GetPixel | |
![]() | GetPropertyItem | |
![]() | GetThumbnailImage | |
![]() | GetType | |
![]() | InitializeLifetimeService | |
![]() | LockBits(Rectangle, ImageLockMode, PixelFormat) | |
![]() | LockBits(Rectangle, ImageLockMode, PixelFormat, BitmapData) | |
![]() | MakeTransparent() | |
![]() | MakeTransparent(Color) | |
![]() | RemovePropertyItem | |
![]() | RotateFlip | |
![]() | Save(String) | |
![]() | Save(Stream, ImageFormat) | |
![]() | Save(String, ImageFormat) | |
![]() | Save(Stream, ImageCodecInfo, EncoderParameters) | |
![]() | Save(String, ImageCodecInfo, EncoderParameters) | |
![]() | SaveAdd(EncoderParameters) | |
![]() | SaveAdd(Image, EncoderParameters) | |
![]() | SelectActiveFrame | |
![]() | SetPixel | |
![]() | SetPropertyItem | |
![]() | SetResolution | |
![]() | ToString | |
![]() | UnlockBits |
| Nome | Descrizione | |
|---|---|---|
![]() ![]() | ISerializable.GetObjectData |
Nota |
|---|
Bitmap image1; private void Button1_Click(System.Object sender, System.EventArgs e) { try { // Retrieve the image. image1 = new Bitmap(@"C:\Documents and Settings\All Users\" + @"Documents\My Music\music.bmp", true); int x, y; // Loop through the images pixels to reset color. for(x=0; x<image1.Width; x++) { for(y=0; y<image1.Height; y++) { Color pixelColor = image1.GetPixel(x, y); Color newColor = Color.FromArgb(pixelColor.R, 0, 0); image1.SetPixel(x, y, newColor); } } // Set the PictureBox to display the image. PictureBox1.Image = image1; // Display the pixel format in Label1. Label1.Text = "Pixel format: "+image1.PixelFormat.ToString(); } catch(ArgumentException) { MessageBox.Show("There was an error." + "Check the path to the image file."); } }
Windows 8, Windows Server 2012, Windows 7, Windows Vista SP2, Windows Server 2008 (ruoli di base del server non supportati), Windows Server 2008 R2 (ruoli di base del server supportati con SP1 o versione successiva, Itanium non supportato)
.NET Framework non supporta tutte le versioni di ciascuna piattaforma. Per un elenco delle versioni supportate, vedere Requisiti di sistema di .NET Framework.
