Categories

Image Edge Detection

Apply professional edge detection algorithms (Sobel, Prewitt, Laplacian, Canny) with adjustable thresholds and visualization options

Click to upload file or drag and drop file here

Maximum file size: 20MB Supported formats: image/jpeg, image/png, image/tiff, image/webp, image/bmp

Upload image for edge detection

Threshold for edge detection (0-255)

High threshold for Canny detector (0-255)

Kernel aperture size (odd number, 3-15)

Color for detected edges (hex or R,G,B)

Display original image alongside edge detection results

Output quality for lossy formats

Key Facts

Category
Design
Input Types
file, select, number, color, checkbox
Output Type
file
Sample Coverage
4
API Ready
Yes

Overview

Extract and visualize structural boundaries from your images using professional-grade algorithms like Canny, Sobel, and Laplacian. This tool allows you to isolate contours and gradients with precise control over thresholds and output styles for design, computer vision, or artistic projects.

When to Use

  • Isolating object outlines for graphic design or vector tracing preparation.
  • Preprocessing images for machine learning models that require feature extraction.
  • Analyzing structural patterns or surface textures in technical or scientific photography.

How It Works

  • Upload your image file in PNG, JPEG, TIFF, WebP, or BMP format.
  • Select your preferred detection algorithm, such as Canny for high-precision edges or Sobel for gradient analysis.
  • Adjust the threshold values and aperture size to fine-tune the sensitivity of the edge detection.
  • Choose your output mode and format, then process the image to generate the final result.

Use Cases

Preparing image masks for background removal or object segmentation.
Creating stylized artistic effects by highlighting the structural skeleton of a photograph.
Extracting geometric features from technical diagrams or blueprints for further analysis.

Examples

1. Isolating Product Contours

Graphic Designer
Background
A designer needs to extract the clean outline of a product from a studio photo to create a vector-based marketing asset.
Problem
Manual tracing is time-consuming and prone to human error.
How to Use
Upload the product photo, select the 'Canny Edge Detector' method, and adjust the thresholds until only the primary product silhouette remains.
Example Config
method: canny, threshold: 50, threshold2: 150, outputMode: edges-only
Outcome
A high-contrast, black-and-white outline of the product, ready for import into vector software.

2. Surface Texture Analysis

Materials Researcher
Background
A researcher is analyzing the surface cracks on a metal sample to determine structural integrity.
Problem
Fine cracks are difficult to see in the original high-resolution image.
How to Use
Upload the microscopic image, apply the 'Laplacian Operator' to enhance fine detail, and set the output mode to 'Magnitude & Thickness'.
Example Config
method: laplacian, apertureSize: 3, outputMode: magnitude-thickness
Outcome
A clear visualization of surface fractures, highlighting the depth and path of the cracks.

Try with Samples

image, png, jpg

Related Hubs

FAQ

Which algorithm should I choose?

Canny is best for clean, distinct object edges, while Sobel and Prewitt are better for analyzing gradient intensity. Laplacian is ideal for detecting fine details and noise.

What does the aperture size do?

The aperture size determines the size of the kernel used for the derivative calculation. Larger values capture broader edges, while smaller values are more sensitive to fine details.

Can I see the original image next to the result?

Yes, enable the 'Show Original Comparison' checkbox to view the source image alongside the processed edge output.

What is the difference between Edge Threshold and Canny High Threshold?

The Edge Threshold sets the base sensitivity for standard operators, while the Canny High Threshold specifically controls the upper bound for the Canny detector's hysteresis process.

Can I change the color of the detected edges?

Yes, you can use the 'Edge Color' picker to customize the color of the extracted contours in your output image.

API Documentation

Request Endpoint

POST /en/api/tools/image-edge-detect

Request Parameters

Parameter Name Type Required Description
imageFile file (Upload required) Yes Upload image for edge detection
detectionMethod select No -
threshold number No Threshold for edge detection (0-255)
threshold2 number No High threshold for Canny detector (0-255)
apertureSize number No Kernel aperture size (odd number, 3-15)
outputMode select No -
edgeColor color No Color for detected edges (hex or R,G,B)
showOriginal checkbox No Display original image alongside edge detection results
format select No -
quality number No Output quality for lossy formats

File type parameters need to be uploaded first via POST /upload/image-edge-detect to get filePath, then pass filePath to the corresponding file field.

Response Format

{
  "filePath": "/public/processing/randomid.ext",
  "fileName": "output.ext",
  "contentType": "application/octet-stream",
  "size": 1024,
  "metadata": {
    "key": "value"
  },
  "error": "Error message (optional)",
  "message": "Notification message (optional)"
}
File: File

AI MCP Documentation

Add this tool to your MCP server configuration:

{
  "mcpServers": {
    "elysiatools-image-edge-detect": {
      "name": "image-edge-detect",
      "description": "Apply professional edge detection algorithms (Sobel, Prewitt, Laplacian, Canny) with adjustable thresholds and visualization options",
      "baseUrl": "https://elysiatools.com/mcp/sse?toolId=image-edge-detect",
      "command": "",
      "args": [],
      "env": {},
      "isActive": true,
      "type": "sse"
    }
  }
}

You can chain multiple tools, e.g.: `https://elysiatools.com/mcp/sse?toolId=png-to-webp,jpg-to-webp,gif-to-webp`, max 20 tools.

Supports URL file links or Base64 encoding for file parameters.

If you encounter any issues, please contact us at [email protected]