We closed this forum 18 June 2010. It has served us well since 2005 as the ALPHA forum did before it from 2002 to 2005. New discussions are ongoing at the new URL http://forum.processing.org. You'll need to sign up and get a new user account. We're sorry about that inconvenience, but we think it's better in the long run. The content on this forum will remain online.
IndexProgramming Questions & HelpSound,  Music Libraries › Ess -java.lang.OutOfMemoryErrorwhile loading mp3
Page Index Toggle Pages: 1
Ess -java.lang.OutOfMemoryErrorwhile loading mp3 (Read 636 times)
Ess -java.lang.OutOfMemoryErrorwhile loading mp3
Mar 25th, 2007, 6:05pm
 
Hi people,
does anybody know if it is even possible to load an mp3 of size cca 13MB via new AudioChannel () ? [ it is stereo recording, dont know if this is important, I've tried to load only left channel anyway, but no luck ]
I've set up the VM to use as minimum 512mb and max 1024mb of memory , still get the java.lang.OutOfMemoryError exception while constructing new AudioChannel..
I use all support files for mp3 import as suggested on krister's pages on kubuntu
thanx for help!
Re: Ess -java.lang.OutOfMemoryErrorwhile loading m
Reply #1 - Mar 25th, 2007, 8:48pm
 
Try using an AudioStream rather than Channel. For an AudioChannel it has to de-compress the entire mp3 into memory.. and it could easily end up as about 150meg when decompressed. An AudioStream will only load small chunks at a time as and when needed.
Page Index Toggle Pages: 1