1. An extracting method of a pattern contour, comprising: acquiring an image of a pattern to be inspected; calculating a schematic edge position of the pattern from the image; preparing an approximate polygon by approximating a polygon consisting of edges having predetermined direction components to a contour shape of the pattern on the basis of the calculated edge position; dividing the approximate polygon into star-shaped polygons; calculating the position of a kernel of the star-shaped polygon; and searching an edge of the pattern in a direction connecting the kernel to an arbitrary point positioned on the edge of the approximate polygon.