ewjordan
Ex Member
Re: Processing possibilities
Reply #3 - May 4th , 2007, 1:15am
In my opinion, the reason Processing is great is that it really simplifies writing graphical Java applets. If you've ever fought with Java trying to get a constant frame rate double buffered applet running without nasty pauses and glitches, you'll appreciate all the behind the scenes stuff that Processing automatically does for you when you type size(640,480,P3D); frameRate(30);. I remember the first time I tried to write a graphical Java applet, I discovered that it would only run smoothly if I added in an empty statement to the run loop. To this day I still don't know why, and frankly, I don't care, because there's no point in fighting with garbage like that when in Processing you can just focus on your actual application logic instead of tricking the applet into behaving as you think it should. Another thing that hooked me is the fact that the P3D renderer allows you to easily render 3D stuff in software, so you can publish 3D web applets without going through the trouble to design your own renderer - even if you do go through that trouble, P3D already has lighting and a pretty complex transformation system that's better than anything you're likely to implement on your own. And now you can even (as long as you're willing to accept a signed applet) publish OpenGL stuff without any difficulty. So basically, if you're interested in graphical stuff and doing it simply (i.e. without dealing with lower level graphical BS), Processing is for you. Something that would take ~500 lines of code in pure Java is often a mere 80 line sketch in Processing (and if you're using 3D, the gains are even more significant). If you're interested in UI stuff, it's probably not your thing, since things like buttons and text fields are a little trickier, and you need to do most of that yourself. And if worst comes to worst, you can always label a file ".java" and use pure Java code (though Swing doesn't play well with Processing), so you really lose nothing by using it.