/SEEDS-superpixels

OpenCV wrapper around original SEEDS superpixels implementation

Primary LanguageC++MIT LicenseMIT

SEEDS Superpixels Wrapper for OpenCV

This is a simple OpenCV wrapper for original SEEDS superpixels implementation. It uses the version 1.1 from author's website.

Example

#include "seeds_opencv.h"

int main()
{
    cv::Mat image = cv::imread("star.png", cv::IMREAD_COLOR);

    cv::Mat labels;
    int count;
    seeds(image, 2, 2, 4, labels, count);

    cv::Mat contour;
    labelContourMask(labels, contour, false);

    image.setTo(cv::Scalar(255, 255, 255), contour);

    cv::imwrite("star_labels.png", image);

    return 0;
}

Star Star Labels

License

Wrapper is MIT license. Please refer to author's website for the license of original SEEDS superpixels implementation.