dcv.features.rht

Module introduces Randomized Hough Transform implementation.

Members

Mixin templates

BaseRht
mixin template BaseRht()

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

Structs

RhtLines
struct RhtLines

Randomized Hough Transform for lines

Examples

1 
2 // Load an image from filesystem.
3 Image image = imread("/path/to/image.png");
4 
5 // Calculate edges by use of canny algorithm
6 auto edges = image
7                 .sliced
8                 .rgb2gray
9                 .as!float
10                 .slice
11                 .conv(gaussian!float(1.0f, 3, 3))
12                 .canny!ubyte(100);
13 
14 // Setup RHT line extraction context
15 auto lines = RhtLines().epouchs(50).iterations(250).minCurve(25);
16 
17 // Lazily iterate and detect lines in pre-processed image
18 foreach(line; lines(edges)) {
19     // do stuff with lines..
20 }

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).