This function was originally designed as a replacement for the Mapping Toolbox function bufferm, which calculates a buffer zone around a polygon. The original bufferm function had some serious bugs that could result in incorrect buffer results and/or errors, and was also very slow. As of R2006b, those bugs have been fixed in bufferm.m. However, this version still maintains a few advantages over the original:
- Can be applied to polygons in either geographical space (as in bufferm) or in cartesian coordinates.
- Better treatment of polygon holes. The original function simply filled in all holes; this version trims or pads holes according to the buffer width given.
Input and output format is identical to bufferm unless the 'xy' cartesian-coordinate option is specified, so it can be used interchangeably.