DevMaster.net Forums
[[ Home | Forums | 3D Engines Database | Wiki | Articles/Tutorials | Game Dev Jobs | IRC Chat Network | Contact Us ]]

Go Back   DevMaster.net Forums > Programming & Development > Sound and Music Programming
User Name
Password
Register FAQ Members List Search Today's Posts Mark Forums Read

Reply
 
Thread Tools Search this Thread Display Modes
Old 06-10-2005, 01:38 PM   #1
SgtMaster
New Member
 
Join Date: Jun 2005
Posts: 1
Default

Hi,
I have been programming a 3D sound with OpenAL, but encountered a problem with doppler effect that I cannot seem to solve. Could I please borrow your wisdom?

Here it goes. I currently have a 3D world where the listener is set where the camera is (first person view). The orientation of the listener is calculated from the direction the camera is facing. Velocity of the listener is currently set to 0. Lets say I fire a rocket with at direction D with some scalar velocity. The program creates a source with rocket flying sound positioned initially at the camera, with direction D and velocity calculated by multiplying scalar factor to direction D. The position of the source is constantly updated, so in my logic, this should produce a sound moving away from the listener, flying towards the direction specified by D at some constant speed.

So this should make the sound pitch lower as the sound is moving away, and the pitch shouldn't change no matter which way I am firing. However, the pitch does change depending on the direction I am firing, and the direction I am facing. So, if I fire in one direction, and if I immediately rotate my camera (change the orientation of the listener), the pitch changes.

Any idea on why this might be happening? Am I misinterpreting the source velocity? Why does listener orientation take a roll in doppler effects?

Thank you for reading, and any response is greatly appreciated.
SgtMaster is offline   Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Forum Jump


All times are GMT -7. The time now is 06:55 AM.


Powered by vBulletin
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.