Find the best boundary/cut/split between two points on an image

Version 1.1 (11.7 KB) by sagi eppel
Find the best boundary/cut/split that pass between two points on the grayscale image.
242 Downloads
Updated 23 Jan 2015

View License

Find the best boundary/cut/split that pass between points (Ax,Ay) and (Bx,By) on the grayscale image Is.

Input:
Is: Grayscale image of the vessel containing the material.
Ax,Ay: coordinates of the start pixel in which the split/path starts
Bx,By: coordinates of the end pixel in which the split/path ends

Note that the A and B must not be on the outer boundary of the image(A,B must be surrounded by pixels)

Output
MarkedImage: The input image Is with the best path between pixels A and B marked on the image (also displayed on screen)
BstPathAB: binary image with the path between the start and end points.
Notes
Scanning method based on the Dijkstra's algorithm.
Note that the resulting path cannot include loops (only propagation from left to right or vertical propagation of path is allowed).

Cite As

sagi eppel (2024). Find the best boundary/cut/split between two points on an image (https://www.mathworks.com/matlabcentral/fileexchange/49132-find-the-best-boundary-cut-split-between-two-points-on-an-image), MATLAB Central File Exchange. Retrieved .

MATLAB Release Compatibility
Created with R2012b
Compatible with any release
Platform Compatibility
Windows macOS Linux

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!
Version Published Release Notes
1.1

cover image

1.0.0.0