sinshu / rustysynth

A SoundFont MIDI synthesizer written in pure Rust
Other
108 stars 20 forks source link

Add sample ID getter for instrument region #11

Closed pomscyth closed 11 months ago

pomscyth commented 11 months ago

Currently, some information about the sample used by an instrument region (e.g. sample ID, original pitch, sample rate, etc.) are not publicly available (being visible only within the crate). This PR addresses that by providing a way to access the sample directly via the sample ID.

sinshu commented 11 months ago

Thanks for the PR. This is indeed necessary 🤔 I think it would be better if the type returned by get_sample_id was usize, what do you think?

pomscyth commented 11 months ago

I'm okay, doesn't matter to me.