System object: vision.BoundaryTracer
Trace object boundary in binary image
PTS = step(H,BW,STARTPT)
PTS = step(H,BW,STARTPT) traces the boundary of an object in a binary image BW. The second input matrix, STARTPT, specified the starting point for tracing the boundary. STARTPT is a two-element vector of [x y] coordinates of the initial point on the object boundary. The step method outputs PTS, an M-by-2 matrix of [x y] coordinates of the boundary points, where M is the number of traced boundary pixels. M is less than or equal to the value specified by the MaximumPixelCount property.
Note: H specifies the System object™ on which to run this step method.
The object performs an initialization the first time the step method is executed. This initialization locks nontunable properties and input specifications, such as dimensions, complexity, and data type of the input data. If you change a nontunable property or an input specification, the System object issues an error. To change nontunable properties or inputs, you must first call the release method to unlock the object.