Ejemplo n.º 1
0
ConvexHullFilter::ConvexHullFilter()
{
    setName("ConvexHullFilter");
    setDesc("Calculates the convex hull of contour");
    setGroup("user");
	
    mIn.setName("input");
    mIn.setDesc("A list of outer contours or a single one");
	addInputListPort(mIn);
	
    mOut.setName("convexHull");
    mOut.setDesc("The convex hulls in the same order as the inputs");
    addOutputListPort(mOut);
}
Ejemplo n.º 2
0
MomentFilter::MomentFilter()
{
    setName("Moments");
    setDesc(QObject::tr("Calculates the moments of a contour."));
    setGroup("image/contour");
    mIn.setName("input");
    mNumPixelsOut.setName("numPixels");
    mNumPixelsOut.setDesc(QObject::tr("The number of pixels inside a contour(m00)"));
    mCogOut.setName("cog");
    mCogOut.setDesc(QObject::tr("The center of gravity (based on m01, m10 and m00"));
    addInputListPort(mIn);
    addOutputListPort(mNumPixelsOut);
    addOutputListPort(mCogOut);
}
Ejemplo n.º 3
0
ConvexHull::ConvexHull()
{
    setName("ConvexHull");
    setDesc(QObject::tr("Calculates the convex hull of contour"));
    setGroup("image/contour");

    mIn.setName("imageIn");
    mIn.setDesc(QObject::tr("Image input"));
    addInputListPort(mIn);

    mOut.setName("convexHull");
    mOut.setDesc(QObject::tr("Convex hull of input image"));
    addOutputListPort(mOut);
}
Ejemplo n.º 4
0
ContourWriter::ContourWriter()
{
    setName("ContourWriter");
    setDesc(QObject::tr("Writes a extracted contour to disc"));
    setGroup("image/contour");
    mFile.setName("fileName");
    mOffsetIn.setName("offset");
    mOffsetIn.setDesc(QObject::tr("Offset that will be added to all calculated positions"));
    mOffsetIn.setDefault(QPointF(0.0, 0.0));
    mContour.setName("contour");
    mContour.setDesc(QObject::tr("A list of the calculated outer contours"));
    addInputPort(mFile);
    addInputPort(mOffsetIn);
    addInputListPort(mContour);
}