Class DetectEdgesExtensions
Defines edge detection extensions applicable on an Image using Mutate/Clone.
Inherited Members
Namespace: SixLabors.ImageSharp.Processing
Assembly: SixLabors.ImageSharp.dll
Syntax
public static class DetectEdgesExtensions
Methods
| Improve this Doc View SourceDetectEdges(IImageProcessingContext)
Detects any edges within the image. Uses the Sobel kernel operating in grayscale mode.
Declaration
public static IImageProcessingContext DetectEdges(this IImageProcessingContext source)
Parameters
Type | Name | Description |
---|---|---|
IImageProcessingContext | source | The image this method extends. |
Returns
Type | Description |
---|---|
IImageProcessingContext | The IImageProcessingContext to allow chaining of operations. |
DetectEdges(IImageProcessingContext, EdgeDetector2DKernel)
Detects any edges within the image operating in grayscale mode.
Declaration
public static IImageProcessingContext DetectEdges(this IImageProcessingContext source, EdgeDetector2DKernel kernel)
Parameters
Type | Name | Description |
---|---|---|
IImageProcessingContext | source | The image this method extends. |
EdgeDetector2DKernel | kernel | The 2D edge detector kernel. |
Returns
Type | Description |
---|---|
IImageProcessingContext | The IImageProcessingContext to allow chaining of operations. |
DetectEdges(IImageProcessingContext, EdgeDetector2DKernel, Rectangle)
Detects any edges within the image operating in grayscale mode.
Declaration
public static IImageProcessingContext DetectEdges(this IImageProcessingContext source, EdgeDetector2DKernel kernel, Rectangle rectangle)
Parameters
Type | Name | Description |
---|---|---|
IImageProcessingContext | source | The image this method extends. |
EdgeDetector2DKernel | kernel | The 2D edge detector kernel. |
Rectangle | rectangle | The Rectangle structure that specifies the portion of the image object to alter. |
Returns
Type | Description |
---|---|
IImageProcessingContext | The IImageProcessingContext to allow chaining of operations. |
DetectEdges(IImageProcessingContext, EdgeDetector2DKernel, Boolean)
Detects any edges within the image using a EdgeDetector2DKernel.
Declaration
public static IImageProcessingContext DetectEdges(this IImageProcessingContext source, EdgeDetector2DKernel kernel, bool grayscale)
Parameters
Type | Name | Description |
---|---|---|
IImageProcessingContext | source | The image this method extends. |
EdgeDetector2DKernel | kernel | The 2D edge detector kernel. |
Boolean | grayscale | Whether to convert the image to grayscale before performing edge detection. |
Returns
Type | Description |
---|---|
IImageProcessingContext | The IImageProcessingContext to allow chaining of operations. |
DetectEdges(IImageProcessingContext, EdgeDetector2DKernel, Boolean, Rectangle)
Detects any edges within the image using a EdgeDetector2DKernel.
Declaration
public static IImageProcessingContext DetectEdges(this IImageProcessingContext source, EdgeDetector2DKernel kernel, bool grayscale, Rectangle rectangle)
Parameters
Type | Name | Description |
---|---|---|
IImageProcessingContext | source | The image this method extends. |
EdgeDetector2DKernel | kernel | The 2D edge detector kernel. |
Boolean | grayscale | Whether to convert the image to grayscale before performing edge detection. |
Rectangle | rectangle | The Rectangle structure that specifies the portion of the image object to alter. |
Returns
Type | Description |
---|---|
IImageProcessingContext | The IImageProcessingContext to allow chaining of operations. |
DetectEdges(IImageProcessingContext, EdgeDetectorCompassKernel)
Detects any edges within the image operating in grayscale mode.
Declaration
public static IImageProcessingContext DetectEdges(this IImageProcessingContext source, EdgeDetectorCompassKernel kernel)
Parameters
Type | Name | Description |
---|---|---|
IImageProcessingContext | source | The image this method extends. |
EdgeDetectorCompassKernel | kernel | Thecompass edge detector kernel. |
Returns
Type | Description |
---|---|
IImageProcessingContext | The IImageProcessingContext to allow chaining of operations. |
DetectEdges(IImageProcessingContext, EdgeDetectorCompassKernel, Rectangle)
Detects any edges within the image operating in grayscale mode.
Declaration
public static IImageProcessingContext DetectEdges(this IImageProcessingContext source, EdgeDetectorCompassKernel kernel, Rectangle rectangle)
Parameters
Type | Name | Description |
---|---|---|
IImageProcessingContext | source | The image this method extends. |
EdgeDetectorCompassKernel | kernel | Thecompass edge detector kernel. |
Rectangle | rectangle | The Rectangle structure that specifies the portion of the image object to alter. |
Returns
Type | Description |
---|---|
IImageProcessingContext | The IImageProcessingContext to allow chaining of operations. |
DetectEdges(IImageProcessingContext, EdgeDetectorCompassKernel, Boolean)
Detects any edges within the image using a EdgeDetectorCompassKernel.
Declaration
public static IImageProcessingContext DetectEdges(this IImageProcessingContext source, EdgeDetectorCompassKernel kernel, bool grayscale)
Parameters
Type | Name | Description |
---|---|---|
IImageProcessingContext | source | The image this method extends. |
EdgeDetectorCompassKernel | kernel | Thecompass edge detector kernel. |
Boolean | grayscale | Whether to convert the image to grayscale before performing edge detection. |
Returns
Type | Description |
---|---|
IImageProcessingContext | The IImageProcessingContext to allow chaining of operations. |
DetectEdges(IImageProcessingContext, EdgeDetectorCompassKernel, Boolean, Rectangle)
Detects any edges within the image using a EdgeDetectorCompassKernel.
Declaration
public static IImageProcessingContext DetectEdges(this IImageProcessingContext source, EdgeDetectorCompassKernel kernel, bool grayscale, Rectangle rectangle)
Parameters
Type | Name | Description |
---|---|---|
IImageProcessingContext | source | The image this method extends. |
EdgeDetectorCompassKernel | kernel | Thecompass edge detector kernel. |
Boolean | grayscale | Whether to convert the image to grayscale before performing edge detection. |
Rectangle | rectangle | The Rectangle structure that specifies the portion of the image object to alter. |
Returns
Type | Description |
---|---|
IImageProcessingContext | The IImageProcessingContext to allow chaining of operations. |
DetectEdges(IImageProcessingContext, EdgeDetectorKernel)
Detects any edges within the image operating in grayscale mode.
Declaration
public static IImageProcessingContext DetectEdges(this IImageProcessingContext source, EdgeDetectorKernel kernel)
Parameters
Type | Name | Description |
---|---|---|
IImageProcessingContext | source | The image this method extends. |
EdgeDetectorKernel | kernel | The edge detector kernel. |
Returns
Type | Description |
---|---|
IImageProcessingContext | The IImageProcessingContext to allow chaining of operations. |
DetectEdges(IImageProcessingContext, EdgeDetectorKernel, Rectangle)
Detects any edges within the image operating in grayscale mode.
Declaration
public static IImageProcessingContext DetectEdges(this IImageProcessingContext source, EdgeDetectorKernel kernel, Rectangle rectangle)
Parameters
Type | Name | Description |
---|---|---|
IImageProcessingContext | source | The image this method extends. |
EdgeDetectorKernel | kernel | The edge detector kernel. |
Rectangle | rectangle | The Rectangle structure that specifies the portion of the image object to alter. |
Returns
Type | Description |
---|---|
IImageProcessingContext | The IImageProcessingContext to allow chaining of operations. |
DetectEdges(IImageProcessingContext, EdgeDetectorKernel, Boolean)
Detects any edges within the image using a EdgeDetectorKernel.
Declaration
public static IImageProcessingContext DetectEdges(this IImageProcessingContext source, EdgeDetectorKernel kernel, bool grayscale)
Parameters
Type | Name | Description |
---|---|---|
IImageProcessingContext | source | The image this method extends. |
EdgeDetectorKernel | kernel | The edge detector kernel. |
Boolean | grayscale | Whether to convert the image to grayscale before performing edge detection. |
Returns
Type | Description |
---|---|
IImageProcessingContext | The IImageProcessingContext to allow chaining of operations. |
DetectEdges(IImageProcessingContext, EdgeDetectorKernel, Boolean, Rectangle)
Detects any edges within the image using a EdgeDetectorKernel.
Declaration
public static IImageProcessingContext DetectEdges(this IImageProcessingContext source, EdgeDetectorKernel kernel, bool grayscale, Rectangle rectangle)
Parameters
Type | Name | Description |
---|---|---|
IImageProcessingContext | source | The image this method extends. |
EdgeDetectorKernel | kernel | The edge detector kernel. |
Boolean | grayscale | Whether to convert the image to grayscale before performing edge detection. |
Rectangle | rectangle | The Rectangle structure that specifies the portion of the image object to alter. |
Returns
Type | Description |
---|---|
IImageProcessingContext | The IImageProcessingContext to allow chaining of operations. |
DetectEdges(IImageProcessingContext, Rectangle)
Detects any edges within the image. Uses the Sobel kernel operating in grayscale mode.
Declaration
public static IImageProcessingContext DetectEdges(this IImageProcessingContext source, Rectangle rectangle)
Parameters
Type | Name | Description |
---|---|---|
IImageProcessingContext | source | The image this method extends. |
Rectangle | rectangle | The Rectangle structure that specifies the portion of the image object to alter. |
Returns
Type | Description |
---|---|
IImageProcessingContext | The IImageProcessingContext to allow chaining of operations. |