I tried to test sound file but there is no respond. Can some one tell me the reason. The music.play become yellow and the following error is on consol: NullPointerException
Here is the code:
import processing.sound.*;
SoundFile music;
void setup() {
size(400, 400);
music = new SoundFile(this, “music.mp3”);
music.play();
}
Do you have a sound file in the correct folder and using the correct name?
Explore the menu and look for "Show Sketch Folder:
There is a mention in here of NullPointerException:
The guidelines in the Processing FAQ ask:
Please help us help you by formatting your code on this forum. Formatted code is not only easier to read, it sometimes cannot be cut-pasted and run correctly if not formatted, making it difficult for others to help you.