dcv.features.rht

Module introduces Randomized Hough Transform implementation.

Members

Mixin templates

BaseRht
mixintemplate BaseRht()

A template that bootstraps a full Randomized Hough transform implementation. The basic primitives required are as follows.

Structs

RhtCircles
struct RhtCircles
Undocumented in source.
RhtEllipses
struct RhtEllipses
Undocumented in source.
RhtLines
struct RhtLines

Randomized Hough Transform for lines

Examples

// Load an image from filesystem.
Image image = imread("/path/to/image.png");

// Calculate edges by use of canny algorithm
auto edges = image
                .sliced
                .rgb2gray
                .as!float
                .slice
                .conv(gaussian!float(1.0f, 3, 3))
                .canny!ubyte(100);

// Setup RHT line extraction context
auto lines = RhtLines().epouchs(50).iterations(250).minCurve(25);

// Lazily iterate and detect lines in pre-processed image
foreach(line; lines(edges)) {
    // do stuff with lines..
}

For more elaborated module description visit the RHT example.

Meta

Authors

Dmitry Olshansky

License

$(LINK3 http://www.boost.org/LICENSE_1_0.txt, Boost Software License - Version 1.0).