First, I'd say reboot it (full shut down, take battery out and back in and on again after a minute or so).
Second, there's threads about a fault if you use the headset jack, where the connector gets stuck and leaves the phone thinking that there's a headset plugged in, so you have to play with it a few times and hope to get it back (I tend to only use a Bluetooth headset to prevent having to deal with plugs and wires). A quick search should get you to those threads.
Third, try using a stereo Bluetooth device, check how the sound is, then switch it back.
Questions would be... do you have any apps that might have caused this?
There is a possibility that it's hardware related, and that would require repairs.