-
Notifications
You must be signed in to change notification settings - Fork 36
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
Get only declared properties of a Synth #22
Comments
So, if I understand correctly, you're looking for a list of the oscillator properties separate from the envelope / filter properties? There are actually separate If you can give me a bit more info on why you need this maybe I can help... |
I guess the only way to do it now is by making a function using regexp, would this be the only way to go on? |
Can you give me an ideal example of how your code would look if gibberish was setup the way you're looking for? I think that would help me figure out what is/isn't possible. |
Yeah, I don't think there's a way to do what you want exactly. However, there is often a These really weren't intended for end-users, so they don't seem to be consistently implemented, but I thought I'd point them out just in case they might help... sorry I don't have better news! |
I see; Thanks for the tips. I managed to get it going and now the app looks much better. One more question if you don't mind. I am making separate range specifications using this below, which works okayish, but I am not sure I am using the appropriate range spec for each parameter. Could you help on this.
The ranges above might look weird, is just some trial and error thing now, so I would appreciate some help on the nominal range specs, or any pointer on these issue. |
Sorry, just saw this now... these things are tricky. An attack stage on a slow moving sound could last a minute, for example, so specifying a maximum value doesn't make a lot of sense. I've had to do similar things in projects I've had and it's always been problematic. Here's a possibly better set: let scaleValue = require('scale-value');
const specs = {
attack: scaleValue(0, 1, 10, 44100 * 10),
decay: scaleValue(0, 1, 10, 22050 * 10),
sustain: scaleValue(0, 1, 0, 44100 * 10),
release: scaleValue(0, 1, 10, 44100 * 10),
gain: scaleValue(0, 1, 0.0, 1),
frequency: scaleValue(0, 1, 0, 1)
};
|
I would like to get only the properties of saw and not of the Synth. Is that possible?
I am using Object.keys(saw) thus it turns (as expected) => waveform | attack | decay | sustain | sustainLevel | release | useADSR | shape | triggerRelease | gain | pulsewidth | frequency | pan | antialias | panVoices | loudness | glide | saturation | filterMult | Q | cutoff | filterType | filterMode | isLow
The text was updated successfully, but these errors were encountered: