Open pixelzoom opened 9 months ago
2/13/24 design meeting @arouinfar @Ashton-Morris @emily-phet @pixelzoom
@Ashton-Morris presented a mockup.
Sounds for "flow started" and "flowed ended", to add realism.
@Ashton-Morris wondered if we needed an additional "flow changed" sound.
"flow" sound continues while faucet is open. Should there be an option to fade the "flow" sound out after some period of time?
Possibly use noise generator (tambo NoiseGenerator.ts) for "flow".
"Tap to dispense" feature could use same sequence of "flow started" => "flow" => "flow ended" sound. @pixelzoom pointed out that "tap to dispense" is used to dispense small amounts of fluid, typically over milliseconds, so playing the full sequence might be problematic.
I did a quick sprint on trying to add default sound to FaucetNode, similar to Slider, since FaucetNode and Slider both extend AccessibleSlider. Unfortunately, none of the sound code is in AccessibleSlider, it's all in Slider. And FaucetNode seems to be missing a KeyboardDragListener, so I could only get sound working for DragListener. Here's an uncommitted patch showing how far I got before I bailed.
Ideally (perhaps), AccessibleSlider should handle sound, so that anything that behaves like a slider would get default sounds. But that looks like a lot of work.
Also noting that Slider's API for sound is sort of confusing. options.soundGenerator
and options.valueChangeSoundGeneratorOptions
actually have nothing to do with SoundGenerator. Slider only takes a ValueChangeSoundPlayer, which is not a SoundGenerator.
Lastly... The default for the 'tap to dispense' feature should probably be similar to the default push button sound. But I didn't get far enough to investigate.
Related to sound design for Faraday's Electromagnetic Lab (FEL), this issue involves both design and development.
From https://github.com/phetsims/faradays-electromagnetic-lab/issues/15#issuecomment-1901285540 ...