AForge.Imaging.Filters.BaseInPlacePartialFilter.ApplyInPlace C# (CSharp) Метод

ApplyInPlace() публичный Метод

Apply filter to an image or its part.
The method applies the filter directly to the provided source image.
Unsupported pixel format of the source image.
public ApplyInPlace ( Bitmap image, Rectangle rect ) : void
image System.Drawing.Bitmap Image to apply filter to.
rect System.Drawing.Rectangle Image rectangle for processing by the filter.
Результат void
        public void ApplyInPlace( Bitmap image, Rectangle rect )
        {
            // lock source bitmap data
            BitmapData data = image.LockBits(
                new Rectangle( 0, 0, image.Width, image.Height ),
                ImageLockMode.ReadWrite, image.PixelFormat );

            try
            {
                // apply the filter
                ApplyInPlace( new UnmanagedImage( data ), rect );
            }
            finally
            {
                // unlock image
                image.UnlockBits( data );
            }
        }

Same methods

BaseInPlacePartialFilter::ApplyInPlace ( Bitmap image ) : void
BaseInPlacePartialFilter::ApplyInPlace ( BitmapData imageData ) : void
BaseInPlacePartialFilter::ApplyInPlace ( BitmapData imageData, Rectangle rect ) : void
BaseInPlacePartialFilter::ApplyInPlace ( UnmanagedImage image ) : void
BaseInPlacePartialFilter::ApplyInPlace ( UnmanagedImage image, Rectangle rect ) : void