Track input and output devices / peripherals (mice, microphones, keyboards etc) as entities with components
- Dominant language
- Rust
- Stars
- 48.2k
- Forks
- 4.8k
- Avg merge
- 3d 16h
- Merged PRs (30d)
- 171
Description
## What problem does this solve or what need does it fill?
Currently there are no ways to modify input/output device settings (outside of gamepads), or read data about them.
## What solution would you like?
Introduce more components related to input devices (Keyboards, Mouse, Microphones, Headphones, etc)
Some ideas I can think of off the top of my head would be
```rust
DeviceName
CursorGrabMode // Already exists on window, not sure how to resolve the conflict.
Visibility // Already exists on window, not sure how to resolve the conflict.
// Headphones and microphones
Sound
AudioChannels
// Used to select the device that is used with Res, individual devices can still be queried manually. If no device is specified, combine input.
// Could optionally be made a resource for each device depending on implementation details.
MainDevice
```
This also gives the added benefit of being able to disable certain devices (such as mouse and microphone input during a cutscene) using the disabling api.
## What alternative(s) have you considered?
Continue as usual.
Contributor guide
Research direction
Start by reviewing the existing window and gamepad input APIs referenced in the issue, along with the proposed DeviceName, CursorGrabMode, Visibility, Sound, AudioChannels, and MainDevice concepts. Done would require an agreed design for device entities and components, including how device selection, combined input, and disabling behavior should work.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- game-dev
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100