PointSound problem

Hi all

I want to have a pointsound which fades out, if you move more far away from it the less you hear from it.

I do like this:


MediaContainer mediaContainer = new MediaContainer("g:/birds12.wav");
PointSound pointSound = new PointSound(mediaContainer, 1.0f);
pointSound.setLoop(PointSound.INFINITE_LOOPS);
pointSound.setEnable(true);
branchGroup.addChild(pointSound);

How do I need to do if i want to make a “fade-out”?

Thanks in Advance

Emil Alonzo

well i would say use FMOD - theres a java wrapper version of it in LWJGL. its way faster and has much better memory handleing. CPU load is real small also.

javasound is ok but the CPU loads is high. Try OpenAL that was working for me fine but that was a while ago. im using FMod now.

– note: fmod is not free and there no macosx java wrapper :frowning: yet

aNt -
Hi, that FMOD looks interesting, as I’ve got problems with JOAL in Xith3D (it’s just seems really buggy) I’d like to try it.

The API looks a little confusing, any code snippets to get started (say a single 3d point sound looping)?