tesselode / kira

Library for expressive game audio.
https://crates.io/crates/kira
Apache License 2.0
837 stars 42 forks source link

Expose loaders and cpal backend using features? #20

Closed simast closed 2 years ago

simast commented 2 years ago

This is really more like a question here. But I found having separate crates I need to have dependencies on core functionality a bit weird. Would it not be better instead of requiring users to have separate dependencies in their Cargo.toml - have the kira-cpal and kira-loaders exposed as features instead? Internally you still have multiple crates, they can still be disabled with default-features = false, custom backend/loader still can be implemented by user, etc.

At least from my experience in Rust this seems to be a more common approach in libraries, but maybe there is a good reason it is the way it is?

tesselode commented 2 years ago

kira-cpal and kira-loaders would not work on wasm, so I think if I exposed it as a feature, I'd also have to make it available only on desktop targets? That seems a little awkward to me.

tesselode commented 2 years ago

cpal and loaders are now exposed as features in v0.6.0 beta 6.