input_helper

Crates.ioinput_helper
lib.rsinput_helper
version0.1.2
sourcesrc
created_at2022-05-08 00:27:16.220706
updated_at2022-05-10 14:02:17.469372
descriptionGeneric types and tools for unifying input libraries.
homepagehttps://github.com/AlexiWolf/input_helper
repositoryhttps://github.com/AlexiWolf/input_helper
max_upload_size
id582311
size28,643
Lexi (AlexiWolf)

documentation

README

Input Helper

Generic types and tools for unifying input libraries.

The main job of Input Helper is to provide a single, unified way to process input from any input framework.

Project Status

NOTE: Input Helper is still in the planning / testing stages. It is not ready for use at the moment.

The Problem

Most libraries that take user input do so in a library-specific way. In order to use the library, you must write library-specific code.

For example: You can't switch from Winit to SDL, or Gilrs to SDL, or any other library without having to rewrite all your input code. This can either couple your project to specific framework(s), or force you to waste time duplicating code. In the case of using multiple input libraries, such as pairing Winit and Gilrs you must handle each framework separately.

The Solution

Library-specific input events can be converted to InputEvents, and sent through Input Helper using InputHelper::send(). Then your application code can be written against Input Helper. If you ever need to switch your input system, then there's no need to rewrite your business logic. This also allows you to process all input code in a single place regardless of its source.

Input Helper will provide default integration functions for common frameworks such as Winit, SDL, and Gilrs.

Contribution

License

Input Helper is licensed under either

at your option.

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without additional terms or conditions.

Commit count: 25

cargo fmt