- Aurigma Graphics Mill 5.5 for .NET
- Introduction
- What's New?
- Overview of Features
- Getting Started
- Programming with Graphics Mill for .NET
- File Formats
- Graphics Mill for .NET Add-ons
- Class Library Reference
- Aurigma.GraphicsMill Namespace
- AbortedException Class
- AdvancedPsdLibraryModule Class
- AviProcessorLibraryModule Class
- Bitmap Class
- Bitmap Members
- Bitmap Constructor
- Bitmap Methods
- {dtor} Method
- Abort Method
- Clear Method
- ClearHistory Method
- ClearRedoHistory Method
- ClearUndoHistory Method
- Clone Method
- Create Method
- Deserialize Method
- Dispose Method
- Draw Method
- Draw Method (Graphics, Int32, Int32, Int32, Int32, Int32, Int32, Int32, Int32, CombineMode, Single, InterpolationMode)
- Draw Method (Graphics, Single, Single, Single, Single, Single, Single, Single, Single, CombineMode, Single, InterpolationMode)
- Draw Method (IntPtr, Int32, Int32, Int32, Int32, Int32, Int32, Int32, Int32, CombineMode, Single, InterpolationMode)
- Draw Method (IntPtr, Single, Single, Single, Single, Single, Single, Single, Single, CombineMode, Single, InterpolationMode)
- Draw Method (Bitmap, Int32, Int32, Int32, Int32, Int32, Int32, Int32, Int32, CombineMode, Single, InterpolationMode)
- Draw Method (Bitmap, Single, Single, Single, Single, Single, Single, Single, Single, CombineMode, Single, InterpolationMode)
- Draw Method (GdiGraphics, Int32, Int32, Int32, Int32, Int32, Int32, Int32, Int32, CombineMode, Single, InterpolationMode)
- Draw Method (GdiGraphics, Single, Single, Single, Single, Single, Single, Single, Single, CombineMode, Single, InterpolationMode)
- Draw Method (Graphics, Int32, Int32, CombineMode)
- Draw Method (IntPtr, Int32, Int32, CombineMode)
- Draw Method (Bitmap, Int32, Int32, CombineMode)
- Draw Method (GdiGraphics, Int32, Int32, CombineMode)
- Draw Method (Graphics, Rectangle, CombineMode, Single, InterpolationMode)
- Draw Method (Graphics, RectangleF, CombineMode, Single, InterpolationMode)
- Draw Method (Graphics, Int32, Int32, CombineMode, Single)
- Draw Method (IntPtr, Rectangle, CombineMode, Single, InterpolationMode)
- Draw Method (IntPtr, RectangleF, CombineMode, Single, InterpolationMode)
- Draw Method (IntPtr, Int32, Int32, CombineMode, Single)
- Draw Method (Bitmap, Rectangle, CombineMode, Single, InterpolationMode)
- Draw Method (Bitmap, RectangleF, CombineMode, Single, InterpolationMode)
- Draw Method (Bitmap, Int32, Int32, CombineMode, Single)
- Draw Method (GdiGraphics, Rectangle, CombineMode, Single, InterpolationMode)
- Draw Method (GdiGraphics, RectangleF, CombineMode, Single, InterpolationMode)
- Draw Method (GdiGraphics, Int32, Int32, CombineMode, Single)
- Draw Method (Graphics, Rectangle, Rectangle, CombineMode, Single, InterpolationMode)
- Draw Method (Graphics, RectangleF, RectangleF, CombineMode, Single, InterpolationMode)
- Draw Method (IntPtr, Rectangle, Rectangle, CombineMode, Single, InterpolationMode)
- Draw Method (IntPtr, RectangleF, RectangleF, CombineMode, Single, InterpolationMode)
- Draw Method (Bitmap, Rectangle, Rectangle, CombineMode, Single, InterpolationMode)
- Draw Method (Bitmap, RectangleF, RectangleF, CombineMode, Single, InterpolationMode)
- Draw Method (GdiGraphics, Rectangle, Rectangle, CombineMode, Single, InterpolationMode)
- Draw Method (GdiGraphics, RectangleF, RectangleF, CombineMode, Single, InterpolationMode)
- Draw Method (Graphics, Int32, Int32, Int32, Int32, CombineMode, Single, InterpolationMode)
- Draw Method (Graphics, Single, Single, Single, Single, CombineMode, Single, InterpolationMode)
- Draw Method (IntPtr, Int32, Int32, Int32, Int32, CombineMode, Single, InterpolationMode)
- Draw Method (IntPtr, Single, Single, Single, Single, CombineMode, Single, InterpolationMode)
- Draw Method (Bitmap, Int32, Int32, Int32, Int32, CombineMode, Single, InterpolationMode)
- Draw Method (Bitmap, Single, Single, Single, Single, CombineMode, Single, InterpolationMode)
- Draw Method (GdiGraphics, Int32, Int32, Int32, Int32, CombineMode, Single, InterpolationMode)
- Draw Method (GdiGraphics, Single, Single, Single, Single, CombineMode, Single, InterpolationMode)
- Export Method
- FromClipboard Method
- FromHdc Method
- GetEmptyMask Method
- GetGdiGraphics Method
- GetGdiplusGraphics Method
- GetObjectData Method
- GetPixel Method
- Implicit Method
- Import Method
- Load Method
- LoadFromClipboard Method
- LoadFromHdc Method
- LoadThumbnail Method
- LockBits Method
- Redo Method
- Save Method
- SaveState Method
- SaveToClipboard Method
- Serialize Method
- SetPixel Method
- ToGdiplusBitmap Method
- ToGdiplusBitmapDirectly Method
- Undo Method
- Unload Method
- UnlockBits Method
- Bitmap Properties
- Bitmap Events
- BitmapChange Enumeration
- BitmapChangedEventArgs Class
- BitmapChangedEventHandler Delegate
- BitmapChangingEventArgs Class
- BitmapChangingEventHandler Delegate
- BitmapData Class
- BitmapEmptyException Class
- BitmapLockedException Class
- BitmapSavingEventArgs Class
- BitmapSavingEventHandler Delegate
- BitmapStatisticsProvider Class
- ChannelsProvider Class
- CMAdobeModuleLoadException Class
- CMException Class
- CMInappropriateProfileException Class
- CMOpenProfileException Class
- CMTransformException Class
- CmykColor Class
- Color Class
- ColorAdjustmentProvider Class
- ColorChannel Enumeration
- ColorManagementProvider Class
- ColorPalette Class
- ColorPaletteEmptyException Class
- ColorPaletteType Enumeration
- ColorProfile Class
- ColorProfileClass Enumeration
- ColorSpace Enumeration
- ErrorEventArgs Class
- Exception Class
- GlobalSettings Class
- GraphicsMillLibraryModule Class
- GrayScaleColor Class
- Histogram Class
- HistogramMode Enumeration
- ILockable Interface
- IPixelFormatSupport Interface
- IStateNavigable Interface
- ISyncEvents Interface
- ISyncHandler Interface
- IUnitConverter Interface
- LibraryModuleAbstract Class
- LockableObject Class
- MediaProcessorLibraryModule Class
- MessageLoopNotPresentedException Class
- ObjectEmptyException Class
- ObjectLockedException Class
- ObjectNotOpenedException Class
- OperationNotCompletedException Class
- PixelFormat Enumeration
- PixelFormatUtils Class
- ProgressEventArgs Class
- ProgressEventHandler Delegate
- Rational Structure
- RgbColor Class
- StateRestoringEventArgs Class
- StateRestoringEventHandler Delegate
- StopEventHandler Delegate
- StreamWrapper Class
- SyncHandler Class
- SynchronizationMode Enumeration
- TimeoutException Class
- TransformsProvider Class
- TrialPeriodTimeException Class
- UnexpectedException Class
- Unit Enumeration
- UnitConverter Class
- UnitConverterHandler Class
- UnitConverterObject Class
- UnsignedRational Structure
- UnsupportedPixelFormatException Class
- Win32Exception Class
- ZipCompressor Class
- Aurigma.GraphicsMill.AjaxControls Namespace
- Aurigma.GraphicsMill.AjaxControls.VectorObjects Namespace
- Aurigma.GraphicsMill.AjaxControls.VectorObjects.Math Namespace
- Aurigma.GraphicsMill.AjaxControls.VectorObjects.RedoUndo Namespace
- Aurigma.GraphicsMill.Codecs Namespace
- Aurigma.GraphicsMill.Drawing Namespace
- Aurigma.GraphicsMill.Licensing Namespace
- Aurigma.GraphicsMill.Transforms Namespace
- Aurigma.GraphicsMill.WebControls Namespace
- Aurigma.GraphicsMill.WinControls Namespace
- GraphicsMill Namespace (Client Class Library)
- Aurigma.GraphicsMill.AjaxControls Namespace (Client Class Library)
- Aurigma.GraphicsMill.AjaxControls.VectorObjects Namespace (Client Class Library)
- Aurigma.GraphicsMill.AjaxControls.VectorObjects.Math Namespace (Client Class Library)
- Aurigma.GraphicsMill.AjaxControls.VectorObjects.RedoUndo Namespace (Client Class Library)
- Aurigma.GraphicsMill Namespace
- Samples
- Licensing
- Copyright Notices
Bitmap.Draw Method (Graphics, Rectangle, CombineMode, Single, InterpolationMode)
Draws current bitmap on given System.Drawing.Graphics object (standard .NET class for drawing).
Namespace:
Aurigma.GraphicsMill
Assembly:
Aurigma.GraphicsMill (in Aurigma.GraphicsMill.dll)
Syntax
Public Sub Draw ( _
destinationGraphics As Graphics, _
destinationRectangle As Rectangle, _
combine As CombineMode, _
opacity As Single, _
interpolationMode As InterpolationMode _
)
public void Draw(
Graphics destinationGraphics,
Rectangle destinationRectangle,
CombineMode combine,
float opacity,
InterpolationMode interpolationMode
)
Parameters
- destinationGraphics
-
Type: System.Drawing.Graphics
Target System.Drawing.Graphics object (on which current bitmap should be drawn).
- destinationRectangle
-
Type: System.Drawing.Rectangle
Destination rectangle (see Remarks section).
- combine
- Algorithm of images blending (plain pixels copying, alpha blending, bitwise operations, etc).
- opacity
-
Type: System.Single
A number in range [0, 1] specifying total opacity of the image. If 0, image is completely transparent, if 1, image is completely opaque.
- interpolationMode
- Algorithm of resizing. Using this parameter you can select between speed and quality of resizing.
Remarks
Bitmap is drawn to destination rectangle on the given System.Drawing.Graphics object. If current bitmap dimensions differ from dimensions of destination rectangle, it is resized to have the same size as destination rectangle.
If bitmap has pixel format which is not GDI-compatible (e.g. extended pixel formats, CMYK, etc) method will automatically create a copy converted to the Format32bppArgb. That's why you always get it drawn, but if you are going to call this method multiple times, it is recommended to convert it to some GDI-compatible format (like Format32bppArgb) to increase the performance.
If you want method to calculate width and height automatically, you can pass 0 to these arguments. It will be calculated with the following way:
- If both width and heigth are 0, it will take source image dimensions (Width and Height properties). This way no resize will be done during drawing.
- If only one of arguments is 0, it will calculate this argument to save proportion. For example, source image is 800x600, and you pass 400 as width and 0 as height. Height will be calculated to preserve aspect ratio of the image, i.e. it will be equal to 300.
All coordinates are measured in units specified with Unit property of the source bitmap.