Any ideas on how to make an area (cubic) sound, ie: for ambient sounds which are still 3D?
I once faked this with a position vector (for the 3d sound) which was moving on middle axis (on the longer side) of the box.
box is defined with two vectors: (-10, -20, -10 ), (10, 20, 10)
the "longer" side is Y, so this will be the middle axis, from (0, -20, 0) to (0, 20, 0). whenever listner gets into the box, i reposition the the sound origin, so that is it closest to the listner, but still "locked" on the middle axis.
perhaps any better ideas?
- vesoljc asked 12 years ago
That would be a really nice feature. I have implemetented lots of geometric emitters during the years but none of them were very optimal. Often I used the idea of finding the closest point in the geometry and let it represent the emitter and I guess it worked ok but with some additional morphing it could be so much better.
About 3DPanLevel. Doesn’t it only set the mixlevel for panning? In the designer tool it still seems to keep the volume attenuation so I’m guessing if you use the function in code it will do the same or? Anyways, being able to morph between 2d and 3d is really nice and something that can be very usefull.
- Frohagen answered 12 years ago
It doesnt just adjust the panning no. It morphs it towards a 2d sound. Not a 2d sound with 3d attenuation. A pure 2d sound.
In fmod designer if someone has specified a distance parameter with a custom rolloff using a volume envelope, then you might see the behaviour you are talking about.
The geometry volume stuff has the same issues you were talking about. All the horrible stuff like convex vs concave/twisted shapes etc. We’ve discussed it a few times here but have to get onto it when we have more time, which isnt right now. It would just be a tool that you could write yourself with the current engine anyway, it would just be to make your life easier
When you ‘enter’ the volume, you can morph a sound from 3d to 2d with Channel::set3DPanLevel, and it gives a very nice effect of being a point source to gradually enveloping you.
For outside the volume, you will have to do that yourself with a moving point source like you say. We’re planning to add Sound::setVolumetricSource(Geometry *object); or something like that, to allow automatic volumetric behaviour with any shape, but thats a while off yet.
Please login first to submit.