Struct gilrs::GilrsBuilder[][src]

pub struct GilrsBuilder { /* fields omitted */ }

Allow to create Gilrs with customized behaviour.

Methods

impl GilrsBuilder
[src]

Create builder with default settings. Use build() to create Gilrs.

If true, use axis_dpad_to_button, Jitter and deadzone filters with default parameters. Defaults to true.

Adds SDL mappings.

If true, will add SDL mappings from SDL_GAMECONTROLLERCONFIG environment variable. Defaults to true.

If true, will add SDL mappings included from https://github.com/gabomdq/SDL_GameControllerDB. Defaults to true.

Sets values on which ButtonPressed and ButtonReleased events will be emitted. build() will return error if pressed ≤ released or if one of values is outside [0.0, 1.0].

Defaults to 0.75 for pressed and 0.65 for released.

Disable or enable automatic state updates. You should use this if you use custom filters; in this case you have to update state manually anyway.

Creates Gilrs.

Auto Trait Implementations