We are about to switch to a new forum software. Until then we have removed the registration on this forum.
Hello,
I am having trouble with an audio reactive project I am working on. So far I have a 3D environment that is using the Minim library to analyze FFT values drawn from the microphone of my PC to change the size of the objects in the environment. I am trying to get this effect to work on my Android phone with the "Google Cardboard" library (http://android.processing.org/tutorials/cardboard_intro/index.html). I am able to display the environment and look around perfectly in VR, however I am unable to analyze the microphone input from my phone. I understand this is not possible with Minim, and I have spent hours looking for, and trying various alternative solutions. I am relatively new to programming and many explanations I have found are very advanced. Is there a simple way to achieve this?
Thank you so much.
Answers
The link shows a VR environment example but I don't see the reference to the FFT. What do you want to get from the FFT? What effect are you looking to implement? In other words, what minim functions were you thinking in using?
Kf
``I have the following code which changes the size of a sphere based on in.right.get(i+1)*50. I am trying to get something working like this on the Android device so I can implement it in VR. I can get the Sphere to display just fine, however I am just having trouble with the audio portion. I have been trying to follow this link but am having trouble. https://forum.processing.org/one/topic/microphone-on-android.html
Thank you!
Did you try the audioInput example from the Ketai library?
http://ketai.org/examples/audioinput/
Notice that as fas as I know, minim kibrary doesn't work in Android.
Kf
I encourage you to work in java mode and using minim to create a demo of your effect using FFT. This will give you a better understanding how to implement your code in Android mode. In java mode you will have the advantage of your code being executed faster and debugging will be less painful.
Kf
@ThimothyThomasson===
--you cannot use minim with the android mode
--in order to capture the mic you have to use the AudioRecord class from android:: see here for more details https://developer.android.com/reference/android/media/AudioRecord.html
-- with this class you (normally) can save your input then read it
-- but you can also read it without saving using a buffer and an audio track
-- as for applying fft in real time to that best way (as for me) is to use the tarsosdsp lib