So I've created this audio sampler that holds sounds in groups. I designed if first with just one group to get the basics working. Once I added the rest which includes hundreds of audio files I, understandably, got an out of memory message upon opening the app.
I tried to fix this by only loading the sounds needed. i.e. I moved the "class= new Class();" parts from setup into the code for the buttons that switch groups. Now my app opens and I don't get a memory error... until I choose a group.
What gives?
Is this because I still declared the object before setup? ( Class class;)
I need help figuring out conservation of memory. How do I load the sounds only when I need them?