pub struct Options {
    pub size: (u32, u32),
    pub max_distance: u16,
    pub image_treshold: u8,
}
Expand description

The options passed as the argument to the distance_field method.

Fields

size: (u32, u32)

The dimensions of the output image (width, height). The default value is: (64,64).

max_distance: u16

The maximum distance for the projected point of the output image on the input image to search for the nearest point. The defaul value is: 512.

image_treshold: u8

The image value at which to apply the treshold. In a black-white vector image 127 is probably the best value. The default value is: 127.

Trait Implementations

Returns:

    size: (64, 64),
    max_distance: 512,
    image_treshold: 127
}```

Returns the “default value” for a type. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The alignment of pointer.

The type for initializers.

Initializes a with the given initializer. Read more

Dereferences the given pointer. Read more

Mutably dereferences the given pointer. Read more

Drops the object pointed to by the given pointer. Read more

Read this value from the supplied reader. Same as ReadEndian::read_from_little_endian().

Read this value from the supplied reader. Same as ReadEndian::read_from_big_endian().

Read this value from the supplied reader. Same as ReadEndian::read_from_native_endian().

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.