Thursday, May 3, 2007

Final









For my final in ENDS 170 I worked with "processing". To start off, I went through some tutorials on processing.org to learn more about the program. I then decided what I wanted to do, which was create a program where little circles could be manipulated by the mouse(such as move them around and stuff.) It doesn't sound too horribly difficult except I wanted to do it without the mouse ever actually touching them. So I tried some ideas and none of them worked. Wondering what to do, I found a website with a physics library that was just what I needed. I then started to work with the particle system introduced in the physics library. First I tried to move my circles around using springs, but I could never get it to work very well. I then tried reversing the attraction force and it worked! After some tweaking on the force of the repulsion, amount of circles, and making walls at the edge of the program, I had my program. So what now? I still had some time before the final so I started messing with random and loops. I wrote several more programs dealing with certain aspects of them. One creates random colored rectangles according to the placement of the mouse. Each rectangle is piled on top of another. To do this I set it to loop and reduce the size of the circle by 1 every loop until it I did the same concept again except the rectangles appear at random places on the screen at random sizes and shapes and slowly turn the page white. A third program was created with 3 dots on a white background. When the user clicks the screen, it seems as if the dots are bouncing around the box. This is using random in a loop with background replaced during every loop. Because of this the screen is cleared after every circle is created, making it look as if it is bouncing around the box. I wrote one program just on loops. It is a blue circle that gradually gets smaller, looking as if water is draining. reached 0, at which point it starts over. Overall I learned a lot from writing in processing. I have never really programed before and I feel that I have made huge improvements over the past few weeks. At first I had to constantly check at how to setup the programs. On the last few programs I rarely had to look at an example and was writing based on what I had learned as opposed to what the website said. My programs may not be the most complex ever created, but I tried to make them interesting by making them interactive with the user. This showed me that I can actually enjoy programming(against my first thoughts) and I see there is more art in it than I previously believed.