Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

2D spline algorithm in OpenCV

Does OpenCV have a method for generating a 2D 'spline' contour? IOW, choose gray-scale pixel values at selected points on a 2D map and have them connected by a smoothed 2-dimensional contour. Output would presumably be gray-scale values in Mat form.

The inputs to a regular spline are a set of point coordinates, and output is a continuous curve that connects the input points.

In this case, the input would be a set of point coordinates -each with a gray-scale value-. The output would be a smoothed gray-scale contour that covers the entire square Mat.

That was tougher to explain than I expected. Hope it was clear. Perhaps that would actually be a 3D spline in that gray-scale value would be the 3rd dimension. But this is for generating a 2D image.