One the measurements provided by regionprops is 'Centroid'. Here's an example of labeling binary objects, computing the centroid of each object, and plotting the centroid location on top... 更多内容 >>
Note
Steve on Image Processing with MATLAB has been archived and will not be updated.
One the measurements provided by regionprops is 'Centroid'. Here's an example of labeling binary objects, computing the centroid of each object, and plotting the centroid location on top... 更多内容 >>
The functions bwlabel and regionprops are very useful for measuring the properties of shapes in a binary image. There are documentation examples and product demos showing how to do this,... 更多内容 >>
Didja know? You can fill holes, or pits, in grayscale images by using the Image Processing Toolbox function imfill. The other day I was rereading the Tarboton paper on upslope area,... 更多内容 >>
[NOTE: After I originally wrote this post about handling plateaus, I discovered problems with the method, so I am no longer using it. I revisited the plateau issue in a later post. -SE] ... 更多内容 >>
Last week I wrote about a possible modification to poly2mask that would estimate how much of each pixel is contained within a polygon. The idea was to use a regular 5-by-5 subgrid and ... 更多内容 >>
Several people have asked me recently how to plot some kind of shape on top of an image, so I thought I'd show the basic technique here. Essentially, you display the image, then call hold on,... 更多内容 >>
This is the final post in a series discussing the algorithm underlying Image Processing Toolbox functions poly2mask and roipoly. (See Part 1 and Part 2.) There are several desirable... 更多内容 >>
I'm familiar with two basic ways to determine whether a point is inside a polygon. The first is to compute the winding number, which is the number of times that a closed curve encircles the... 更多内容 >>
This is the first of several blogs about the algorithm behind poly2mask and roipoly. poly2mask takes a set of polygon vertices and produces a binary mask image. The binary mask has 1s for... 更多内容 >>
Reader JP asked me about my recent blog post on the Hough transform. Specifically, she wanted to know exactly how the rho-theta coordinate system was defined. When I answered her question, ... 更多内容 >>