diff --git a/java/libraries/sound/src/cpp/processing_sound_MethClaInterface.cpp b/java/libraries/sound/src/cpp/processing_sound_MethClaInterface.cpp index ed3fb21ac..70b0b85d4 100644 --- a/java/libraries/sound/src/cpp/processing_sound_MethClaInterface.cpp +++ b/java/libraries/sound/src/cpp/processing_sound_MethClaInterface.cpp @@ -81,6 +81,7 @@ JNIEXPORT jint JNICALL Java_processing_sound_MethClaInterface_engineNew (JNIEnv .addLibrary(methcla_plugins_tri) .addLibrary(methcla_plugins_pulse) .addLibrary(methcla_soundfile_api_libsndfile) + .addLibrary(methcla_soundfile_api_mpg123) .addLibrary(methcla_plugins_patch_cable) .addLibrary(methcla_plugins_sampler) .addLibrary(methcla_plugins_white_noise) diff --git a/java/libraries/sound/src/processing/sound/SoundFile.java b/java/libraries/sound/src/processing/sound/SoundFile.java index 491902871..a65d33487 100644 --- a/java/libraries/sound/src/processing/sound/SoundFile.java +++ b/java/libraries/sound/src/processing/sound/SoundFile.java @@ -1,5 +1,6 @@ package processing.sound; import processing.core.*; +import java.io.File; public class SoundFile implements SoundObject { @@ -14,8 +15,7 @@ public class SoundFile implements SoundObject { float m_add=0; int m_cue=0; float m_pos=0; - boolean m_loop; - + boolean m_loop; public SoundFile(PApplet theParent, String path) { this.parent = theParent; @@ -24,7 +24,13 @@ public class SoundFile implements SoundObject { m_engine.start(); methCla = new MethClaInterface(); m_filePath=theParent.dataPath(path); - m_info = m_engine.soundFileInfo(m_filePath); + File sample = new File(m_filePath); + if(sample.isFile() == true){ + m_info = m_engine.soundFileInfo(m_filePath); + } + else { + System.out.println("Error: Soundfile doesn't exist. Pleae check path"); + } } public int frames(){ diff --git a/java/libraries/sound/todo.txt b/java/libraries/sound/todo.txt index c6442b31c..7cfc290a8 100644 --- a/java/libraries/sound/todo.txt +++ b/java/libraries/sound/todo.txt @@ -13,6 +13,7 @@ + Fix problem of passing effects to Analyzers + Make audio input work - Use Patch Cables for signal splitting for effects + + Fix MP3 thing Features: + Compile Windows Version