I've done some work on the sound system in main.cxx and have attached a patch for folks to review if they want to look at what I did.
I made a simplifying assumption that the listener is either stationary (stationary enough) or it is tracking with the aircraft model position. The existing code does a good job of transforming the listener and model velocities into the correct coordinate frame. This is required for doppler effects to work, so I didn't want to change that. However, the mechanism for computing model and listener velocities (current position - last position) leads to enough jitter/variability that it causes noticeable defects or artificats in the audio output. So what I have done is to grab the velocity vector from the FDM in NED coordinates, compute the length, and use this to scale the existing model_vel vector to the correct length. This should remove velocity jitter artifacts from the previous scheme and result in a smooth consistent velocity vector. Then I used my simplifying assumption to set the listener velocity vector to (a) zero if the listener is stationary or (b) the model_vel if the listener is moving. This seems to really help clean up the stall horn sound (and hopefully the marker beacon sounds which suffered the same effect.) But at the same time, the doppler effects are maintained as they were. I'm not sure this is the final solution, but I think it's a step in the right direction. Regards, Curt. -- Curtis Olson: http://baron.flightgear.org/~curt/
main-sound-patch.diff
Description: Binary data
------------------------------------------------------------------------- This SF.Net email is sponsored by the Moblin Your Move Developer's challenge Build the coolest Linux based applications with Moblin SDK & win great prizes Grand prize is a trip for two to an Open Source event anywhere in the world http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________ Flightgear-devel mailing list Flightgear-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/flightgear-devel