Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

We should create an interface for Axis #19

Open
olefasting opened this issue Feb 1, 2022 · 3 comments
Open

We should create an interface for Axis #19

olefasting opened this issue Feb 1, 2022 · 3 comments
Assignees
Labels
enhancement New feature or request

Comments

@olefasting
Copy link
Member

I am doing some testing with WASM and I noticed that the Axis type, used as argument to [..]::digital_value varies from backend to backend.

We should probably create a common enum type that can be used in our API and, if needed, be converted to the appropriate type by the individual backends, in stead of using generics.

@potatotech
Copy link
Collaborator

potatotech commented Feb 2, 2022

The buttons vary between backends as well. Unfortunately, not every input in one backend has an equivalent in the other, so if I created enums for the inputs they have in common, some inputs would be unavailable. However, I can add the common set as a default feature, and if users want the backend-specific inputs, they could disable ignore it.

EDIT: Since features should be additive, the backend-specific inputs should remain available even if users enable the common set.

@potatotech potatotech self-assigned this Feb 2, 2022
@potatotech potatotech added the enhancement New feature or request label Feb 2, 2022
@potatotech
Copy link
Collaborator

On second thought, it would be better for the common set to be a core feature that cannot be disabled. This library is meant to abstract over the backends, after all. Backend-specific inputs would then become an opt-in feature. This will be a breaking change.

@olefasting
Copy link
Member Author

On second thought, it would be better for the common set to be a core feature that cannot be disabled. This library is meant to abstract over the backends, after all. Backend-specific inputs would then become an opt-in feature. This will be a breaking change.

I agree. This seems like the best design to me, at least. We should probably bite the bullet and Break All The Things ;)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants