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.
IndexProcessing DevelopmentLibraries,  Tool Development › advice about libraries
Page Index Toggle Pages: 1
advice about libraries (Read 1183 times)
advice about libraries
May 7th, 2009, 3:19pm
 
I want to know what the difference is in performance if you were to take the code inside a library and run it as regular classes compiled at runtime like the rest of a typical Processing sketch. What are the advantages of libraries other than being standardized and portable?

If I break some code out of its library and embed it directly in my sketch will I see any performance increase? Will I lose performance?

thanks for any and all advice in advance...
Best!
Re: advice about libraries
Reply #1 - May 7th, 2009, 3:51pm
 
i have to admit i dont know, but i guess because the whole code is compiled before it starts anyway i guess you dont see any difference.
Re: advice about libraries
Reply #2 - May 8th, 2009, 12:56am
 
You might gain... some milliseconds at startup. Because that's one jar less to load and perhaps some classes less to handle if you trim the library down.
Probably not worth the work, unless you also want to reduce the size of the jar.
Page Index Toggle Pages: 1