Draw Line Segments (anti aliased)
computes the distance from a given line segment (in 2d) or draws an anti aliased line
see http://mathworld.wolfram.com/Point-LineDistance2-Dimensional.html for computation of the orthogonal distance to the line.
Where appropriate, gets the orthogonal distance to the line, or one of the two end points.
Can be used to make anti aliased line segment(s) drawings / masks (see lineMask.m)
Can also be used to compute the distance from multiple line segments by taking the minimum of the distances to each line segment.
Version 0.1: Nov 23, 2009
Cite As
Alvin (2024). Draw Line Segments (anti aliased) (https://www.mathworks.com/matlabcentral/fileexchange/25937-draw-line-segments-anti-aliased), MATLAB Central File Exchange. Retrieved .
MATLAB Release Compatibility
Platform Compatibility
Windows macOS LinuxCategories
- Image Processing and Computer Vision > Image Processing Toolbox > Image Segmentation and Analysis > Image Segmentation >
Tags
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!Discover Live Editor
Create scripts with code, output, and formatted text in a single executable document.