symcode 0.1.0

Symbolic Barcode - Programming Library
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
use visioncortex::{BinaryImage, BoundingRect, ColorImage, Shape};

/// To detect finder elements from a color image
pub trait Finder {
	/// If succeed, return an array of finder positions
    fn find(&self, input: &ColorImage) -> Result<Vec<BoundingRect>, &'static str>;
}

/// Definition of a finder element
pub trait FinderElement {

	fn to_image(&self, width: usize, height: usize) -> BinaryImage; // to be used by SymcodeGenerator

	fn is_finder(&self, shape: Shape) -> bool; // to be used by SymcodeScanner
}