object_line_int( a, b, mask, dist_trld )
This function finds the intersection between a line between points a and b and the boundary of an object in a binary mask. Point a must be inside the object. Point b can be anywhere in the image. The function always returns an intersection point by extending the line beyond point b if necessary.
The points a, b and int are given as [x,y] coordinates. Mask is a binary image containing the object of interest.
Cite As
Violet (2024). object_line_int( a, b, mask, dist_trld ) (https://www.mathworks.com/matlabcentral/fileexchange/52239-object_line_int-a-b-mask-dist_trld), 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 > Region and Image Properties >
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.
object_line_int/
Version | Published | Release Notes | |
---|---|---|---|
1.42.0.0 | Upload example file |
||
1.41.0.0 | Add an example on how to run the function. |
||
1.4.0.0 | Enable multiple intersection points to be discovered as long as they are further apart that a given threshold. |
||
1.3.0.0 | Optimize computation of distances and fix issue with output |
||
1.2.0.0 | Fixed issues with some |
||
1.1.0.0 | Minor changes to avoid issues when points lie on a vertical line. |
||
1.0.0.0 |