Hello Guest

WaveData.create returns null

  • 2 Replies
WaveData.create returns null
« on: March 05, 2012, 03:13:35 »

I am having great difficulties getting a sound to load. I initialized OpenAL, and then I attempted to load them like this:

Code: [Select]
FileInputStream fin;

fin = new FileInputStream("data/sounds/blam.wav");
catch(FileNotFoundException e)
System.out.println("Error trying to load sound data/sounds/blam.wav: Could load the sound file!");
return false;

    WaveData waveFile = WaveData.create(new BufferedInputStream(fin));

It finds the file, but WaveData.create always returns null.

What am I doing wrong here?

Re: WaveData.create returns null
« Reply #1 on: March 10, 2012, 02:53:07 »
Never mind, I figured it out. For some reason, re-exporting the WAVE file made it work.

Re: WaveData.create returns null
« Reply #2 on: November 02, 2013, 22:22:24 »
i think we may be in the same boat.. what do you mean you re-exported?