Dark Bit Factory & Gravity

ARCHIVE => Archive => Java,JS & Flash => Topic started by: benny! on March 08, 2007

Title: Processing
Post by: benny! on March 08, 2007
Hi.

I want to share the following link with you. It is an open source programming language to easily create
Java applets.

http://processing.org/ (http://processing.org/)

Here is the official quote from the entry page :
Quote
Processing is an open source programming language and environment for people who want to program
images, animation, and sound. It is used by students, artists, designers, architects, researchers, and
hobbyists for learning, prototyping, and production. It is created to teach fundamentals of computer
programming within a visual context and to serve as a software sketchbook and professional production
tool. Processing is developed by artists and designers as an alternative to proprietary software tools in
the same domain.

If you are interested, here are some examples by GHOSTAGENCY :

http://www.ghostagency.net/processing/sketch_cubo_fractal/index.html (http://www.ghostagency.net/processing/sketch_cubo_fractal/index.html)

http://www.ghostagency.net/processing/spyro_study/index.html (http://www.ghostagency.net/processing/spyro_study/index.html)

http://www.ghostagency.net/processing/relations_var1/index.html (http://www.ghostagency.net/processing/relations_var1/index.html)
Title: Re: Processing
Post by: Shockwave on March 08, 2007
Really cool stuff Benny! I like the last one the best.
Title: Re: Processing
Post by: rdc on March 08, 2007
Interesting.
Title: Re: Processing
Post by: Paul on March 08, 2007
looks good  :clap:
Title: Re: Processing
Post by: rdc on March 08, 2007
This is quite a little development system. Very exciting. I'll have to work something up in this. Thanks for the link Benny.
Title: Re: Processing
Post by: benny! on March 08, 2007
Your welcome. I got in touch with Processing some years ago ( it was in ALPHA stage ).
Nearly forget about it because I tend to write my Java applets from scratch now. Never-
theless, it makes gfx coding with java very easy and has some nice built in function.

Furthermore, you can extend your programs with normal java classes rather easily ...

Btw, there is also a version for java enabled mobile phones around at :

http://mobile.processing.org/index.php (http://mobile.processing.org/index.php)

I tested it back in 2005 and it did work perfectly on my mobile as far as I remember. I
did write a little horizontal starfield. Here is the code for it :

Code: [Select]
Star [] s;
int  numStars;
int  centerX;
int  centerY;
 
void setup()
{
  numStars = 30;
  centerX = width >> 1;
  centerY = height >>1;
  s = new Star[numStars];
  for (int i = 0; i < numStars; i++)
  {
    s[i] = new Star();
  }
}
 
void draw()
{
  background(0);
 
  for (int i = 0; i < numStars; i++)
  {
    s[i].draw();
  }   
}
 
class Star
{
  int x;
  int y;
  int z;
  int f;
   
  Star()
  {
    this.x = random(width);
    this.y = random(height);
    this.z = random(1,4);
    this.f = this.z * 50;
  }
   
  void draw()
  {
    stroke(f);
    this.x = this.x - this.z;
 
    if (this.x > 0)
    {     
      point (this.x, this.y);
    }
    else
    {
      this.x = width;
      this.y = random(height);
      this.z = random(1,4);
      this.f = this.z * 50;
    }   
  }
}
Title: Re: Processing
Post by: Shockwave on March 09, 2007
Looks nice and straight forward :)
The syntax is very similar looking to c++
Title: Re: Processing
Post by: mike_g on March 09, 2007
Looks cool,when I start learning Java later this year I'll be sure to get back to this stuff :)