diff --git a/.github/FUNDING.yml b/.github/FUNDING.yml new file mode 100644 index 000000000..93c4b27b4 --- /dev/null +++ b/.github/FUNDING.yml @@ -0,0 +1,2 @@ +github: processing +custom: https://processingfoundation.org/ diff --git a/.gitignore b/.gitignore index 367672981..27c953a9e 100644 --- a/.gitignore +++ b/.gitignore @@ -23,3 +23,4 @@ about/ contrib_generate/contribs.txt # File now built on the server side; don't need to track here contrib_generate/contributions.txt # File now built on the server side; don't need to track here *~ +/bin/ diff --git a/README.md b/README.md index c0183179c..60a674da3 100644 --- a/README.md +++ b/README.md @@ -1,10 +1,14 @@ +> ⚠️ This repository is now deprecated and will be archived soon. If you have any issues or want to submit a pull request, please direct them to the [processing-website](https://github.com/processing/processing-website) repo. Make sure to check the [README](https://github.com/processing/processing-website/blob/main/README.md) for information on how to contribute to the documentation. + + + Processing Documentation ========== -This is the official source code for the Processing reference, examples, tutorials, and [processing.org](http://processing.org) web site. +~~This is the official source code for the Processing reference, examples, tutorials, and [processing.org](http://processing.org) web site.~~ -If you have found an error in the Processing reference, examples, tutorials, or website you can file it here under the ["issues" tab](https://github.com/processing/processing-docs/issues). +~~If you have found an error in the Processing reference, examples, tutorials, or website you can file it here under the ["issues" tab](https://github.com/processing/processing-docs/issues).~~ -The [processing](https://github.com/processing/processing) repository contains the source code for Processing itself. (Please use that link to file issues regarding the Processing software.) +~~The [processing](https://github.com/processing/processing) repository contains the source code for Processing itself. (Please use that link to file issues regarding the Processing software.)~~ diff --git a/content/api_en/LIB_io/GPIO_digitalRead.xml b/content/api_en/LIB_io/GPIO_digitalRead.xml index 2efc9fbb1..4a8c8d36d 100755 --- a/content/api_en/LIB_io/GPIO_digitalRead.xml +++ b/content/api_en/LIB_io/GPIO_digitalRead.xml @@ -14,20 +14,21 @@ +Configures a pin to act either as input (INPUT), or input with internal pull-up resistor (INPUT_PULLUP), or input with internal pull-down resistor (INPUT_PULLDOWN) or output (OUTPUT)

Unlike on Arduino, where pins are implicitly set to inputs by default, it is necessary -to call this function for any pin you want to access, including input pins. +to call this function for any pin you want to access, including input pins.
+
+Pull-up and pull-down resistors are very useful when connecting buttons and switches, since they will force the value of the pin in a specified electrical state when no electrical connection is made, and the pin would otherwise be left "floating".
+
+The ability to set (and clear) pull-up and pull-down resistors is currently limited to the Raspberry Pi running the Raspbian distribution. On other systems, a warning will be shown. ]]>
diff --git a/content/api_en/LIB_io/LED.xml b/content/api_en/LIB_io/LED.xml index 286d1c56b..12f9fa0f7 100755 --- a/content/api_en/LIB_io/LED.xml +++ b/content/api_en/LIB_io/LED.xml @@ -17,17 +17,20 @@ LED greenLed; boolean ledOn = false; void setup() { + // list all available LEDs + printArray(LED.list()); + // the green LED is led0 on the Raspberry Pi - greenLed = new LED(LED.list()[0]); + greenLed = new LED("led0"); frameRate(0.5); } void draw() { ledOn = !ledOn; if (ledOn) { - greenLed.set(1.0); + greenLed.brightness(1.0); } else { - greenLed.set(0.0); + greenLed.brightness(0.0); } } diff --git a/content/api_en/LIB_io/LED_brightness.xml b/content/api_en/LIB_io/LED_brightness.xml index c6d5f675d..3696d5f7f 100755 --- a/content/api_en/LIB_io/LED_brightness.xml +++ b/content/api_en/LIB_io/LED_brightness.xml @@ -18,16 +18,16 @@ boolean ledOn = false; void setup() { // the green LED is led0 on the Raspberry Pi - greenLed = new LED(LED.list()[0]); + greenLed = new LED("led0"); frameRate(0.5); } void draw() { ledOn = !ledOn; if (ledOn) { - greenLed.set(1.0); + greenLed.brightness(1.0); } else { - greenLed.set(0.0); + greenLed.brightness(0.0); } } diff --git a/content/api_en/LIB_io/LED_close.xml b/content/api_en/LIB_io/LED_close.xml index 3b6d993a4..a49e9d1cf 100755 --- a/content/api_en/LIB_io/LED_close.xml +++ b/content/api_en/LIB_io/LED_close.xml @@ -18,16 +18,16 @@ boolean ledOn = false; void setup() { // the green LED is led0 on the Raspberry Pi - greenLed = new LED(LED.list()[0]); + greenLed = new LED("led0"); frameRate(1); } void draw() { ledOn = !ledOn; if (ledOn) { - greenLed.set(1.0); + greenLed.brightness(1.0); } else { - greenLed.set(0.0); + greenLed.brightness(0.0); } } diff --git a/content/api_en/LIB_io/PWM_set.xml b/content/api_en/LIB_io/PWM_set.xml index 5437657b2..f21b3bfba 100755 --- a/content/api_en/LIB_io/PWM_set.xml +++ b/content/api_en/LIB_io/PWM_set.xml @@ -17,7 +17,9 @@ +
+When no period is specified, a default 1 kHz (1000 Hz) is used. ]]>
diff --git a/content/api_en/LIB_net/clientEvent.xml b/content/api_en/LIB_net/clientEvent.xml index b71892510..d831f37a4 100755 --- a/content/api_en/LIB_net/clientEvent.xml +++ b/content/api_en/LIB_net/clientEvent.xml @@ -19,25 +19,27 @@ int dataIn; void setup() { size(200, 200); myClient = new Client(this, "127.0.0.1", 5204); + noLoop(); } -void draw() { } // Empty draw keeps the program running +void draw() { + background(dataIn); +} -// ClientEvent message is generated when the server -// sends data to an existing client. +// ClientEvent message is generated when the +// server sends data to an existing client. void clientEvent(Client someClient) { print("Server Says: "); - dataIn = myClient.read(); + dataIn = someClient.read(); println(dataIn); - background(dataIn); - + redraw(); } ]]>
diff --git a/content/api_en/LIB_sound/AudioDevice.xml b/content/api_en/LIB_sound/AudioDevice.xml index 5bb214dba..1172dc020 100755 --- a/content/api_en/LIB_sound/AudioDevice.xml +++ b/content/api_en/LIB_sound/AudioDevice.xml @@ -4,7 +4,7 @@ Sound -I/O +Configuration Application @@ -29,16 +29,6 @@ void draw() { Audio Device allows for configuring the audio server. If you need a low latency server you can reduce the buffer size. Allowed values are power of 2. For changing the sample rate pass the appropriate value in the constructor. ]]> - - - - - - - - - - AudioDevice(parent, samplerate, buffersize) @@ -57,10 +47,8 @@ AudioDevice(parent, samplerate, buffersize) int: buffersize (i.e. 32/64/128 ..) - - - +Sound 1.0 diff --git a/content/api_en/LIB_sound/AudioSample.xml b/content/api_en/LIB_sound/AudioSample.xml new file mode 100755 index 000000000..053be266c --- /dev/null +++ b/content/api_en/LIB_sound/AudioSample.xml @@ -0,0 +1,49 @@ + + +AudioSample + +Sound + +Audio Files + +Application + + + + + + + + + + + diff --git a/content/api_en/LIB_sound/AudioSample_amp.xml b/content/api_en/LIB_sound/AudioSample_amp.xml new file mode 100644 index 000000000..7a1181b3e --- /dev/null +++ b/content/api_en/LIB_sound/AudioSample_amp.xml @@ -0,0 +1,42 @@ + + + +play() + +Sound Files + + + +Web & Application + + + + + + + + + diff --git a/content/api_en/LIB_sound/AudioSample_channels.xml b/content/api_en/LIB_sound/AudioSample_channels.xml new file mode 100755 index 000000000..af430a14d --- /dev/null +++ b/content/api_en/LIB_sound/AudioSample_channels.xml @@ -0,0 +1,40 @@ + + + +channels() + +Sound Files + + + +Web & Application + + + + + + + + + diff --git a/content/api_en/LIB_sound/AudioSample_cue.xml b/content/api_en/LIB_sound/AudioSample_cue.xml new file mode 100755 index 000000000..c4eae7ace --- /dev/null +++ b/content/api_en/LIB_sound/AudioSample_cue.xml @@ -0,0 +1,37 @@ + + + +cue() + +Sound Files + + + +Web & Application + + + + + + + + + diff --git a/content/api_en/LIB_sound/AudioSample_duration.xml b/content/api_en/LIB_sound/AudioSample_duration.xml new file mode 100755 index 000000000..b083d3e47 --- /dev/null +++ b/content/api_en/LIB_sound/AudioSample_duration.xml @@ -0,0 +1,38 @@ + + + +duration() + +Sound Files + + + +Web & Application + + + + + + + + + diff --git a/content/api_en/LIB_sound/AudioSample_frames.xml b/content/api_en/LIB_sound/AudioSample_frames.xml new file mode 100755 index 000000000..c58a3c077 --- /dev/null +++ b/content/api_en/LIB_sound/AudioSample_frames.xml @@ -0,0 +1,36 @@ + + + +frames() + +Sound Files + + + +Web & Application + + + + + + + + + diff --git a/content/api_en/LIB_sound/AudioSample_isPlaying.xml b/content/api_en/LIB_sound/AudioSample_isPlaying.xml new file mode 100755 index 000000000..9a7ab422b --- /dev/null +++ b/content/api_en/LIB_sound/AudioSample_isPlaying.xml @@ -0,0 +1,45 @@ + + + +isPlaying() + +Sound Files + + + +Web & Application + + + + + + + + + diff --git a/content/api_en/LIB_sound/AudioSample_jump.xml b/content/api_en/LIB_sound/AudioSample_jump.xml new file mode 100755 index 000000000..290eb7cfd --- /dev/null +++ b/content/api_en/LIB_sound/AudioSample_jump.xml @@ -0,0 +1,36 @@ + + + +jump() + +Sound Files + + + +Web & Application + + + + + + + + + diff --git a/content/api_en/LIB_sound/AudioSample_loop.xml b/content/api_en/LIB_sound/AudioSample_loop.xml new file mode 100644 index 000000000..f95b7e484 --- /dev/null +++ b/content/api_en/LIB_sound/AudioSample_loop.xml @@ -0,0 +1,40 @@ + + + +loop() + +Sound Files + + + +Web & Application + + + + + + + + + diff --git a/content/api_en/LIB_sound/AudioSample_pan.xml b/content/api_en/LIB_sound/AudioSample_pan.xml new file mode 100755 index 000000000..7b2b176db --- /dev/null +++ b/content/api_en/LIB_sound/AudioSample_pan.xml @@ -0,0 +1,38 @@ + + + +pan() + +Sound Files + + + +Web & Application + + + + + + + + + diff --git a/content/api_en/LIB_sound/AudioSample_pause.xml b/content/api_en/LIB_sound/AudioSample_pause.xml new file mode 100755 index 000000000..67ece9ab7 --- /dev/null +++ b/content/api_en/LIB_sound/AudioSample_pause.xml @@ -0,0 +1,51 @@ + + + +pause() + +Sound Files + + + +Web & Application + + + + + + + + + diff --git a/content/api_en/LIB_sound/AudioSample_play.xml b/content/api_en/LIB_sound/AudioSample_play.xml new file mode 100755 index 000000000..d1584ae38 --- /dev/null +++ b/content/api_en/LIB_sound/AudioSample_play.xml @@ -0,0 +1,40 @@ + + + +play() + +Sound Files + + + +Web & Application + + + + + + + + + diff --git a/content/api_en/LIB_sound/AudioSample_rate.xml b/content/api_en/LIB_sound/AudioSample_rate.xml new file mode 100755 index 000000000..fbe8dc446 --- /dev/null +++ b/content/api_en/LIB_sound/AudioSample_rate.xml @@ -0,0 +1,47 @@ + + + +rate() + +Sound Files + + + +Web & Application + + + + + + + + + diff --git a/content/api_en/LIB_sound/AudioSample_read.xml b/content/api_en/LIB_sound/AudioSample_read.xml new file mode 100755 index 000000000..b21fc039a --- /dev/null +++ b/content/api_en/LIB_sound/AudioSample_read.xml @@ -0,0 +1,56 @@ + + + +read() + +Sound Files + + + +Web & Application + + + + + + + + + +AudioSample.frames() + + diff --git a/content/api_en/LIB_sound/AudioSample_resize.xml b/content/api_en/LIB_sound/AudioSample_resize.xml new file mode 100755 index 000000000..d326abdc6 --- /dev/null +++ b/content/api_en/LIB_sound/AudioSample_resize.xml @@ -0,0 +1,40 @@ + + + +resize() + +Sound Files + + + +Web & Application + + + + + + + + + diff --git a/content/api_en/LIB_sound/AudioSample_sampleRate.xml b/content/api_en/LIB_sound/AudioSample_sampleRate.xml new file mode 100755 index 000000000..b67c1fb85 --- /dev/null +++ b/content/api_en/LIB_sound/AudioSample_sampleRate.xml @@ -0,0 +1,37 @@ + + + +sampleRate() + +Sound Files + + + +Web & Application + + + + + + + + + diff --git a/content/api_en/LIB_sound/AudioSample_write.xml b/content/api_en/LIB_sound/AudioSample_write.xml new file mode 100755 index 000000000..e8cfbeb4c --- /dev/null +++ b/content/api_en/LIB_sound/AudioSample_write.xml @@ -0,0 +1,49 @@ + + + +write() + +Sound Files + + + +Web & Application + + + + + + + + + +AudioSample.read + + diff --git a/content/api_en/LIB_sound/BrownNoise.xml b/content/api_en/LIB_sound/BrownNoise.xml index 72c8fe79b..f8b95cac7 100755 --- a/content/api_en/LIB_sound/BrownNoise.xml +++ b/content/api_en/LIB_sound/BrownNoise.xml @@ -29,66 +29,7 @@ void draw() { - - - - - - - - -play() -Start the generator - - - -stop() -Stop the generator - - - -amp() -Change the amplitude/volume of the generator - - - -add() -Offset the output of the generator by given value - - - -pan() -Move the sound in a stereo panorama - - - -set() -Set multiple parameters at once - - - -BrownNoise(parent) - - - -parent -PApplet: typically use "this" - - - - - - - -1.0 - -Object - -Library - diff --git a/content/api_en/LIB_sound/BrownNoise_add.xml b/content/api_en/LIB_sound/BrownNoise_add.xml index ec5550347..d00869e8d 100755 --- a/content/api_en/LIB_sound/BrownNoise_add.xml +++ b/content/api_en/LIB_sound/BrownNoise_add.xml @@ -35,19 +35,4 @@ void draw() { The .add() method is useful for modulating other audio signals. ]]> - -noise.add(add) - - - - - - -1.0 - -Method - -Library - - diff --git a/content/api_en/LIB_sound/BrownNoise_amp.xml b/content/api_en/LIB_sound/BrownNoise_amp.xml index edb349c7d..4264c2f4b 100755 --- a/content/api_en/LIB_sound/BrownNoise_amp.xml +++ b/content/api_en/LIB_sound/BrownNoise_amp.xml @@ -35,24 +35,4 @@ void draw() { Changes the amplitude/volume of the noise generator. Allowed values are between 0.0 and 1.0. ]]> - -noise.amp(vol) - - - - - - - - - - - -1.0 - -Method - -Library - - diff --git a/content/api_en/LIB_sound/BrownNoise_pan.xml b/content/api_en/LIB_sound/BrownNoise_pan.xml index 71043d021..6644626fd 100755 --- a/content/api_en/LIB_sound/BrownNoise_pan.xml +++ b/content/api_en/LIB_sound/BrownNoise_pan.xml @@ -36,19 +36,4 @@ void draw() { Pan the generator in a stereo panorama. -1.0 pans to the left channel and 1.0 to the right channel. ]]> - -noise.pan(pos) - - - - - - -1.0 - -Method - -Library - - diff --git a/content/api_en/LIB_sound/BrownNoise_play.xml b/content/api_en/LIB_sound/BrownNoise_play.xml index 9a1c30f40..915d8cfcb 100755 --- a/content/api_en/LIB_sound/BrownNoise_play.xml +++ b/content/api_en/LIB_sound/BrownNoise_play.xml @@ -34,19 +34,4 @@ void draw() { Starts the Brown Noise generator. ]]> - -noise.play() - - - - - - -1.0 - -Method - -Library - - diff --git a/content/api_en/LIB_sound/BrownNoise_set.xml b/content/api_en/LIB_sound/BrownNoise_set.xml index 1ace27281..a24a1c3ef 100755 --- a/content/api_en/LIB_sound/BrownNoise_set.xml +++ b/content/api_en/LIB_sound/BrownNoise_set.xml @@ -41,19 +41,4 @@ void mousePressed() { Sets amplitude, add and pan position with one method. ]]> - -noise.set(amp, add, pos) - - - - - - -1.0 - -Method - -Library - - diff --git a/content/api_en/LIB_sound/BrownNoise_stop.xml b/content/api_en/LIB_sound/BrownNoise_stop.xml index 849ca5f8d..6111b73ae 100755 --- a/content/api_en/LIB_sound/BrownNoise_stop.xml +++ b/content/api_en/LIB_sound/BrownNoise_stop.xml @@ -38,19 +38,4 @@ void mousePressed() { Stops the Brown Noise generator. ]]> - -noise.stop() - - - - - - -1.0 - -Method - -Library - - diff --git a/content/api_en/LIB_sound/FFT_analyze.xml b/content/api_en/LIB_sound/FFT_analyze.xml index 6c05e7396..4bd4c1bfa 100755 --- a/content/api_en/LIB_sound/FFT_analyze.xml +++ b/content/api_en/LIB_sound/FFT_analyze.xml @@ -41,34 +41,14 @@ void draw() { for(int i = 0; i < bands; i++){ // The result of the FFT is normalized // draw the line for frequency band i scaling it up by 5 to get more amplitude. - line( i, height, i, height - spectrum[i]*height*5 ); + line(i, height, i, height - spectrum[i]*height*5 ); } } ]]> - -amp.analyze() - - - - - - - -float - - - -1.0 - -Method - -Library - - diff --git a/content/api_en/LIB_sound/PinkNoise.xml b/content/api_en/LIB_sound/PinkNoise.xml index 59f26ae9a..fd74f29e5 100755 --- a/content/api_en/LIB_sound/PinkNoise.xml +++ b/content/api_en/LIB_sound/PinkNoise.xml @@ -29,66 +29,7 @@ void draw() { - - - - - - - - -play() -Start the generator - - - -stop() -Stop the generator - - - -amp() -Change the amplitude/volume of the generator - - - -add() -Offset the output of the generator by given value - - - -pan() -Move the sound in a stereo panorama - - - -set() -Set multiple parameters at once - - - -WhiteNoise(parent) - - - -parent -PApplet: typically use "this" - - - - - - - -1.0 - -Object - -Library - diff --git a/content/api_en/LIB_sound/PinkNoise_add.xml b/content/api_en/LIB_sound/PinkNoise_add.xml index 999b05183..28de64b97 100755 --- a/content/api_en/LIB_sound/PinkNoise_add.xml +++ b/content/api_en/LIB_sound/PinkNoise_add.xml @@ -35,19 +35,4 @@ void draw() { The .add() method is useful for modulating other audio signals. ]]> - -noise.add(add) - - - - - - -1.0 - -Method - -Library - - diff --git a/content/api_en/LIB_sound/PinkNoise_amp.xml b/content/api_en/LIB_sound/PinkNoise_amp.xml index 14e8a8745..67e87cc56 100755 --- a/content/api_en/LIB_sound/PinkNoise_amp.xml +++ b/content/api_en/LIB_sound/PinkNoise_amp.xml @@ -35,24 +35,4 @@ void draw() { Changes the amplitude/volume of the noise generator. Allowed values are between 0.0 and 1.0. ]]> - -noise.amp(vol) - - - - - - - - - - - -1.0 - -Method - -Library - - diff --git a/content/api_en/LIB_sound/PinkNoise_pan.xml b/content/api_en/LIB_sound/PinkNoise_pan.xml index d786b649b..10bb0cf09 100755 --- a/content/api_en/LIB_sound/PinkNoise_pan.xml +++ b/content/api_en/LIB_sound/PinkNoise_pan.xml @@ -36,19 +36,4 @@ void draw() { Pan the generator in a stereo panorama. -1.0 pans to the left channel and 1.0 to the right channel. ]]> - -noise.pan(pos) - - - - - - -1.0 - -Method - -Library - - diff --git a/content/api_en/LIB_sound/PinkNoise_play.xml b/content/api_en/LIB_sound/PinkNoise_play.xml index 9cf795d7d..c40593f4d 100755 --- a/content/api_en/LIB_sound/PinkNoise_play.xml +++ b/content/api_en/LIB_sound/PinkNoise_play.xml @@ -34,19 +34,4 @@ void draw() { Starts the Pink Noise generator. ]]> - -noise.play() - - - - - - -1.0 - -Method - -Library - - diff --git a/content/api_en/LIB_sound/PinkNoise_set.xml b/content/api_en/LIB_sound/PinkNoise_set.xml index ff84919dc..9914d239f 100755 --- a/content/api_en/LIB_sound/PinkNoise_set.xml +++ b/content/api_en/LIB_sound/PinkNoise_set.xml @@ -41,19 +41,4 @@ void mousePressed() { Sets amplitude, add and pan position with one method. ]]> - -noise.set(amp, add, pos) - - - - - - -1.0 - -Method - -Library - - diff --git a/content/api_en/LIB_sound/PinkNoise_stop.xml b/content/api_en/LIB_sound/PinkNoise_stop.xml index 2e0db52be..f9bc7dca5 100755 --- a/content/api_en/LIB_sound/PinkNoise_stop.xml +++ b/content/api_en/LIB_sound/PinkNoise_stop.xml @@ -38,19 +38,4 @@ void mousePressed() { Stops the Pink Noise generator. ]]> - -noise.stop() - - - - - - -1.0 - -Method - -Library - - diff --git a/content/api_en/LIB_sound/Pulse.xml b/content/api_en/LIB_sound/Pulse.xml index 2bae58c81..e1b4402cd 100755 --- a/content/api_en/LIB_sound/Pulse.xml +++ b/content/api_en/LIB_sound/Pulse.xml @@ -9,7 +9,7 @@ Application - +../../../images/LIB_sound_Pulse.png - - - - - - - - -play() -Start the oscillator - - - -stop() -Stop the oscillator - - - -freq() -Change the frequency of the oscillator - - - -width() -Change the pulse width of the oscillator - - - -amp() -Change the amplitude/volume of the oscillator - - - -add() -Offset the output of the oscillator by given value - - - -pan() -Move the sound in a stereo panorama - - - -set() -Set multiple parameters at once - - - -Pulse(parent) - - - -parent -PApplet: typically use "this" - - - - - - - -1.0 - -Object - -Library - diff --git a/content/api_en/LIB_sound/SawOsc.xml b/content/api_en/LIB_sound/SawOsc.xml index 514326e8f..979ca1bb5 100755 --- a/content/api_en/LIB_sound/SawOsc.xml +++ b/content/api_en/LIB_sound/SawOsc.xml @@ -9,7 +9,7 @@ Application - +../../../images/LIB_sound_SawOsc.png - - - - - - - - -play() -Start the oscillator - - - -stop() -Stop the oscillator - - - -freq() -Change the frequency of the oscillator - - - -amp() -Change the amplitude/volume of the oscillator - - - -add() -Offset the output of the oscillator by given value - - - -pan() -Move the sound in a stereo panorama - - - -set() -Set multiple parameters at once - - - -SqrOsc(parent) - - - -parent -PApplet: typically use "this" - - - - - - - -1.0 - -Object - -Library - diff --git a/content/api_en/LIB_sound/SinOsc.xml b/content/api_en/LIB_sound/SinOsc.xml index 1f6c8ad1e..abec47858 100755 --- a/content/api_en/LIB_sound/SinOsc.xml +++ b/content/api_en/LIB_sound/SinOsc.xml @@ -9,7 +9,7 @@ Application - +../../../images/LIB_sound_SinOsc.png - - - - - - - - -play() -Start the oscillator - - - -stop() -Stop the oscillator - - - -freq() -Change the frequency of the oscillator - - - -amp() -Change the amplitude/volume of the oscillator - - - -add() -Offset the output of the oscillator by given value - - - -pan() -Move the sound in a stereo panorama - - - -set() -Set multiple parameters at once - - - -SinOsc(parent) - - - -parent -PApplet: typically use "this" - - - - - - - -1.0 - -Object - -Library - diff --git a/content/api_en/LIB_sound/SinOsc_play.xml b/content/api_en/LIB_sound/SinOsc_play.xml index 31761bad6..4c89cd172 100755 --- a/content/api_en/LIB_sound/SinOsc_play.xml +++ b/content/api_en/LIB_sound/SinOsc_play.xml @@ -13,7 +13,7 @@ + +Sound + +Sound + +Configuration + +Application + + + + + + + + +AudioIn + + + \ No newline at end of file diff --git a/content/api_en/LIB_sound/SoundFile.xml b/content/api_en/LIB_sound/SoundFile.xml index db860e881..c6eb0d03c 100755 --- a/content/api_en/LIB_sound/SoundFile.xml +++ b/content/api_en/LIB_sound/SoundFile.xml @@ -9,7 +9,6 @@ Application - - - - - - - - - -play() -Play the soundfile - - - -loop() -Loop the soundfile - - - -cue() -Set the starting position of the soundfile - - - -jump() -Jump to a specific position in the file while continuing to play - - - -stop() -Stop the soundfile - - - -rate() -Change the playback rate of the soundfile - - - -amp() -Change the amplitude/volume of the player - - - -add() -Offset the output of the player by given value - - - -pan() -Move the soundfile in a stereo panorama - - - -set() -Set multiple parameters at once - - - -duration() -Returns the duration of the soundfile - - - -sampleRate() -Returns the sample rate of the soundfile - - - -frames() -Returns the number of frames/samples of the soundfile - - - -channels() -Returns the number of channels of the soundfile - - - -SoundFile(parent, path) - - - -parent -PApplet: typically use "this" - - - -path -Full Path to file or filename for data path - - - - - - - -1.0 - -Object - -Library - diff --git a/content/api_en/LIB_sound/SoundFile_add.xml b/content/api_en/LIB_sound/SoundFile_add.xml index 28df56508..2b92734e5 100755 --- a/content/api_en/LIB_sound/SoundFile_add.xml +++ b/content/api_en/LIB_sound/SoundFile_add.xml @@ -18,12 +18,12 @@ SoundFile file; void setup() { size(640, 360); background(255); - + // Load a soundfile from the /data folder of the sketch and play it back file = new SoundFile(this, "sample.mp3"); file.play(); file.add(0.1); -} +} void draw() { } @@ -32,7 +32,7 @@ void draw() { diff --git a/content/api_en/LIB_sound/SoundFile_amp.xml b/content/api_en/LIB_sound/SoundFile_amp.xml index 8fed77f35..34002bbd2 100755 --- a/content/api_en/LIB_sound/SoundFile_amp.xml +++ b/content/api_en/LIB_sound/SoundFile_amp.xml @@ -21,8 +21,8 @@ void setup() { // Load a soundfile from the /data folder of the sketch and play it back file = new SoundFile(this, "sample.mp3"); - file.play(); file.amp(0.5); + file.play(); } void draw() { diff --git a/content/api_en/LIB_sound/SoundFile_channels.xml b/content/api_en/LIB_sound/SoundFile_channels.xml index 2e371f9e2..ace503d83 100755 --- a/content/api_en/LIB_sound/SoundFile_channels.xml +++ b/content/api_en/LIB_sound/SoundFile_channels.xml @@ -18,11 +18,11 @@ SoundFile file; void setup() { size(640, 360); background(255); - + // Load a soundfile from the /data folder of the sketch and get the number of channels file = new SoundFile(this, "sample.mp3"); println(file.channels()); -} +} void draw() { } @@ -31,22 +31,7 @@ void draw() { - -file.channels() - - -int - - - -1.0 - -Method - -Library - - diff --git a/content/api_en/LIB_sound/SoundFile_cue.xml b/content/api_en/LIB_sound/SoundFile_cue.xml index 347d45dc4..bded003ce 100755 --- a/content/api_en/LIB_sound/SoundFile_cue.xml +++ b/content/api_en/LIB_sound/SoundFile_cue.xml @@ -21,33 +21,17 @@ void setup() { // Load a soundfile from the /data folder of the sketch and play it back file = new SoundFile(this, "sample.mp3"); - file.cue(15); + file.cue(3.5); file.play(); } void draw() { } - ]]> second parameter supports only integer values. +Cues the playhead to a fixed position in the soundfile. Note that cue() only affects the playhead for future calls to play(), but not to loop(). ]]> - -file.cue(second) - - - - - - -1.0 - -Method - -Library - - diff --git a/content/api_en/LIB_sound/SoundFile_duration.xml b/content/api_en/LIB_sound/SoundFile_duration.xml index ca9e0e073..969d68a02 100755 --- a/content/api_en/LIB_sound/SoundFile_duration.xml +++ b/content/api_en/LIB_sound/SoundFile_duration.xml @@ -21,32 +21,16 @@ void setup() { // Load a soundfile from the data folder of the sketch and get the duration of the file file = new SoundFile(this, "sample.mp3"); - println("SFDuration= " + file.duration() + " seconds"); + println("Duration= " + file.duration() + " seconds"); } void draw() { } - ]]> - -file.duration() - - -float - - - -1.0 - -Method - -Library - - diff --git a/content/api_en/LIB_sound/SoundFile_frames.xml b/content/api_en/LIB_sound/SoundFile_frames.xml index eb464331f..f4a66de1a 100755 --- a/content/api_en/LIB_sound/SoundFile_frames.xml +++ b/content/api_en/LIB_sound/SoundFile_frames.xml @@ -18,10 +18,10 @@ SoundFile file; void setup() { size(640, 360); background(255); - + // Load a soundfile from the data folder of the sketch and get the number of frames file = new SoundFile(this, "sample.mp3"); - println("SFSamples= " + file.frames() + " samples"); + println("Frames= " + file.frames() + " frames"); } void draw() { @@ -31,22 +31,7 @@ void draw() { - -file.frames() - - -int - - - -1.0 - -Method - -Library - - diff --git a/content/api_en/LIB_sound/SoundFile_isPlaying.xml b/content/api_en/LIB_sound/SoundFile_isPlaying.xml new file mode 100755 index 000000000..fb5ec3082 --- /dev/null +++ b/content/api_en/LIB_sound/SoundFile_isPlaying.xml @@ -0,0 +1,45 @@ + + + +isPlaying() + +Sound Files + + + +Web & Application + + + + + + + + + diff --git a/content/api_en/LIB_sound/SoundFile_jump.xml b/content/api_en/LIB_sound/SoundFile_jump.xml index caa6a01a9..23bb57fa1 100755 --- a/content/api_en/LIB_sound/SoundFile_jump.xml +++ b/content/api_en/LIB_sound/SoundFile_jump.xml @@ -21,32 +21,16 @@ void setup() { // Load a soundfile from the /data folder of the sketch and play it back file = new SoundFile(this, "sample.mp3"); - file.jump(15.3); + file.jump(3.5); } void draw() { } - ]]> - -file.jump(second) - - - - - - -1.0 - -Method - -Library - - diff --git a/content/api_en/LIB_sound/SoundFile_loop.xml b/content/api_en/LIB_sound/SoundFile_loop.xml index d66e81a83..8f42ae4d9 100755 --- a/content/api_en/LIB_sound/SoundFile_loop.xml +++ b/content/api_en/LIB_sound/SoundFile_loop.xml @@ -31,7 +31,7 @@ void draw() { diff --git a/content/api_en/LIB_sound/SoundFile_pan.xml b/content/api_en/LIB_sound/SoundFile_pan.xml index 52fc29f6b..44e6f2746 100755 --- a/content/api_en/LIB_sound/SoundFile_pan.xml +++ b/content/api_en/LIB_sound/SoundFile_pan.xml @@ -19,7 +19,7 @@ void setup() { size(640, 360); background(255); - // Load a soundfile from the data folder of the sketch and play it back + // Load a MONO soundfile from the data folder of the sketch and play it back file = new SoundFile(this, "sample.mp3"); file.play(); } @@ -32,22 +32,7 @@ void draw() { - -file.pan() - - - - - - -1.0 - -Method - -Library - - diff --git a/content/api_en/LIB_sound/SoundFile_sampleRate.xml b/content/api_en/LIB_sound/SoundFile_pause.xml similarity index 52% rename from content/api_en/LIB_sound/SoundFile_sampleRate.xml rename to content/api_en/LIB_sound/SoundFile_pause.xml index 38e25aff2..abfe629ae 100755 --- a/content/api_en/LIB_sound/SoundFile_sampleRate.xml +++ b/content/api_en/LIB_sound/SoundFile_pause.xml @@ -1,7 +1,7 @@ -sampleRate() +pause() Sound Files @@ -18,35 +18,27 @@ SoundFile file; void setup() { size(640, 360); background(255); - - // Load a soundfile from the data folder of the sketch and get the sample rate + + // Load a soundfile from the /data folder of the sketch and play it back file = new SoundFile(this, "sample.mp3"); - println("SFSampleRate= " + file.sampleRate() + " Hz"); -} + file.play(); +} void draw() { } +void mousePressed() { + if (file.isPlaying()) { + file.pause(); + } else { + file.play(); + } +} ]]> - -file.sampleRate() - - -int - - - -1.0 - -Method - -Library - - diff --git a/content/api_en/LIB_sound/SoundFile_play.xml b/content/api_en/LIB_sound/SoundFile_play.xml index 95f493497..f3bb129ef 100755 --- a/content/api_en/LIB_sound/SoundFile_play.xml +++ b/content/api_en/LIB_sound/SoundFile_play.xml @@ -22,31 +22,15 @@ void setup() { // Load a soundfile from the /data folder of the sketch and play it back file = new SoundFile(this, "sample.mp3"); file.play(); -} +} void draw() { } - ]]> - -file.play() - - - - - - -1.0 - -Method - -Library - - diff --git a/content/api_en/LIB_sound/SoundFile_rate.xml b/content/api_en/LIB_sound/SoundFile_rate.xml index 48ef77737..953ca579d 100755 --- a/content/api_en/LIB_sound/SoundFile_rate.xml +++ b/content/api_en/LIB_sound/SoundFile_rate.xml @@ -21,34 +21,17 @@ void setup() { // Load a soundfile from the data folder of the sketch and play it back double the speed file = new SoundFile(this, "sample.mp3"); - file.play(); + file.loop(); file.rate(2); } void draw() { } - ]]> - -file.rate() - - - - - - -1.0 - -Method - -Library - - diff --git a/content/api_en/LIB_sound/SoundFile_set.xml b/content/api_en/LIB_sound/SoundFile_set.xml index e0b029462..b9f42ee74 100755 --- a/content/api_en/LIB_sound/SoundFile_set.xml +++ b/content/api_en/LIB_sound/SoundFile_set.xml @@ -19,27 +19,26 @@ void setup() { size(640, 360); background(255); - // Load a soundfile from the data folder of the sketch and get the number of channels + // Load a soundfile from the data folder of the sketch file = new SoundFile(this, "sample.mp3"); - println("SFSampleRate= " + file.sampleRate() + " Hz"); } void draw() { } void mousePressed() { - float rate=3; - float pos=0.5; - float amp=0.5; - float add=0; - file.set(rate, amp, add, pos); + float rate = 3; + float pos = 0.5; + float amp = 0.5; + float add = 0; + file.set(rate, pos, amp, add); } ]]> diff --git a/content/api_en/LIB_sound/SoundFile_stop.xml b/content/api_en/LIB_sound/SoundFile_stop.xml index d8648eda5..d4b3830e7 100755 --- a/content/api_en/LIB_sound/SoundFile_stop.xml +++ b/content/api_en/LIB_sound/SoundFile_stop.xml @@ -15,26 +15,26 @@ import processing.sound.*; SoundFile file; - void setup() { +void setup() { size(640, 360); background(255); - + // Load a soundfile from the /data folder of the sketch and play it back file = new SoundFile(this, "sample.mp3"); file.play(); - } +} - void(){ - } - - void mousePressed() { +void draw() { +} + +void mousePressed() { file.stop(); - } +} ]]> diff --git a/content/api_en/LIB_sound/Sound_inputDevice.xml b/content/api_en/LIB_sound/Sound_inputDevice.xml new file mode 100755 index 000000000..e09498aac --- /dev/null +++ b/content/api_en/LIB_sound/Sound_inputDevice.xml @@ -0,0 +1,36 @@ + + + +inputDevice() + +Sound + +Configuration + +Web & Application + + + + + + + + + +AudioIn + + + diff --git a/content/api_en/LIB_sound/Sound_list.xml b/content/api_en/LIB_sound/Sound_list.xml new file mode 100755 index 000000000..80644eb01 --- /dev/null +++ b/content/api_en/LIB_sound/Sound_list.xml @@ -0,0 +1,28 @@ + + + +Sound.list() + +Sound + +Configuration + +Web & Application + + + + + + + + + diff --git a/content/api_en/LIB_sound/Sound_outputDevice.xml b/content/api_en/LIB_sound/Sound_outputDevice.xml new file mode 100755 index 000000000..3f26b40eb --- /dev/null +++ b/content/api_en/LIB_sound/Sound_outputDevice.xml @@ -0,0 +1,33 @@ + + + +outputDevice() + +Sound + +Configuration + +Web & Application + + + + + + + + + +AudioIn + + + diff --git a/content/api_en/LIB_sound/Sound_sampleRate.xml b/content/api_en/LIB_sound/Sound_sampleRate.xml new file mode 100755 index 000000000..0e37ce728 --- /dev/null +++ b/content/api_en/LIB_sound/Sound_sampleRate.xml @@ -0,0 +1,31 @@ + + +sampleRate() + +Sound + +Configuration + +Application + + + + + + + + + diff --git a/content/api_en/LIB_sound/Sound_volume.xml b/content/api_en/LIB_sound/Sound_volume.xml new file mode 100755 index 000000000..96d9e6700 --- /dev/null +++ b/content/api_en/LIB_sound/Sound_volume.xml @@ -0,0 +1,46 @@ + + + +volume() + +Sound + +Configuration + +Web & Application + + + + + + + + + diff --git a/content/api_en/LIB_sound/SqrOsc.xml b/content/api_en/LIB_sound/SqrOsc.xml index d1d0c096f..f4ff7ec2f 100755 --- a/content/api_en/LIB_sound/SqrOsc.xml +++ b/content/api_en/LIB_sound/SqrOsc.xml @@ -9,7 +9,7 @@ Application - +../../../images/LIB_sound_SqrOsc.png - - - - - - - - -play() -Start the oscillator - - - -stop() -Stop the oscillator - - - -freq() -Change the frequency of the oscillator - - - -amp() -Change the amplitude/volume of the oscillator - - - -add() -Offset the output of the oscillator by given value - - - -pan() -Move the sound in a stereo panorama - - - -set() -Set multiple parameters at once - - - -SqrOsc(parent) - - - -parent -PApplet: typically use "this" - - - - - - - -1.0 - -Object - -Library - diff --git a/content/api_en/LIB_sound/TriOsc.xml b/content/api_en/LIB_sound/TriOsc.xml index 2ca49c832..d504de89a 100755 --- a/content/api_en/LIB_sound/TriOsc.xml +++ b/content/api_en/LIB_sound/TriOsc.xml @@ -9,7 +9,7 @@ Application - +../../../images/LIB_sound_TriOsc.png - - - - - - - - -play() -Start the oscillator - - - -stop() -Stop the oscillator - - - -freq() -Change the frequency of the oscillator - - - -amp() -Change the amplitude/volume of the oscillator - - - -add() -Offset the output of the oscillator by given value - - - -pan() -Move the sound in a stereo panorama - - - -set() -Set multiple parameters at once - - - -TriOsc(parent) - - - -parent -PApplet: typically use "this" - - - - - - - -1.0 - -Object - -Library - diff --git a/content/api_en/LIB_sound/Waveform.xml b/content/api_en/LIB_sound/Waveform.xml new file mode 100644 index 000000000..4251ddd60 --- /dev/null +++ b/content/api_en/LIB_sound/Waveform.xml @@ -0,0 +1,107 @@ + + + +Waveform + +Sound + +Analyzer + +Application + + + + + + + + + + + + + + + + +input() +Define the audio input for the analyzer + + + +analyze() +Gets the last nsamples captured from the connected input sound source, writes them + into this Waveform's `data` array, and returns it. + + + +stop() +Stop the analyzer + + + +data +`float[]` of length nsamples, with the sample amplitudes between `-1` and `1` + + + +Waveform(parent) + + + +parent +PApplet: typically use "this" + + + + + + + +Object + +Library + + diff --git a/content/api_en/LIB_sound/WhiteNoise.xml b/content/api_en/LIB_sound/WhiteNoise.xml index 0f67dfb46..ba8d252c2 100755 --- a/content/api_en/LIB_sound/WhiteNoise.xml +++ b/content/api_en/LIB_sound/WhiteNoise.xml @@ -29,66 +29,7 @@ void draw() { - - - - - - - - -play() -Start the generator - - - -stop() -Stop the generator - - - -amp() -Change the amplitude/volume of the generator - - - -add() -Offset the output of the generator by given value - - - -pan() -Move the sound in a stereo panorama - - - -set() -Set multiple parameters at once - - - -WhiteNoise(parent) - - - -parent -PApplet: typically use "this" - - - - - - - -1.0 - -Object - -Library - diff --git a/content/api_en/LIB_sound/WhiteNoise_add.xml b/content/api_en/LIB_sound/WhiteNoise_add.xml index 1876dc1ab..a6da5916b 100755 --- a/content/api_en/LIB_sound/WhiteNoise_add.xml +++ b/content/api_en/LIB_sound/WhiteNoise_add.xml @@ -34,19 +34,4 @@ void draw() { The .add() method is useful for modulating other audio signals. ]]> - -noise.add(add) - - - - - - -1.0 - -Method - -Library - - diff --git a/content/api_en/LIB_sound/WhiteNoise_amp.xml b/content/api_en/LIB_sound/WhiteNoise_amp.xml index 98ea36777..83eef598a 100755 --- a/content/api_en/LIB_sound/WhiteNoise_amp.xml +++ b/content/api_en/LIB_sound/WhiteNoise_amp.xml @@ -35,24 +35,4 @@ void draw() { Changes the amplitude/volume of the noise generator. Allowed values are between 0.0 and 1.0. ]]> - -noise.amp(vol) - - - - - - - - - - - -1.0 - -Method - -Library - - diff --git a/content/api_en/LIB_sound/WhiteNoise_pan.xml b/content/api_en/LIB_sound/WhiteNoise_pan.xml index 3bcfab0ec..ffb68b7cf 100755 --- a/content/api_en/LIB_sound/WhiteNoise_pan.xml +++ b/content/api_en/LIB_sound/WhiteNoise_pan.xml @@ -36,19 +36,4 @@ void draw() { Pan the generator in a stereo panorama. -1.0 pans to the left channel and 1.0 to the right channel. ]]> - -noise.pan(pos) - - - - - - -1.0 - -Method - -Library - - diff --git a/content/api_en/LIB_sound/WhiteNoise_play.xml b/content/api_en/LIB_sound/WhiteNoise_play.xml index c25d29486..9dd12d80d 100755 --- a/content/api_en/LIB_sound/WhiteNoise_play.xml +++ b/content/api_en/LIB_sound/WhiteNoise_play.xml @@ -34,19 +34,4 @@ void draw() { Starts the White Noise generator. ]]> - -noise.play() - - - - - - -1.0 - -Method - -Library - - diff --git a/content/api_en/LIB_sound/WhiteNoise_set.xml b/content/api_en/LIB_sound/WhiteNoise_set.xml index a4d965129..6ecf74ca1 100755 --- a/content/api_en/LIB_sound/WhiteNoise_set.xml +++ b/content/api_en/LIB_sound/WhiteNoise_set.xml @@ -41,19 +41,4 @@ void mousePressed() { Sets amplitude, add and pan position with one method. ]]> - -noise.set(amp, add, pos) - - - - - - -1.0 - -Method - -Library - - diff --git a/content/api_en/LIB_sound/WhiteNoise_stop.xml b/content/api_en/LIB_sound/WhiteNoise_stop.xml index a5b932fd8..783fa8a36 100755 --- a/content/api_en/LIB_sound/WhiteNoise_stop.xml +++ b/content/api_en/LIB_sound/WhiteNoise_stop.xml @@ -38,19 +38,4 @@ void mousePressed() { Stops the White Noise generator. ]]> - -noise.stop() - - - - - - -1.0 - -Method - -Library - - diff --git a/content/api_en/LIB_sound/index.html b/content/api_en/LIB_sound/index.html index 007b42f79..5bee0974e 100755 --- a/content/api_en/LIB_sound/index.html +++ b/content/api_en/LIB_sound/index.html @@ -1,71 +1,75 @@ - -

Sound

- -
-

- The new Sound library for Processing 3 provides a simple way to work with audio. It can play, analyze, and synthesize sound. The library comes with a collection of oscillators for basic wave forms, a variety of noise generators, and effects and filters to alter sound files and other generated sounds. The syntax is minimal to make it easy to patch one sound object into another. -

-

- The source code is available on the processing-sound GitHub repository. Please report bugs here. This library is only compatible with Processing 3.0+. -

- -
- -
-

- - I/O -

- AudioDevice
- AudioIn
-

- - Audio Files - -

- SoundFile
-

- - Effects - -

- LowPass
- HighPass
- BandPass
- Delay
- Reverb
-

- - Analysis -

- Amplitude
- FFT
-

- -

-
- -
-

- Noise -

- WhiteNoise
- PinkNoise
- BrownNoise
-

- - Oscillators -

- SinOsc
- SawOsc
- SqrOsc
- TriOsc
- Pulse
-

- - Envelopes -

- Env
-

-

-
+ +

Sound

+ +
+

+ The new Sound library for Processing 3 provides a simple way to work with audio. It can play, analyze, and synthesize sound. It provides a collection of oscillators for basic wave forms, a variety of noise generators, and effects and filters to play and alter sound files and other generated sounds. The syntax is minimal to make it easy to patch one sound object into another. The library also comes with example sketches covering many use cases to help you get started. +

+

+ The source code is available on the processing-sound GitHub repository. Please report bugs here. This library is only compatible with Processing 3.0+. +

+ +
+ +
+

+ + Configuration +

+ Sound
+

+ + I/O +

+ AudioIn
+

+ + Sampling +

+ SoundFile
+ AudioSample
+

+ + Effects + +

+ LowPass
+ HighPass
+ BandPass
+ Delay
+ Reverb
+

+ +

+
+ +
+

+ Noise +

+ WhiteNoise
+ PinkNoise
+ BrownNoise
+

+ + Oscillators +

+ SinOsc
+ SawOsc
+ SqrOsc
+ TriOsc
+ Pulse
+

+ + Envelopes +

+ Env
+

+ + Analysis +

+ Amplitude
+ FFT
+

+

+
diff --git a/content/api_en/LIB_svg/index.html b/content/api_en/LIB_svg/index.html new file mode 100644 index 000000000..24737df1d --- /dev/null +++ b/content/api_en/LIB_svg/index.html @@ -0,0 +1,167 @@ + +

SVG Export

+ +
+

The SVG library makes it possible to write SVG files directly from Processing. These vector graphics files can be scaled to any size and output at very high resolutions. The SVG library can flatten 3D data into a 2D vector file, but to export 3D data, use the DXF library. The source code is available on the Processing GitHub repository. Please report bugs here.
+
+ This library can be used with the core Processing function size(), or createGraphics(). See the examples below for different techniques.

+
+ +
+

+SVG Export (No Screen Display)
+
+This example draws a single frame to a SVG file and quits. (Note that no display window will open; this helps when you're trying to create massive SVG images that are far larger than the screen size.)

+ +
import processing.svg.*;
+
+void setup() {
+  size(400, 400, SVG, "filename.svg");
+}
+
+void draw() {
+  // Draw something good here
+  line(0, 0, width/2, height);
+
+  // Exit the program
+  println("Finished.");
+  exit();
+}
+ + +

SVG Export (With Screen Display)
+
+To draw to the screen while also saving an SVG beginRecord() +and endRecord() functions. Unlike the PDF renderer, the SVG renderer will only save the final frame of a sequence. This is slower, but is useful when you need to +see what you're working on as it saves.

+ +
import processing.svg.*;
+
+void setup() {
+  size(400, 400);
+  noLoop();
+  beginRecord(SVG, "filename.svg");
+}
+
+void draw() {
+  // Draw something good here
+  line(0, 0, width/2, height);
+
+  endRecord();
+}
+ + +

Single Frame from an Animation (With Screen Display)
+It's also possible to save one frame from a program with moving elements. +Create a boolean variable to turn the SVG recording process on and off

+ +
import processing.svg.*;
+
+boolean record;
+
+void setup() {
+  size(400, 400);
+}
+
+void draw() {
+  if (record) {
+    // Note that #### will be replaced with the frame number. Fancy!
+    beginRecord(SVG, "frame-####.svg");
+  }
+
+  // Draw something good here
+  background(255);
+  line(mouseX, mouseY, width/2, height/2);
+
+  if (record) {
+    endRecord();
+	record = false;
+  }
+}
+
+// Use a keypress so thousands of files aren't created
+void mousePressed() {
+  record = true;
+}
+ + +

SVG Files from 3D Geometry (With Screen Display)
+
+To create vectors from 3D data, use the beginRaw() and endRaw() commands. +These commands will grab the shape data just before it is rendered to the screen. +At this stage, your entire scene is nothing but a long list of lines and triangles. +This means that a shape created with sphere() method will be made up of hundreds of +triangles, rather than a single object.

+ +

When using beginRaw() and endRaw(), it's possible to write to either a 2D or 3D renderer. +For instance, beginRaw() with the SVG library will write the geometry as flattened triangles +and lines.

+ +
import processing.svg.*;
+
+boolean record;
+
+void setup() {
+  size(500, 500, P3D);
+}
+
+void draw() {
+  if (record) {
+    beginRaw(SVG, "output.svg");
+  }
+
+  // Do all your drawing here
+  background(204);
+  translate(width/2, height/2, -200);
+  rotateZ(0.2);
+  rotateY(mouseX/500.0);
+  box(200);
+
+  if (record) {
+    endRaw();
+    record = false;
+  }
+}
+
+// Hit 'r' to record a single frame
+void keyPressed() {
+  if (key == 'r') {
+    record = true;
+  }
+}
+
+ +

Using createGraphics() to Create an SVG File
+
+To write a SVG file using only the createGraphics() command, rather than as +part of a sketch, it's necessary to call dispose() on the PGraphicsSVG object. +This is the same as calling exit(), but it won't quit the sketch.

+ +
import processing.svg.*;
+
+PGraphics svg = createGraphics(300, 300, SVG, "output.svg");
+svg.beginDraw();
+svg.background(128, 0, 0);
+svg.line(50, 50, 250, 250);
+svg.dispose();
+svg.endDraw();
+ + +

+Additional notes for the SVG renderer: + +

    + +
  • If you want 3D data, use the DXF recording library instead. + +
  • Using hint(ENABLE_DEPTH_SORT) can improve the appearance of 3D geometry drawn to 2D file formats. + +
  • Many methods, particularly pixel-based methods, don't make sense for SVG renderers. This includes: loadPixels, updatePixels, get, set, mask, filter, copy, blend, save, and image + +
  • Again, exit() is really important when using SVG with size(). + +
+ +

+ +
diff --git a/content/api_en/PImage_filter.xml b/content/api_en/PImage_filter.xml index 30df9a9da..f30582ad1 100755 --- a/content/api_en/PImage_filter.xml +++ b/content/api_en/PImage_filter.xml @@ -156,7 +156,7 @@ POSTERIZE
Limits each channel of the image to the number of colors specified as the parameter. The parameter can be set to values between 2 and 255, but results are most noticeable in the lower ranges.

BLUR
-Executes a Guassian blur with the level parameter specifying the extent of the blurring. If no parameter is used, the blur is equivalent to Guassian blur of radius 1. Larger values increase the blur.
+Executes a Gaussian blur with the level parameter specifying the extent of the blurring. If no parameter is used, the blur is equivalent to Gaussian blur of radius 1. Larger values increase the blur.

ERODE
Reduces the light areas. No parameter is used.
diff --git a/content/api_en/PImage_loadPixels.xml b/content/api_en/PImage_loadPixels.xml index 23c5f9730..a9c353f84 100644 --- a/content/api_en/PImage_loadPixels.xml +++ b/content/api_en/PImage_loadPixels.xml @@ -34,8 +34,6 @@ void draw() { pixels[] array. This function must always be called before reading from or writing to pixels[]. -

-Certain renderers may or may not seem to require loadPixels() or updatePixels(). However, the rule is that any time you want to manipulate the pixels[] array, you must have previously called loadPixels(), and after changes have been made, call updatePixels(). Even if the renderer may not seem to use this function in the current Processing release, this will always be subject to change. ]]>
diff --git a/content/api_en/PImage_pixels.xml b/content/api_en/PImage_pixels.xml index 68203cae0..1f2a363e2 100755 --- a/content/api_en/PImage_pixels.xml +++ b/content/api_en/PImage_pixels.xml @@ -31,7 +31,7 @@ void draw() {
+The pixels[] array contains the values for all the pixels in the image. These values are of the color datatype. This array is the size of the image, meaning if the image is 100 x 100 pixels, there will be 10,000 values and if the window is 200 x 300 pixels, there will be 60,000 values.

Before accessing this array, the data must loaded with the loadPixels() method. Failure to do so may result in a NullPointerException. After the array data has been modified, the updatePixels() method must be run to update the content of the display window. ]]>
diff --git a/content/api_en/PImage_save.xml b/content/api_en/PImage_save.xml index d485f5cc8..0c6830b00 100755 --- a/content/api_en/PImage_save.xml +++ b/content/api_en/PImage_save.xml @@ -29,7 +29,7 @@ newImage.save("outputImage.jpg"); filename parameter. For example, "image.tif" will have a TIFF image and "image.png" will save a PNG image. If no extension is included in the filename, the image will save in TIFF format and .tif will be added to the name. These files are saved to the sketch's folder, which may be opened by selecting "Show sketch folder" from the "Sketch" menu. It is not possible to use save() while running the program in a web browser.

To save an image created within the code, rather than through loading, it's necessary to make the image with the createImage() function so it is aware of the location of the program and can therefore save the file to the right place. See the createImage() reference for more information. +Saves the image into a file. Append a file extension to the name of the file, to indicate the file format to be used: either TIFF (.tif), TARGA (.tga), JPEG (.jpg), or PNG (.png). If no extension is included in the filename, the image will save in TIFF format and .tif will be added to the name. These files are saved to the sketch's folder, which may be opened by selecting "Show sketch folder" from the "Sketch" menu.

To save an image created within the code, rather than through loading, it's necessary to make the image with the createImage() function so it is aware of the location of the program and can therefore save the file to the right place. See the createImage() reference for more information. ]]>
diff --git a/content/api_en/PImage_updatePixels.xml b/content/api_en/PImage_updatePixels.xml index 7e713fffd..470c33d07 100644 --- a/content/api_en/PImage_updatePixels.xml +++ b/content/api_en/PImage_updatePixels.xml @@ -34,10 +34,6 @@ void draw() { pixels[] array. Use in conjunction with loadPixels(). If you're only reading pixels from the array, there's no need to call updatePixels(). -

-Certain renderers may or may not seem to require loadPixels() or updatePixels(). However, the rule is that any time you want to manipulate the pixels[] array, you must first call loadPixels(), and after changes have been made, call updatePixels(). Even if the renderer may not seem to use this function in the current Processing release, this will always be subject to change. -

-Currently, none of the renderers use the additional parameters to updatePixels(), however this may be implemented in the future. ]]>
diff --git a/content/api_en/PShape_addChild.xml b/content/api_en/PShape_addChild.xml index 3d69836a8..36dcc867a 100644 --- a/content/api_en/PShape_addChild.xml +++ b/content/api_en/PShape_addChild.xml @@ -11,13 +11,13 @@ path, rectangle, and circle are added to a parent PShape variable named house that is a GROUP. ]]> diff --git a/content/api_en/PShape_beginContour.xml b/content/api_en/PShape_beginContour.xml index fefc7d7d1..510cf16f1 100644 --- a/content/api_en/PShape_beginContour.xml +++ b/content/api_en/PShape_beginContour.xml @@ -14,12 +14,12 @@ PShape s; void setup() { - size(100, 100); + size(200, 200, P2D); // Make a shape s = createShape(); s.beginShape(); - s.noStroke(); + //s.noStroke(); // Exterior part of shape s.vertex(-50,-50); @@ -36,11 +36,11 @@ void setup() { s.endContour(); // Finish off shape - s.endShape(); + s.endShape(CLOSE); } void draw() { - background(52); + background(204); translate(width/2, height/2); s.rotate(0.01); shape(s); diff --git a/content/api_en/PShape_endContour.xml b/content/api_en/PShape_endContour.xml index b88cd4c3f..43119b0ea 100644 --- a/content/api_en/PShape_endContour.xml +++ b/content/api_en/PShape_endContour.xml @@ -14,12 +14,12 @@ PShape s; void setup() { - size(100, 100); + size(200, 200, P2D); // Make a shape s = createShape(); s.beginShape(); - s.noStroke(); + //s.noStroke(); // Exterior part of shape s.vertex(-50,-50); @@ -36,11 +36,11 @@ void setup() { s.endContour(); // Finish off shape - s.endShape(); + s.endShape(CLOSE); } void draw() { - background(52); + background(204); translate(width/2, height/2); s.rotate(0.01); shape(s); diff --git a/content/api_en/StringList_hasValue.xml b/content/api_en/StringList_hasValue.xml index 764dfa9d9..c864feb07 100755 --- a/content/api_en/StringList_hasValue.xml +++ b/content/api_en/StringList_hasValue.xml @@ -21,8 +21,8 @@ void setup() { inventory.append("flour"); inventory.append("tea"); println(inventory); - if (inventory.hasValue("tea") == true) { - println("Yes, we have a tea"); + if (inventory.hasValue("tea")) { + println("Yes, we have tea"); } else { println("Sorry, no tea"); } diff --git a/content/api_en/ambientLight.xml b/content/api_en/ambientLight.xml index 8f2ed792f..029c8dcf4 100755 --- a/content/api_en/ambientLight.xml +++ b/content/api_en/ambientLight.xml @@ -41,7 +41,7 @@ sphere(30); draw() to remain persistent in a looping program. Placing them in the setup() of a looping program will cause them to only have an effect the first time through the loop. The v1, v2, and v3 parameters are interpreted as either RGB or HSB values, depending on the current color mode. +Adds an ambient light. Ambient light doesn't come from a specific direction, the rays of light have bounced around so much that objects are evenly lit from all sides. Ambient lights are almost always used in combination with other types of lights. Lights need to be included in the draw() to remain persistent in a looping program. Placing them in the setup() of a looping program will cause them to only have an effect the first time through the loop. The v1, v2, and v3 parameters are interpreted as either RGB or HSB values, depending on the current color mode. ]]> diff --git a/content/api_en/append.xml b/content/api_en/append.xml index d9fc3aecc..fea9cc952 100755 --- a/content/api_en/append.xml +++ b/content/api_en/append.xml @@ -23,7 +23,7 @@ println(sa2); element parameter must be the same as the datatype of the array.
+Expands a one-dimensional array by one element and adds data to the new position. The datatype of the element parameter must be the same as the datatype of the array.

When using an array of objects, the data returned from the function must be cast to the object array's data type. For example: SomeClass[] items = (SomeClass[]) append(originalArray, element) ]]>
diff --git a/content/api_en/arc.xml b/content/api_en/arc.xml index 742e7391f..071891848 100755 --- a/content/api_en/arc.xml +++ b/content/api_en/arc.xml @@ -37,10 +37,10 @@ arc(50, 50, 80, 80, 0, PI+QUARTER_PI, PIE); a, b, c, and d parameters. The origin of the arc's ellipse may be changed with the ellipseMode() function. Use the start and stop parameters to specify the angles (in radians) at which to draw the arc.
-
-There are three ways to draw an arc; the rendering technique used is defined by the optional seventh parameter. The three options, depicted in the above examples, are PIE, OPEN, and CHORD. The default mode is the OPEN stroke with a PIE fill.
-
+Draws an arc to the screen. Arcs are drawn along the outer edge of an ellipse defined by the a, b, c, and d parameters. The origin of the arc's ellipse may be changed with the ellipseMode() function. Use the start and stop parameters to specify the angles (in radians) at which to draw the arc. The start/stop values must be in clockwise order. +

+There are three ways to draw an arc; the rendering technique used is defined by the optional seventh parameter. The three options, depicted in the above examples, are PIE, OPEN, and CHORD. The default mode is the OPEN stroke with a PIE fill. +

In some cases, the arc() function isn't accurate enough for smooth drawing. For example, the shape may jitter on screen when rotating slowly. If you're having an issue with how arcs are rendered, you'll need to draw the arc yourself with beginShape()/endShape() or a PShape. ]]>
diff --git a/content/api_en/arrayCopy.xml b/content/api_en/arrayCopy.xml index 1d0d41ef7..1b5165a10 100644 --- a/content/api_en/arrayCopy.xml +++ b/content/api_en/arrayCopy.xml @@ -41,7 +41,7 @@ Copies an array (or part of an array) to another array. The src array is
The simplified version with only two arguments — arrayCopy(src, dst) — copies an entire array to another of the same size. It is equivalent to arrayCopy(src, 0, dst, 0, src.length).

-Using this function is far more efficient for copying array data than iterating through a for() loop and copying each element individually. This function only copies references, which means that for most purposes it only copies one-dimensional arrays (a single set of brackets). If used with a two (or three or more) dimensional array, it will only copy the references at the first level, because a two dimensional array is simply an "array of arrays". This does not produce an error, however, because this is often the desired behavior. Internally, this function calls Java's System.arraycopy() method, so most things that apply there are inherited. +Using this function is far more efficient for copying array data than iterating through a for() loop and copying each element individually. This function only copies references, which means that for most purposes it only copies one-dimensional arrays (a single set of brackets). If used with a two (or three or more) dimensional array, it will only copy the references at the first level, because a two dimensional array is simply an "array of arrays". This does not produce an error, however, because this is often the desired behavior. Internally, this function calls Java's System.arraycopy() method, so most things that apply there are inherited. ]]> diff --git a/content/api_en/attrib.xml b/content/api_en/attrib.xml new file mode 100644 index 000000000..3d21bc538 --- /dev/null +++ b/content/api_en/attrib.xml @@ -0,0 +1,63 @@ + + + +attrib() + +Rendering + + + + + + + + + + +attrib() function attaches custom values to each vertex in the scene. By default, Processing handles several per-vertex attributes: position, color, normal, texture coordinates, etc. These attributes are used by the renderer to determine how the geometry will look on the screen as result of applying the built-in shaders that compute texture, lighting, etc. However, if the coder sets a custom shader that does some additional rendering calculations, then she might need to pass additional information to the the shader in the form of custom attributes. These attributes can be of three types: position, normal, color, and other. The first three are meant to specify xyz coordinates, normal coordinates, and color components, respectively. The third type can be use to pass any kind of attribute value. +]]> + + diff --git a/content/api_en/blend.xml b/content/api_en/blend.xml index d10a95f76..59d8431c9 100755 --- a/content/api_en/blend.xml +++ b/content/api_en/blend.xml @@ -52,15 +52,15 @@ blend(img, 0, 0, 33, 100, 67, 0, 33, 100, LIGHTEST);
-BLEND - linear interpolation of colours: C = A*factor + B
+BLEND - linear interpolation of colors: C = A*factor + B

ADD - additive blending with white clip: C = min(A*factor + B, 255)

SUBTRACT - subtractive blending with black clip: C = max(B - A*factor, 0)

-DARKEST - only the darkest colour succeeds: C = min(A*factor, B)
+DARKEST - only the darkest color succeeds: C = min(A*factor, B)

-LIGHTEST - only the lightest colour succeeds: C = max(A*factor, B)
+LIGHTEST - only the lightest color succeeds: C = max(A*factor, B)

DIFFERENCE - subtract colors from underlying image.

diff --git a/content/api_en/blendMode.xml b/content/api_en/blendMode.xml index 26e3285a2..a3c309cb1 100755 --- a/content/api_en/blendMode.xml +++ b/content/api_en/blendMode.xml @@ -35,17 +35,17 @@ line(75, 25, 25, 75); +Blends the pixels in the display window according to a defined mode. There is a choice of the following modes to blend the source pixels (A) with the ones of pixels already in the display window (B). Each pixel's final color is the result of applying one of the blend modes with each channel of (A) and (B) independently. The red channel is compared with red, green with green, and blue with blue.

-BLEND - linear interpolation of colours: C = A*factor + B. This is the default blending mode.
+BLEND - linear interpolation of colors: C = A*factor + B. This is the default.

ADD - additive blending with white clip: C = min(A*factor + B, 255)

SUBTRACT - subtractive blending with black clip: C = max(B - A*factor, 0)

-DARKEST - only the darkest colour succeeds: C = min(A*factor, B)
+DARKEST - only the darkest color succeeds: C = min(A*factor, B)

-LIGHTEST - only the lightest colour succeeds: C = max(A*factor, B)
+LIGHTEST - only the lightest color succeeds: C = max(A*factor, B)

DIFFERENCE - subtract colors from underlying image.

diff --git a/content/api_en/circle.xml b/content/api_en/circle.xml new file mode 100755 index 000000000..0e1d9adfb --- /dev/null +++ b/content/api_en/circle.xml @@ -0,0 +1,23 @@ + + +circle() + +Shape + +2D Primitives + + + + +ellipse_.png + + + +ellipseMode() function. +]]> + + + diff --git a/content/api_en/clear.xml b/content/api_en/clear.xml index d71f240d8..4db47b198 100644 --- a/content/api_en/clear.xml +++ b/content/api_en/clear.xml @@ -15,23 +15,25 @@ PGraphics pg; void setup() { size(200, 200); - pg = createGraphics(100, 100); + pg = createGraphics(width, height); } void draw() { background(204); - pg.beginDraw(); - pg.stroke(0, 102, 153); - pg.line(0, 0, mouseX, mouseY); - pg.endDraw(); - image(pg, 50, 50); -} - -// Click to clear the PGraphics object -void mousePressed() { - pg.beginDraw(); - pg.clear(); - pg.endDraw(); + + // Clear the PGraphics when the mouse is pressed + if (mousePressed == true) { + pg.beginDraw(); + pg.clear(); + pg.endDraw(); + } else { + pg.beginDraw(); + pg.stroke(0, 102, 153); + pg.line(width/2, height/2, mouseX, mouseY); + pg.endDraw(); + } + + image(pg, 0, 0); } ]]>
diff --git a/content/api_en/createGraphics.xml b/content/api_en/createGraphics.xml index 9cd5a982b..2eb84e5bc 100755 --- a/content/api_en/createGraphics.xml +++ b/content/api_en/createGraphics.xml @@ -30,13 +30,13 @@ void draw() { PGraphics object. Use this class if you need to draw into an off-screen graphics buffer. The first two parameters define the width and height in pixels. The third, optional parameter specifies the renderer. It can be defined as P2D, P3D, or PDF. If the third parameter isn't used, the default renderer is set. The PDF renderer requires the filename parameter.
+Creates and returns a new PGraphics object. Use this class if you need to draw into an off-screen graphics buffer. The first two parameters define the width and height in pixels. The third, optional parameter specifies the renderer. It can be defined as P2D, P3D, PDF, or SVG. If the third parameter isn't used, the default renderer is set. The PDF and SVG renderers require the filename parameter.

-It's important to consider the renderer used with createGraphics() in relation to the main renderer specified in size(). For example, it's only possible to use P2D or P3D with createGraphics() when one of them is defined in size(). Unlike Processing 1.0, P2D and P3D use OpenGL for drawing, and when using an OpenGL renderer it's necessary for the main drawing surface to be OpenGL-based. If P2D or P3D are used as the renderer in size(), then any of the options can be used with createGraphics(). If the default renderer is used in size(), then only the default or PDF can be used with createGraphics().
+It's important to consider the renderer used with createGraphics() in relation to the main renderer specified in size(). For example, it's only possible to use P2D or P3D with createGraphics() when one of them is defined in size(). Unlike Processing 1.0, P2D and P3D use OpenGL for drawing, and when using an OpenGL renderer it's necessary for the main drawing surface to be OpenGL-based. If P2D or P3D are used as the renderer in size(), then any of the options can be used with createGraphics(). If the default renderer is used in size(), then only the default, PDF, or SVG can be used with createGraphics().

-It's important to call any drawing functions between beginDraw() and endDraw() statements. This is also true for any functions that affect drawing, such as smooth() or colorMode().
+It's important to run all drawing functions between the beginDraw() and endDraw(). As the exception to this rule, smooth() should be run on the PGraphics object before beginDraw(). See the reference for smooth() for more detail.

-The createGraphics() function should almost never be used inside draw() because of the memory and time needed to set up the graphics. One-time or occasional use during draw() are acceptable, but code that calls createGraphics() at 60 frames per second will run out of memory or freeze your sketch.
+The createGraphics() function should almost never be used inside draw() because of the memory and time needed to set up the graphics. One-time or occasional use during draw() might be acceptable, but code that calls createGraphics() at 60 frames per second might run out of memory or freeze your sketch.

Unlike the main drawing surface which is completely opaque, surfaces created with createGraphics() can have transparency. This makes it possible to draw into a graphics and maintain the alpha channel. By using save() to write a PNG or TGA file, the transparency of the graphics object will be honored. ]]>
diff --git a/content/api_en/createReader.xml b/content/api_en/createReader.xml index a72384cf6..5ffe8049a 100644 --- a/content/api_en/createReader.xml +++ b/content/api_en/createReader.xml @@ -11,30 +11,25 @@ diff --git a/content/api_en/createShape.xml b/content/api_en/createShape.xml index 644deb0a5..4469495e8 100755 --- a/content/api_en/createShape.xml +++ b/content/api_en/createShape.xml @@ -91,6 +91,7 @@ void setup() { alien = createShape(GROUP); // Make two shapes + ellipseMode(CORNER); head = createShape(ELLIPSE, -25, 0, 50, 50); head.setFill(color(255)); body = createShape(RECT, -25, 45, 50, 40); @@ -111,7 +112,7 @@ void draw() { createShape() function is used to define a new shape. Once created, this shape can be drawn with the shape() function. The basic way to use the function defines new primitive shapes. One of the following parameters are used as the first parameter: ELLIPSE, RECT, ARC, TRIANGLE, SPHERE, BOX, QUAD, or LINE. The parameters for each of these different shapes are the same as their corresponding functions: ellipse(), rect(), arc(), triangle(), sphere(), box(), and line(). The first example above clarifies how this works.
+The createShape() function is used to define a new shape. Once created, this shape can be drawn with the shape() function. The basic way to use the function defines new primitive shapes. One of the following parameters are used as the first parameter: ELLIPSE, RECT, ARC, TRIANGLE, SPHERE, BOX, QUAD, or LINE. The parameters for each of these different shapes are the same as their corresponding functions: ellipse(), rect(), arc(), triangle(), sphere(), box(), quad(), and line(). The first example above clarifies how this works.

Custom, unique shapes can be made by using createShape() without a parameter. After the shape is started, the drawing attributes and geometry can be set directly to the shape within the beginShape() and endShape() methods. See the second example above for specifics, and the reference for beginShape() for all of its options.

diff --git a/content/api_en/cursor.xml b/content/api_en/cursor.xml index 3b3e9b0a3..81499ab44 100755 --- a/content/api_en/cursor.xml +++ b/content/api_en/cursor.xml @@ -14,8 +14,11 @@ // Move the mouse left and right across the image // to see the cursor change from a cross to a hand -void draw() -{ +void setup() { + size(100, 100); +} + +void draw() { if (mouseX < 50) { cursor(CROSS); } else { @@ -26,10 +29,10 @@ void draw()
x and y must be less than the dimensions of the image. -

+Sets the cursor to a predefined symbol or an image, or makes it visible if already hidden. If you are trying to set an image as the cursor, the recommended size is 16x16 or 32x32 pixels. The values for parameters x and y must be less than the dimensions of the image. +

Setting or hiding the cursor does not generally work with "Present" mode (when running full-screen). -

+

With the P2D and P3D renderers, a generic set of cursors are used because the OpenGL renderer doesn't have access to the default cursor images for each platform (Issue 3791). ]]>
diff --git a/content/api_en/curvePoint.xml b/content/api_en/curvePoint.xml index 8c9a6e011..c38a07c22 100755 --- a/content/api_en/curvePoint.xml +++ b/content/api_en/curvePoint.xml @@ -30,7 +30,7 @@ for (int i = 0; i <= steps; i++) { t for points a, b, c, d. The parameter t may range from 0 (the start of the curve) and 1 (the end of the curve). a and d are points on the curve, and b and c are the control points. This can be used once with the x coordinates and a second time with the y coordinates to get the location of a curve at t. +Evaluates the curve at point t for points a, b, c, d. The parameter t may range from 0 (the start of the curve) and 1 (the end of the curve). a and d are the control points, and b and c are points on the curve. As seen in the example above, this can be used once with the x coordinates and a second time with the y coordinates to get the location of a curve at t. ]]> diff --git a/content/api_en/endShape.xml b/content/api_en/endShape.xml index a6c604615..eaa2d1e05 100755 --- a/content/api_en/endShape.xml +++ b/content/api_en/endShape.xml @@ -28,7 +28,7 @@ endShape(); endShape() function is the companion to beginShape() and may only be called after beginShape(). When endshape() is called, all of image data defined since the previous call to beginShape() is written into the image buffer. The constant CLOSE as the value for the MODE parameter to close the shape (to connect the beginning and the end). +The endShape() function is the companion to beginShape() and may only be called after beginShape(). When endShape() is called, all of image data defined since the previous call to beginShape() is written into the image buffer. The constant CLOSE as the value for the MODE parameter to close the shape (to connect the beginning and the end). ]]> diff --git a/content/api_en/environment/index.html b/content/api_en/environment/index.html index 4d2e038d2..5d92731eb 100644 --- a/content/api_en/environment/index.html +++ b/content/api_en/environment/index.html @@ -531,8 +531,8 @@
Android Mode

Sketches written in this mode can be exported to run on Android phones and tablets. - This mode is documented on the - Processing for Android page of the Processing Wiki. To add this mode, click on + This mode is documented on the + Processing for Android page. To add this mode, click on the mode button in the upper-right corner of the PDE and select "Add Mode..."

--> @@ -574,7 +574,7 @@

- The Export information and + The Export information and Tips page on the Processing Wiki covers the details of exporting Applications from Java mode.

diff --git a/content/api_en/expand.xml b/content/api_en/expand.xml index 30c9d4afe..f0f020319 100755 --- a/content/api_en/expand.xml +++ b/content/api_en/expand.xml @@ -32,7 +32,7 @@ println(imgs.length); // Prints "64" newSize parameter provides precise control over the increase in size. +Increases the size of a one-dimensional array. By default, this function doubles the size of the array, but the optional newSize parameter provides precise control over the increase in size.

When using an array of objects, the data returned from the function must be cast to the object array's data type. For example: SomeClass[] items = (SomeClass[]) expand(originalArray) ]]>
diff --git a/content/api_en/frustum.xml b/content/api_en/frustum.xml index 5469e611d..f9645bd5a 100755 --- a/content/api_en/frustum.xml +++ b/content/api_en/frustum.xml @@ -25,7 +25,7 @@ Sets a perspective matrix as defined by the parameters.

A frustum is a geometric form: a pyramid with its top cut off. With the viewer's eye at the imaginary top of the pyramid, the six planes of the frustum act as clipping planes when rendering a 3D view. Thus, any form inside the clipping planes is rendered and visible; anything outside those planes is not visible.

-Setting the frustum has the effect of changing the perspective with which the scene is rendered. This can be acheived more simply in many cases by using perspective().
+Setting the frustum has the effect of changing the perspective with which the scene is rendered. This can be achieved more simply in many cases by using perspective().

Note that the near value must be greater than zero (as the point of the frustum "pyramid" cannot converge "behind" the viewer). Similarly, the far value must be greater than the near value (as the "far" plane of the frustum must be "farther away" from the viewer than the near plane).

diff --git a/content/api_en/get.xml b/content/api_en/get.xml index c1307b3cd..be56dc889 100755 --- a/content/api_en/get.xml +++ b/content/api_en/get.xml @@ -31,10 +31,12 @@ rect(25, 25, 50, 50); x and y parameters to get the value of one pixel. Get a section of the display window by specifying additional w and h parameters. When getting an image, the x and y parameters define the coordinates for the upper-left corner of the image, regardless of the current imageMode().
-
+Reads the color of any pixel or grabs a section of an image. If no parameters are specified, the entire image is returned. Use the x and y parameters to get the value of one pixel. Get a section of the display window by specifying additional w and h parameters. When getting an image, the x and y parameters define the coordinates for the upper-left corner of the image, regardless of the current imageMode(). +

If the pixel requested is outside of the image window, black is returned. The numbers returned are scaled according to the current color ranges, but only RGB values are returned by this function. For example, even though you may have drawn a shape with colorMode(HSB), the numbers returned will be in RGB format.

+If a width and a height are specified, get(x, y, w, h) returns a PImage corresponding to the part of the original PImage where the top left pixel is at the (x, y) position with a width of w a height of h. +

Getting the color of a single pixel with get(x, y) is easy, but not as fast as grabbing the data directly from pixels[]. The equivalent statement to get(x, y) using pixels[] is pixels[y*width+x]. See the reference for pixels[] for more information. ]]>
diff --git a/content/api_en/green.xml b/content/api_en/green.xml index 7d3ff0566..f1c38fe88 100755 --- a/content/api_en/green.xml +++ b/content/api_en/green.xml @@ -27,8 +27,8 @@ Extracts the green value from a color, scaled to match current colorMode() The green() function is easy to use and understand, but it is slower than a technique called bit shifting. When working in colorMode(RGB, 255), you can acheive the same results as green() but with greater speed by using the right shift operator (>>) with a bit mask. For example, the following two lines of code are equivalent means of getting the green value of the color value c:

-
float r1 = green(c);  // Simpler, but slower to calculate
-float r2 = c >> 8 & 0xFF;  // Very fast to calculate
+
float g1 = green(c);  // Simpler, but slower to calculate
+float g2 = c >> 8 & 0xFF;  // Very fast to calculate
]]> diff --git a/content/api_en/include/ArrayList.xml b/content/api_en/include/ArrayList.xml index 1cf04f77d..8feb4dc3a 100644 --- a/content/api_en/include/ArrayList.xml +++ b/content/api_en/include/ArrayList.xml @@ -64,7 +64,7 @@ An ArrayList stores a variable number of objects. This is similar to maki
An ArrayList is a resizable-array implementation of the Java List interface. It has many methods used to control and search its contents. For example, the length of the ArrayList is returned by its size() method, which is an integer value for the total number of elements in the list. An element is added to an ArrayList with the add() method and is deleted with the remove() method. The get() method returns the element at the specified position in the list. (See the above example for context.)

-For a list of the numerous ArrayList features, please read the Java reference description. +For a list of the numerous ArrayList features, please read the Java reference description. ]]> diff --git a/content/api_en/include/BufferedReader.xml b/content/api_en/include/BufferedReader.xml index 354daa453..c7ef0855d 100644 --- a/content/api_en/include/BufferedReader.xml +++ b/content/api_en/include/BufferedReader.xml @@ -45,17 +45,14 @@ A BufferedReader object is used to read files line-by-line as individual Starting with Processing release 0134, all files loaded and saved by the Processing API use UTF-8 encoding. In previous releases, the default encoding for your platform was used, which causes problems when files are moved to other platforms. ]]> + + readLine() returns a String that is the current line in the text file - - - - - - + @@ -67,8 +64,9 @@ catch 1.0 -Function +Object + +PDE -Core diff --git a/content/api_en/include/HashMap.xml b/content/api_en/include/HashMap.xml index 56ba42897..493e893de 100644 --- a/content/api_en/include/HashMap.xml +++ b/content/api_en/include/HashMap.xml @@ -22,7 +22,7 @@ hm.put("Ava", 1); hm.put("Cait", 35); hm.put("Casey", 36); -// Using an enhanced loop to interate over each entry +// Using an enhanced loop to iterate over each entry for (Map.Entry me : hm.entrySet()) { print(me.getKey() + " is "); println(me.getValue()); @@ -39,7 +39,7 @@ println("Casey is " + val); HashMap stores a collection of objects, each referenced by a key. This is similar to an Array, only instead of accessing elements with a numeric index, a String is used. (If you are familiar with associative arrays from other languages, this is the same idea.) The above example covers basic use, but there's a more extensive example included with the Processing examples. In addition, for simple pairings of Strings and integers, Strings and floats, or Strings and Strings, you can now use the simpler IntDict, FloatDict, and StringDict classes.

-For a list of the numerous HashMap features, please read the Java reference description. +For a list of the numerous HashMap features, please read the Java reference description. ]]>
diff --git a/content/api_en/include/Object.xml b/content/api_en/include/Object.xml index 46ff0c441..c2b5dc9dd 100755 --- a/content/api_en/include/Object.xml +++ b/content/api_en/include/Object.xml @@ -35,7 +35,7 @@ class HLine { } void update() { ypos += speed; - if (ypos > width) { + if (ypos > height) { ypos = 0; } line(0, ypos, width, ypos); diff --git a/content/api_en/include/String.xml b/content/api_en/include/String.xml index e4c4a9625..2febbe7de 100755 --- a/content/api_en/include/String.xml +++ b/content/api_en/include/String.xml @@ -24,12 +24,9 @@ println(str2); // Prints "CCCP" to the console @@ -46,11 +43,11 @@ println(quoted); // This one has "quotes" String includes methods for examining individual characters, comparing strings, searching strings, extracting parts of strings, and for converting an entire string uppercase and lowercase. Strings are always defined inside double quotes ("Abc"), and characters are always defined inside single quotes ('A').

-To compare the contents of two Strings, use the equals() method, as in if (a.equals(b)), instead of if (a == b). A String is an Object, so comparing them with the == operator only compares whether both Strings are stored in the same memory location. Using the equals() method will ensure that the actual contents are compared. (The troubleshooting reference has a longer explanation.)
+To compare the contents of two Strings, use the equals() method, as in if (a.equals(b)), instead of if (a == b). A String is an Object, so comparing them with the == operator only compares whether both Strings are stored in the same memory location. Using the equals() method will ensure that the actual contents are compared. (The troubleshooting reference has a longer explanation.)

Because a String is defined between double quotation marks, to include such marks within the String itself you must use the \ (backslash) character. (See the third example above.) This is known as an escape sequence. Other escape sequences include \t for the tab character and \n for new line. Because backslash is the escape character, to include a single backslash within a String, you must use two consecutive backslashes, as in: \\

-There are more string methods than those linked from this page. Additional documentation is located online in the official Java documentation. +There are more string methods than those linked from this page. Additional documentation is located online in the official Java documentation. ]]>
@@ -110,7 +107,6 @@ String(data, offset, length) int: number of characters - @@ -124,6 +120,4 @@ text() PDE - - diff --git a/content/api_en/include/String_substring.xml b/content/api_en/include/String_substring.xml index 0514f23ae..40813a34c 100755 --- a/content/api_en/include/String_substring.xml +++ b/content/api_en/include/String_substring.xml @@ -16,8 +16,8 @@ String str1 = "CCCP"; String str2 = "Rabbit"; String ss1 = str1.substring(2); // Returns "CP" String ss2 = str2.substring(3); // Returns "bit" -String ss3 = str1.substring(0, 2); // Returns "CC" -println(ss1 + ":" + ss2 + ":" + ss3); // Prints "CP:bit:CC" +String ss3 = str2.substring(0, 2); // Returns "Ra" +println(ss1 + ":" + ss2 + ":" + ss3); // Prints "CP:bit:Ra" ]]>
diff --git a/content/api_en/include/class.xml b/content/api_en/include/class.xml index 45eedd292..5f1e84cab 100755 --- a/content/api_en/include/class.xml +++ b/content/api_en/include/class.xml @@ -46,7 +46,7 @@ class HLine { Object-Oriented Programming is hosted on the Oracle website. +Keyword used to indicate the declaration of a class. A class is a composite of fields (data) and methods (functions that are a part of the class) which may be instantiated as objects. The first letter of a class name is usually uppercase to separate it from other kinds of variables. A related tutorial on Object-Oriented Programming is hosted on the Oracle website. ]]> diff --git a/content/api_en/include/color_datatype.xml b/content/api_en/include/color_datatype.xml index 2b501bf56..0f0b7b8f0 100755 --- a/content/api_en/include/color_datatype.xml +++ b/content/api_en/include/color_datatype.xml @@ -23,7 +23,7 @@ rect(50, 0, 50, 100); get() and color() or they may be specified directly using hexadecimal notation such as #FFCC00 or 0xFFFFCCOO. +Datatype for storing color values. Colors may be assigned with get() and color() or they may be specified directly using hexadecimal notation such as #FFCC00 or 0xFFFFCC00.

Using print() or println() on a color will produce strange results (usually negative numbers) because of the way colors are stored in memory. A better technique is to use the hex() function to format the color data, or use the red(), green(), and blue() functions to get individual values and print those. The hue(), saturation(), and brightness() functions work in a similar fashion. To extract red, green, and blue values more quickly (for instance when analyzing an image or a frame of video), use bit shifting.

diff --git a/content/api_en/include/curlybraces.xml b/content/api_en/include/curlybraces.xml index f4f1898c9..e9984f0d7 100755 --- a/content/api_en/include/curlybraces.xml +++ b/content/api_en/include/curlybraces.xml @@ -26,7 +26,7 @@ void draw() { for and if structures. Curly braces are also used for defining inital values in array declarations. +Define the beginning and end of functions blocks and statement blocks such as the for and if structures. Curly braces are also used for defining initial values in array declarations. ]]> diff --git a/content/api_en/include/doccomment.xml b/content/api_en/include/doccomment.xml index bb4331414..fa036a032 100755 --- a/content/api_en/include/doccomment.xml +++ b/content/api_en/include/doccomment.xml @@ -22,7 +22,9 @@ line(50, 0, 50, 100);
+Doc comments may be converted into browseable documentation using external editors and tools such as the command line javadoc, doc generators such as Doxygen, or IDEs such as Eclipse, Netbeans, or IntelliJ IDEA. ]]>
diff --git a/content/api_en/include/double.xml b/content/api_en/include/double.xml index 75ce6f466..24942764e 100644 --- a/content/api_en/include/double.xml +++ b/content/api_en/include/double.xml @@ -11,11 +11,11 @@ diff --git a/content/api_en/include/equality.xml b/content/api_en/include/equality.xml index 4ddfbd69a..a47eac505 100755 --- a/content/api_en/include/equality.xml +++ b/content/api_en/include/equality.xml @@ -14,15 +14,16 @@ int a = 23; int b = 23; if (a == b) { - println("variables a and b are equal"); + println("the values of variables 'a' and 'b' are the same"); } ]]> +Determines if two values are equivalent. Please note the equality operator (==) is different from the assignment operator (=) and although they look similar, they have a different use. If you're comparing two variables, the equality operator (==) only works with primitive data types like int, boolean, and char. It doesn't work with composite data types like Array, Table, and PVector.
+
+Note that when comparing String objects, you must use the equals() method instead of ==. See the reference for String or the troubleshooting note for more explanation.

-Note that when comparing String objects, you must use the equals() method instead of == to compare their contents. See the reference for String or the troubleshooting note for more explanation. ]]>
diff --git a/content/api_en/include/float.xml b/content/api_en/include/float.xml index 964d946e6..134cb33f4 100755 --- a/content/api_en/include/float.xml +++ b/content/api_en/include/float.xml @@ -41,7 +41,7 @@ Data type for floating-point numbers, e.g. numbers that have a decimal point.
Floats are not precise, so adding small values (such as 0.0001) may not always increment precisely due to rounding errors. If you want to increment a value in small intervals, use an int, and divide by a float value before using it. (See the second example above.)

-Floating-point numbers can be as large as 3.40282347E+38 and as low as -3.40282347E+38. They are stored as 32 bits (4 bytes) of information. The float data type is inherited from Java; you can read more about the technical details here and here.
+Floating-point numbers can be as large as 3.40282347E+38 and as low as -3.40282347E+38. They are stored as 32 bits (4 bytes) of information. The float data type is inherited from Java; you can read more about the technical details here and here.

Processing supports the double datatype from Java as well. However, none of the Processing functions use double values, which use more memory and are typically overkill for most work created in Processing. We do not plan to add support for double values, as doing so would require increasing the number of API functions significantly. ]]>
diff --git a/content/api_en/hint.xml b/content/api_en/include/hint.xml similarity index 88% rename from content/api_en/hint.xml rename to content/api_en/include/hint.xml index 7068ab8c8..a48311069 100644 --- a/content/api_en/hint.xml +++ b/content/api_en/include/hint.xml @@ -6,7 +6,27 @@ - +function + + + + + hint() to allow people to tune the settings for their particular sketch. Implementing a hint() is a last resort that's used when a more elegant solution cannot be found. Some options might graduate to standard features instead of hints over time, or be added and removed between (major) releases. @@ -48,4 +68,27 @@ Forces the P3D renderer to draw each shape (including its strokes) separately, i Enables stroke geometry (lines and points) to be affected by the perspective, meaning that they will look smaller as they move away from the camera. ]]> + +hint(which) + + + + + + + +void + + +PGraphics +createGraphics() +size() + + +1.0 + +Function + +PDE + diff --git a/content/api_en/include/intconvert.xml b/content/api_en/include/intconvert.xml index f14376165..56ba6ddb8 100755 --- a/content/api_en/include/intconvert.xml +++ b/content/api_en/include/intconvert.xml @@ -20,7 +20,7 @@ println(c + " : " + i); // Prints "E : 69" boolean, byte, char, color, float, int, or long) to its integer representation.
+Converts any value of a primitive data type (boolean, byte, char, color, float, int, or long) or String to its integer representation.

When an array of values is passed in, then an int array of the same length is returned. ]]>
diff --git a/content/api_en/include/multilinecomment.xml b/content/api_en/include/multilinecomment.xml index bd88002cb..a1c9dd6a1 100755 --- a/content/api_en/include/multilinecomment.xml +++ b/content/api_en/include/multilinecomment.xml @@ -22,7 +22,7 @@ line(50, 0, 50, 100); diff --git a/content/api_en/include/multiply.xml b/content/api_en/include/multiply.xml index 20c71bb1f..a125ad6fd 100755 --- a/content/api_en/include/multiply.xml +++ b/content/api_en/include/multiply.xml @@ -37,7 +37,7 @@ Multiplies the values of the two parameters. Multiplication is equivalent to a s -+ (add) ++ (addition) / (divide) @@ -48,10 +48,4 @@ Multiplies the values of the two parameters. Multiplication is equivalent to a s PDE - - - - - - diff --git a/content/api_en/include/rightshift.xml b/content/api_en/include/rightshift.xml index 27526643b..06437e001 100755 --- a/content/api_en/include/rightshift.xml +++ b/content/api_en/include/rightshift.xml @@ -37,7 +37,7 @@ rect(30, 20, 55, 55);
Bit shifting is helpful when using the color data type. A right shift can extract red, green, blue, and alpha values from a color. A left shift can be used to quickly reassemble a color value (more quickly than the color() function). ]]>
diff --git a/content/api_en/include/setLocation.xml b/content/api_en/include/setLocation.xml new file mode 100644 index 000000000..c54f0ee04 --- /dev/null +++ b/content/api_en/include/setLocation.xml @@ -0,0 +1,60 @@ + + +setLocation() + +Structure + + + +function + + + + + + +setLocation() function defines the position of the Processing sketch in relation to the upper-left corner of the computer screen. +

+There are more features of PSurface documented in the Processing JavaDoc. +]]>
+ + +surface.setLocation(x, y) + + + + + + + + + + + + +void + + + + +3.0 + +Function + +PDE + +
diff --git a/content/api_en/include/setResizable.xml b/content/api_en/include/setResizable.xml new file mode 100644 index 000000000..3b4261790 --- /dev/null +++ b/content/api_en/include/setResizable.xml @@ -0,0 +1,55 @@ + + +setResizable() + +Structure + + + +function + + + + + + +surface.setResizable(true) is used within a sketch, the window can be resized while it's running. +

+There are more features of PSurface documented in the Processing JavaDoc. +]]>
+ + +surface.setResizable(resizable) + + + + + + + +void + + + + +3.0 + +Function + +PDE + +
diff --git a/content/api_en/include/setTitle.xml b/content/api_en/include/setTitle.xml new file mode 100644 index 000000000..1c18e6d22 --- /dev/null +++ b/content/api_en/include/setTitle.xml @@ -0,0 +1,55 @@ + + +setTitle() + +Structure + + + +function + + + + + + +setTitle() function defines the title to appear at the top of the sketch window. +

+There are more features of PSurface documented in the Processing JavaDoc. +]]>
+ + +surface.setTitle(title) + + + + + + + +void + + + + +3.0 + +Function + +PDE + +
diff --git a/content/api_en/include/strconvert.xml b/content/api_en/include/strconvert.xml index 2126306f9..e81be07c5 100755 --- a/content/api_en/include/strconvert.xml +++ b/content/api_en/include/strconvert.xml @@ -29,7 +29,7 @@ println(sb); // Prints 'false-28R-32.61024' boolean, byte, char, color, double, float, int, or long) to its String representation. For example, converting an integer with str(3) will return the String value of "3", converting a float with str(-12.6) will return "-12.6", and converting a boolean with str(true) will return "true".
+Converts a value of a primitive data type (boolean, byte, char, int, or float) to its String representation. For example, converting an integer with str(3) will return the String value of "3", converting a float with str(-12.6) will return "-12.6", and converting a boolean with str(true) will return "true".

When an array of values is passed in, then a String array of the same length is returned. ]]>
diff --git a/content/api_en/key.xml b/content/api_en/key.xml index 282186f52..0b7d3bde0 100755 --- a/content/api_en/key.xml +++ b/content/api_en/key.xml @@ -30,7 +30,7 @@ void draw() { key always contains the value of the most recent key on the keyboard that was used (either pressed or released).

-For non-ASCII keys, use the keyCode variable. The keys included in the ASCII specification (BACKSPACE, TAB, ENTER, RETURN, ESC, and DELETE) do not require checking to see if they key is coded, and you should simply use the key variable instead of keyCode If you're making cross-platform projects, note that the ENTER key is commonly used on PCs and Unix and the RETURN key is used instead on Macintosh. Check for both ENTER and RETURN to make sure your program will work for all platforms. +For non-ASCII keys, use the keyCode variable. The keys included in the ASCII specification (BACKSPACE, TAB, ENTER, RETURN, ESC, and DELETE) do not require checking to see if the key is coded, and you should simply use the key variable instead of keyCode If you're making cross-platform projects, note that the ENTER key is commonly used on PCs and Unix and the RETURN key is used instead on Macintosh. Check for both ENTER and RETURN to make sure your program will work for all platforms.

There are issues with how keyCode behaves across different renderers and operating systems. Watch out for unexpected behavior as you switch renderers and operating systems. ]]>
diff --git a/content/api_en/keyCode.xml b/content/api_en/keyCode.xml index b11ea3ca0..8a3cd3d2f 100755 --- a/content/api_en/keyCode.xml +++ b/content/api_en/keyCode.xml @@ -39,9 +39,11 @@ When checking for these keys, it can be useful to first check if the key is code

The keys included in the ASCII specification (BACKSPACE, TAB, ENTER, RETURN, ESC, and DELETE) do not require checking to see if the key is coded; for those keys, you should simply use the key variable directly (and not keyCode). If you're making cross-platform projects, note that the ENTER key is commonly used on PCs and Unix, while the RETURN key is used on Macs. Make sure your program will work on all platforms by checking for both ENTER and RETURN.

-For those familiar with Java, the values for UP and DOWN are simply shorter versions of Java's KeyEvent.VK_UP and KeyEvent.VK_DOWN. Other keyCode values can be found in the Java KeyEvent reference. +For those familiar with Java, the values for UP and DOWN are simply shorter versions of Java's KeyEvent.VK_UP and KeyEvent.VK_DOWN. Other keyCode values can be found in the Java KeyEvent reference.

There are issues with how keyCode behaves across different renderers and operating systems. Watch out for unexpected behavior as you switch renderers and operating systems and you are using keys are aren't mentioned in this reference entry. +

+If you are using P2D or P3D as your renderer, use the NEWT KeyEvent constants. ]]> diff --git a/content/api_en/libraries/index.html b/content/api_en/libraries/index.html index 11cc19e54..e507a7c8b 100644 --- a/content/api_en/libraries/index.html +++ b/content/api_en/libraries/index.html @@ -16,7 +16,12 @@
PDF Export
Network

Send and receive data over the Internet through simple clients and servers.

- + +
  • +
    SVG Export
    +

    Create SVG files.

    +
  • +
  • Serial

    Send data between Processing and external hardware through serial communication (RS-232).

    diff --git a/content/api_en/loadJSONArray.xml b/content/api_en/loadJSONArray.xml index d7b7444ac..da22530e9 100755 --- a/content/api_en/loadJSONArray.xml +++ b/content/api_en/loadJSONArray.xml @@ -13,24 +13,26 @@ pixels[] array. This function must always be called before reading from or writing to pixels[]. Subsequent changes to the display window will not be reflected in pixels until loadPixels() is called again.
    -
    -Certain renderers may or may not seem to require loadPixels() or updatePixels(). However, the rule is that any time you want to manipulate the pixels[] array, you must have previously called loadPixels(), and after changes have been made, call updatePixels(). Even if the renderer may not seem to use this function in the current Processing release, this will always be subject to change. +Loads the pixel data of the current display window into the pixels[] array. This function must always be called before reading from or writing to pixels[]. Subsequent changes to the display window will not be reflected in pixels until loadPixels() is called again. ]]>
    diff --git a/content/api_en/loadTable.xml b/content/api_en/loadTable.xml index ef3908cea..e796c5c1c 100755 --- a/content/api_en/loadTable.xml +++ b/content/api_en/loadTable.xml @@ -11,7 +11,7 @@ If the file contains a header row, include "header" in the options parameter. If the file does not have a header row, then simply omit the "header" option.

    -When specifying both a header and the file type as the options parameter, separate the options with commas, as in: loadTable("data.csv", "header, tsv")
    +Some CSV files contain newline (CR or LF) characters inside cells. This is rare, but adding the "newlines" option will handle them properly. (This is not enabled by default because the parsing code is much slower.)
    +
    +When specifying multiple options, separate them with commas, as in: loadTable("data.csv", "header, tsv")

    All files loaded and saved by the Processing API use UTF-8 encoding. ]]> diff --git a/content/api_en/match.xml b/content/api_en/match.xml index 1db3a9f3a..92d1b2fdf 100755 --- a/content/api_en/match.xml +++ b/content/api_en/match.xml @@ -51,7 +51,7 @@ To use the function, first check to see if the result is null. If the result is
    If there are groups (specified by sets of parentheses) in the regular expression, then the contents of each will be returned in the array. Element [0] of a regular expression match returns the entire matching string, and the match groups start at element [1] (the first group is [1], the second [2], and so on).

    -The syntax can be found in the reference for Java's Pattern class. For regular expression syntax, read the Java Tutorial on the topic. +The syntax can be found in the reference for Java's Pattern class. For regular expression syntax, read the Java Tutorial on the topic. ]]> diff --git a/content/api_en/matchAll.xml b/content/api_en/matchAll.xml index 56feb6b5b..4f0345fbe 100644 --- a/content/api_en/matchAll.xml +++ b/content/api_en/matchAll.xml @@ -33,7 +33,7 @@ To use the function, first check to see if the result is null. If the result is
    If there are groups (specified by sets of parentheses) in the regular expression, then the contents of each will be returned in the array. Assuming a loop with counter variable i, element [i][0] of a regular expression match returns the entire matching string, and the match groups start at element [i][1] (the first group is [i][1], the second [i][2], and so on).

    -The syntax can be found in the reference for Java's Pattern class. For regular expression syntax, read the Java Tutorial on the topic. +The syntax can be found in the reference for Java's Pattern class. For regular expression syntax, read the Java Tutorial on the topic. ]]> diff --git a/content/api_en/mouseWheel.xml b/content/api_en/mouseWheel.xml index 02c01cd7a..0a2344176 100755 --- a/content/api_en/mouseWheel.xml +++ b/content/api_en/mouseWheel.xml @@ -26,7 +26,7 @@ void mouseWheel(MouseEvent event) {
    mouseWheel() function returns positive values when the mouse wheel is rotated down (toward the user), and negative values for the other direction (up or away from the user). On OS X with "natural" scrolling enabled, the values are opposite. +The code within the mouseWheel() event function is run when the mouse wheel is moved. (Some mice don't have wheels and this function is only applicable with mice that have a wheel.) The getCount() function used within mouseWheel() returns positive values when the mouse wheel is rotated down (toward the user), and negative values for the other direction (up or away from the user). On OS X with "natural" scrolling enabled, the values are opposite.

    Mouse and keyboard events only work when a program has draw(). Without draw(), the code is only run once and then stops listening for events. ]]>
    diff --git a/content/api_en/nf.xml b/content/api_en/nf.xml index f1e6123dd..295db43ac 100755 --- a/content/api_en/nf.xml +++ b/content/api_en/nf.xml @@ -26,11 +26,16 @@ String se = nf(e, 5, 3); println(se); // Prints "00040.200" String sf = nf(f, 3, 5); println(sf); // Prints "009.01200" + +String sf2 = nf(f, 0, 5); +println(sf2); // Prints "9.01200" +String sf3 = nf(f, 0, 2); +println(sf3); // Prints "9.01" ]]>
    digits, left, and right parameters should always be positive integers.

    As shown in the above example, nf() is used to add zeros to the left and/or right of a number. This is typically for aligning a list of numbers. To remove digits from a floating-point number, use the int(), ceil(), floor(), or round() functions. +Utility function for formatting numbers into strings. There are two versions: one for formatting floats, and one for formatting ints. The values for the digits and right parameters should always be positive integers. The left parameter should be positive or 0. If it is zero, only the right side is formatted.

    As shown in the above example, nf() is used to add zeros to the left and/or right of a number. This is typically for aligning a list of numbers. To remove digits from a floating-point number, use the int(), ceil(), floor(), or round() functions. ]]>
    diff --git a/content/api_en/noSmooth.xml b/content/api_en/noSmooth.xml index aa1ceec8d..d40dd92e6 100755 --- a/content/api_en/noSmooth.xml +++ b/content/api_en/noSmooth.xml @@ -38,7 +38,7 @@ void draw() { smooth() is active by default, so it is necessary to call noSmooth() to disable smoothing of geometry, fonts, and images. Since the release of Processing 3.0, the noSmooth() function can only be run once for each sketch, either at the top of a sketch without a setup(), or after the size() function when used in a sketch with setup(). See the examples above for both scenarios. +Draws all geometry and fonts with jagged (aliased) edges and images with hard edges between the pixels when enlarged rather than interpolating pixels. Note that smooth() is active by default, so it is necessary to call noSmooth() to disable smoothing of geometry, fonts, and images. Since the release of Processing 3.0, the noSmooth() function can only be run once for each sketch, either at the top of a sketch without a setup(), or after the size() function when used in a sketch with setup(). See the examples above for both scenarios. ]]> diff --git a/content/api_en/noiseDetail.xml b/content/api_en/noiseDetail.xml index b770659f0..dfd0d0633 100755 --- a/content/api_en/noiseDetail.xml +++ b/content/api_en/noiseDetail.xml @@ -31,7 +31,7 @@ void draw() { +Adjusts the character and level of detail produced by the Perlin noise function. Similar to harmonics in physics, noise is computed over several octaves. Lower octaves contribute more to the output signal and as such define the overall intensity of the noise, whereas higher octaves create finer-grained details in the noise sequence.

    By default, noise is computed over 4 octaves with each octave contributing exactly half than its predecessor, starting at 50% strength for the first octave. This falloff amount can be changed by adding an additional function parameter. For example, a falloff factor of 0.75 means each octave will now have 75% impact (25% less) of the previous lower octave. While any number between 0.0 and 1.0 is valid, note that values greater than 0.5 may result in noise() returning values greater than 1.0.

    diff --git a/content/api_en/pixelDensity.xml b/content/api_en/pixelDensity.xml index 02d96afe8..35b15bac1 100755 --- a/content/api_en/pixelDensity.xml +++ b/content/api_en/pixelDensity.xml @@ -57,9 +57,10 @@ void draw() { size() in a program without a setup() and used within setup() when a program has one. The pixelDensity() should only be used with hardcoded numbers (in almost all cases this number will be 2) or in combination with displayDensity() as in the third example above. - +

    +When the pixel density is set to more than 1, it changes all of the pixel operations including the way get(), set(), blend(), copy(), and updatePixels() all work. See the reference for pixelWidth and pixelHeight for more information. +

    To use variables as the arguments to pixelDensity() function, place the pixelDensity() function within the settings() function. There is more information about this on the settings() reference page. - ]]>
    diff --git a/content/api_en/pixelHeight.xml b/content/api_en/pixelHeight.xml index 8be6e94d4..1a2e15e63 100755 --- a/content/api_en/pixelHeight.xml +++ b/content/api_en/pixelHeight.xml @@ -8,10 +8,41 @@ + + + + diff --git a/content/api_en/pixelWidth.xml b/content/api_en/pixelWidth.xml index 45ab35d9e..5f88fa136 100755 --- a/content/api_en/pixelWidth.xml +++ b/content/api_en/pixelWidth.xml @@ -8,10 +8,41 @@ + + + + diff --git a/content/api_en/pixels.xml b/content/api_en/pixels.xml index b7ac0be33..536f50338 100755 --- a/content/api_en/pixels.xml +++ b/content/api_en/pixels.xml @@ -21,8 +21,8 @@ updatePixels(); -
    +The pixels[] array contains the values for all the pixels in the display window. These values are of the color datatype. This array is defined by the size of the display window. For example, if the window is 100 x 100 pixels, there will be 10,000 values and if the window is 200 x 300 pixels, there will be 60,000 values. When the pixel density is set to higher than 1 with the pixelDensity() function, these values will change. See the reference for pixelWidth or pixelHeight for more information. +

    Before accessing this array, the data must loaded with the loadPixels() function. Failure to do so may result in a NullPointerException. Subsequent changes to the display window will not be reflected in pixels until loadPixels() is called again. After pixels has been modified, the updatePixels() function must be run to update the content of the display window. ]]>
    diff --git a/content/api_en/point.xml b/content/api_en/point.xml index 141dc932f..6034c7f82 100755 --- a/content/api_en/point.xml +++ b/content/api_en/point.xml @@ -35,6 +35,10 @@ point(30, 75, -50); Draws a point, a coordinate in space at the dimension of one pixel. The first parameter is the horizontal value for the point, the second value is the vertical value for the point, and the optional third value is the depth value. Drawing this shape in 3D with the z parameter requires the P3D parameter in combination with size() as shown in the above example.

    Use stroke() to set the color of a point(). +

    +Point appears round with the default strokeCap(ROUND) and square with strokeCap(PROJECT). Points are invisible with strokeCap(SQUARE) (no cap). +

    +Using point() with strokeWeight(1) or smaller may draw nothing to the screen, depending on the graphics settings of the computer. Workarounds include setting the pixel using set() or drawing the point using either circle() or square(). ]]>
    diff --git a/content/api_en/pop.xml b/content/api_en/pop.xml new file mode 100644 index 000000000..743748933 --- /dev/null +++ b/content/api_en/pop.xml @@ -0,0 +1,51 @@ + + +pop() + +Structure + + + + + + +popMatrix_.png + + + + +popStyle_0.png + + + +pop() function restores the previous drawing style settings and transformations after push() has changed them. Note that these functions are always used together. They allow you to change the style and transformation settings and later return to what you had. When a new state is started with push(), it builds on the current style and transform information.
    +
    +push() stores information related to the current transformation state and style settings controlled by the following functions: rotate(), translate(), scale(), fill(), stroke(), tint(), strokeWeight(), strokeCap(), strokeJoin(), imageMode(), rectMode(), ellipseMode(), colorMode(), textAlign(), textFont(), textMode(), textSize(), textLeading().
    +
    +The push() and pop() functions were added with Processing 3.5. They can be used in place of pushMatrix(), popMatrix(), pushStyles(), and popStyles(). The difference is that push() and pop() control both the transformations (rotate, scale, translate) and the drawing styles at the same time. +]]> + + diff --git a/content/api_en/push.xml b/content/api_en/push.xml new file mode 100644 index 000000000..e926650fb --- /dev/null +++ b/content/api_en/push.xml @@ -0,0 +1,51 @@ + + +push() + +Structure + + + + + + +pushMatrix_.png + + + + +pushStyle_0.png + + + +push() function saves the current drawing style settings and transformations, while pop() restores these settings. Note that these functions are always used together. They allow you to change the style and transformation settings and later return to what you had. When a new state is started with push(), it builds on the current style and transform information.
    +
    +push() stores information related to the current transformation state and style settings controlled by the following functions: rotate(), translate(), scale(), fill(), stroke(), tint(), strokeWeight(), strokeCap(), strokeJoin(), imageMode(), rectMode(), ellipseMode(), colorMode(), textAlign(), textFont(), textMode(), textSize(), textLeading().
    +
    +The push() and pop() functions were added with Processing 3.5. They can be used in place of pushMatrix(), popMatrix(), pushStyles(), and popStyles(). The difference is that push() and pop() control both the transformations (rotate, scale, translate) and the drawing styles at the same time. +]]>
    + +
    diff --git a/content/api_en/quadraticVertex.xml b/content/api_en/quadraticVertex.xml index 1cf51f929..c3dd03bc5 100644 --- a/content/api_en/quadraticVertex.xml +++ b/content/api_en/quadraticVertex.xml @@ -35,7 +35,7 @@ endShape(); quadraticVertex() defines the position of one control points and one anchor point of a Bezier curve, adding a new segment to a line or shape. The first time quadraticVertex() is used within a beginShape() call, it must be prefaced with a call to vertex() to set the first anchor point. This function must be used between beginShape() and endShape() and only when there is no MODE parameter specified to beginShape(). Using the 3D version requires rendering with P3D (see the Environment reference for more information). +Specifies vertex coordinates for quadratic Bezier curves. Each call to quadraticVertex() defines the position of one control point and one anchor point of a Bezier curve, adding a new segment to a line or shape. The first time quadraticVertex() is used within a beginShape() call, it must be prefaced with a call to vertex() to set the first anchor point. This function must be used between beginShape() and endShape() and only when there is no MODE parameter specified to beginShape(). Using the 3D version requires rendering with P3D (see the Environment reference for more information). ]]> diff --git a/content/api_en/resetMatrix.xml b/content/api_en/resetMatrix.xml index 733a2803b..fb1c6ac42 100755 --- a/content/api_en/resetMatrix.xml +++ b/content/api_en/resetMatrix.xml @@ -9,7 +9,7 @@ -resetMatrix_.png +
    When using an array of objects, the data returned from the function must be cast to the object array's data type. For example: SomeClass[] items = (SomeClass[]) shorten(originalArray) ]]>
    diff --git a/content/api_en/size.xml b/content/api_en/size.xml index 50ddae1f3..bd6f4c1b0 100755 --- a/content/api_en/size.xml +++ b/content/api_en/size.xml @@ -51,7 +51,7 @@ box(35);
    setup() function, the size() function must be the first line of code inside setup().
    +Defines the dimension of the display window width and height in units of pixels. In a program that has the setup() function, the size() function must be the first line of code inside setup(), and the setup() function must appear in the code tab with the same name as your sketch folder.

    The built-in variables width and height are set by the parameters passed to this function. For example, running size(640, 480) will assign 640 to the width variable and 480 to the height variable. If size() is not used, the window will be given a default size of 100 x 100 pixels.

    @@ -73,6 +73,8 @@ The renderer parameter selects which rendering engine to use. For example
    PDF: The PDF renderer draws 2D graphics directly to an Acrobat PDF file. This produces excellent results when you need vector shapes for high-resolution output or printing. You must first use Import Library → PDF to make use of the library. More information can be found in the PDF library reference.

    +SVG: The SVG renderer draws 2D graphics directly to an SVG file. This is great for importing into other vector programs or using for digital fabrication. You must first use Import Library → SVG Export to make use of the library.
    +
    As of Processing 3.0, to use variables as the parameters to size() function, place the size() function within the settings() function (instead of setup()). There is more information about this on the settings() reference page.

    ]]>
    diff --git a/content/api_en/smooth.xml b/content/api_en/smooth.xml index 6b82e35b5..c19f7a303 100755 --- a/content/api_en/smooth.xml +++ b/content/api_en/smooth.xml @@ -28,6 +28,8 @@ void draw() { + + + + + smooth() only needs to be used when a program needs to set the smoothing in a different way. The level parameter increases the level of smoothness. This is the level of over sampling applied to the graphics buffer.
    -
    -With the P2D and P3D renderers, smooth(2) is the default, this is called "2x anti-aliasing." The code smooth(4) is used for 4x anti-aliasing and smooth(8) is specified for 8x anti-aliasing. The maximum anti-aliasing level is determined by the hardware of the machine that is running the software, so smooth(4) and smooth(8) will not work with every computer.
    -
    -The default renderer uses smooth(3) by default. This is bicubic smoothing. The other option for the default renderer is smooth(2), which is bilinear smoothing.
    -
    +Draws all geometry with smooth (anti-aliased) edges. This behavior is the default, so smooth() only needs to be used when a program needs to set the smoothing in a different way. The level parameter increases the amount of smoothness. This is the level of over sampling applied to the graphics buffer. +

    +With the P2D and P3D renderers, smooth(2) is the default, this is called "2x anti-aliasing." The code smooth(4) is used for 4x anti-aliasing and smooth(8) is specified for "8x anti-aliasing." The maximum anti-aliasing level is determined by the hardware of the machine that is running the software, so smooth(4) and smooth(8) will not work with every computer. +

    +The default renderer uses smooth(3) by default. This is bicubic smoothing. The other option for the default renderer is smooth(2), which is bilinear smoothing. +

    With Processing 3.0, smooth() is different than before. It was common to use smooth() and noSmooth() to turn on and off antialiasing within a sketch. Now, because of how the software has changed, smooth() can only be set once within a sketch. It can be used either at the top of a sketch without a setup(), or after the size() function when used in a sketch with setup(). The noSmooth() function also follows the same rules. +

    +When smooth() is used with a PGraphics object, it should be run right after the object is created with createGraphics(), as shown in the Reference in the third example. ]]>
    diff --git a/content/api_en/splice.xml b/content/api_en/splice.xml index c62c959e8..a9f5358c6 100755 --- a/content/api_en/splice.xml +++ b/content/api_en/splice.xml @@ -39,7 +39,7 @@ println(a); +Inserts a value or an array of values into an existing array. The first two parameters must be arrays of the same datatype. The first parameter specifies the initial array to be modified, and the second parameter defines the data to be inserted. The third parameter is an index value which specifies the array position from which to insert data. (Remember that array index numbering starts at zero, so the first position is 0, the second position is 1, and so on.)

    When splicing an array of objects, the data returned from the function must be cast to the object array's data type. For example: SomeClass[] items = (SomeClass[]) splice(array1, array2, index) ]]>
    diff --git a/content/api_en/split.xml b/content/api_en/split.xml index 13841d3ba..5b01ca9f2 100755 --- a/content/api_en/split.xml +++ b/content/api_en/split.xml @@ -38,7 +38,7 @@ String[] list = split(men, " ] "); split() function breaks a String into pieces using a character or string as the delimiter. The delim parameter specifies the character or characters that mark the boundaries between each piece. A String[] array is returned that contains each of the pieces.

    -If the result is a set of numbers, you can convert the String[] array to to a float[] or int[] array using the datatype conversion functions int() and float(). (See the second example above.) +If the result is a set of numbers, you can convert the String[] array to a float[] or int[] array using the datatype conversion functions int() and float(). (See the second example above.)

    The splitTokens() function works in a similar fashion, except that it splits using a range of characters instead of a specific character or sequence.

     

     

    - - - + Programming Interactivity: A Designer's Guide to Processing, Arduino, and openFrameworks - Programming Interactivity
    + Programming Interactivity
    Joshua Noble.
    Published January 2012, O'Reilly. 728 pages. Paperback.
    » Order from Amazon.com
    - The O'Reilly website says, "Make cool stuff. If you're a designer or artist without a lot of programming experience, this book will teach you to work with 2D and 3D graphics, sound, physical interaction, and electronic circuitry to create all sorts of interesting and compelling experiences -- online and off. Programming Interactivity explains programming and electrical engineering basics, and introduces three freely available tools created specifically for artists and designers: Processing, Arduino, and OpenFrameworks." - + The O'Reilly website says, "Make cool stuff. If you're a designer or artist without a lot of programming experience, this book will teach you to work with 2D and 3D graphics, sound, physical interaction, and electronic circuitry to create all sorts of interesting and compelling experiences -- online and off. Programming Interactivity explains programming and electrical engineering basics, and introduces three freely available tools created specifically for artists and designers: Processing, Arduino, and OpenFrameworks." + + +

     

    @@ -324,7 +394,6 @@

    Books. Processing books cove -

     

    @@ -345,15 +414,12 @@

    Books. Processing books cove The Wiley website says, "this book offers a series of generic procedures that can function as building blocks and encourages you to then use those building blocks to experiment, explore, and channel your thoughts, ideas, and principles into potential solutions. The book covers such topics as structured shapes, solid geometry, networking and databases, physical computing, image processing, graphic user interfaces, and more." - -

     

     

    - Data-driven Graphic Design: Creative Coding for Visual Communication @@ -363,20 +429,16 @@

    Books. Processing books cove Andrew Richardson.
    Published January 2016, Bloomsbury. 224 Pages. Paperback.
    » Order from Amazon.com -
    +

    The book description reads, "Data-driven Graphic Design introduces the creative potential of computational data and how it can be used to inform and create everything from typography, print and moving graphics to interactive design and physical installations. Using code as a creative environment allows designers to step outside the boundaries of commercial software tools, and create a set of unique, digitally informed pieces of work. The use of code offers a new way of thinking about and creating design for the digital environment." - - - + - +

     

     

    @@ -422,7 +484,7 @@

    Books. Processing books cove - +

     

     

    @@ -509,20 +571,40 @@

    Books. Processing books cove

     

    - + + + + O Código Transcendente: Uma Introdução Prática à Programação e Arte Gerativa + O Código Transcendente: Uma Introdução Prática à Programação e Arte Gerativa
    + Mateus Berruezo.
    + Published December 2019. 270 pages. PDF, Web.
    + Text in Portuguese.
    + » Download
    + » Read online +
    +
    + Este livro é um guia de programação com enfoque prático considerando o contexto da arte gerativa e do pensamento computacional. Ele conta com explicações e exemplos visuais cuidadosamente projetados para serem de valor tanto para programadores quanto artistas. As aplicações e estudos de caso foram direcionados para a linguagem Processing cuja própria filosofia segue o princípio da exploração do artístico através do código. + + + +

     

    +

     

    + + Einführung ins Programmieren mit Processing Einführung ins Programmieren mit Processing
    - Matthias Wolf.
    - Published August 2013. 178 pages. PDF, Paperback.
    - Text in German.
    - » Order Print/EBook from lulu.com
    -
    -

    Die eigenständige Programmiersprache Processing basiert auf Java und ähnelt diesem sehr, verbirgt aber gleichzeitig viel von dessen Komplexität. Dadurch ist Processing für den Programmieranfänger ideal geeignet, um sich Konzepte des Programmierens zu erschließen und bewahrt gleichzeitig die Möglichkeit eines späteren Umstiegs. Dennoch ist die Sprache keineswegs nur für triviale Anfängeraufgaben geeignet: speziell im Bereich der graphischen Datenverarbeitung spielt Processing seine Stärken aus.

    -

    Dieses Buch richtet sich in erster Linie an den Einsteiger, den es an die Bewältigung auch komplexerer Aufgaben heranführt, wobei grundlegende Konzepte der imperativen und der objektorientierten Programmierung vorgestellt werden. Auch notwendige theoretische Hintergründe kommen dabei nicht zu kurz. Ausführlich kommentierter Beispielcode erschließt Konzepte und Sprache. Aber auch der routinierte Programmierer, der sich "nur" eine neue Sprache erschließen will, wird fündig!

    -

    Aus dem Inhalt: Datentypen — Variablen — Arrays (ein- und mehrdiomensional) — Flusssteuerung — Methoden — Objektorientiertes Programmieren — 2D-Graphik — 3D-Graphik — Dateizugriff — PDF — QuickTimeTM — Arduino®-Mikrocontroller — Alphabetischer Index + Matthias Wolf.
    + Published August 2013. 178 pages. PDF, Paperback.
    + Text in German.
    + » Order Print/EBook from lulu.com
    +
    +

    Die eigenständige Programmiersprache Processing basiert auf Java und ähnelt diesem sehr, verbirgt aber gleichzeitig viel von dessen Komplexität. Dadurch ist Processing für den Programmieranfänger ideal geeignet, um sich Konzepte des Programmierens zu erschließen und bewahrt gleichzeitig die Möglichkeit eines späteren Umstiegs. Dennoch ist die Sprache keineswegs nur für triviale Anfängeraufgaben geeignet: speziell im Bereich der graphischen Datenverarbeitung spielt Processing seine Stärken aus.

    +

    Dieses Buch richtet sich in erster Linie an den Einsteiger, den es an die Bewältigung auch komplexerer Aufgaben heranführt, wobei grundlegende Konzepte der imperativen und der objektorientierten Programmierung vorgestellt werden. Auch notwendige theoretische Hintergründe kommen dabei nicht zu kurz. Ausführlich kommentierter Beispielcode erschließt Konzepte und Sprache. Aber auch der routinierte Programmierer, der sich "nur" eine neue Sprache erschließen will, wird fündig!

    +

    Aus dem Inhalt: Datentypen — Variablen — Arrays (ein- und mehrdiomensional) — Flusssteuerung — Methoden — Objektorientiertes Programmieren — 2D-Graphik — 3D-Graphik — Dateizugriff — PDF — QuickTimeTM — Arduino®-Mikrocontroller — Alphabetischer Index @@ -540,7 +622,7 @@

    Books. Processing books cove Text in German.

    The OReilly.de site writes, "Processing ist eine auf Grafik, Simulation und Animation spezialisierte objektorientierte Programmiersprache, die besonders für Menschen mit wenig Programmiererfahrung geeignet ist. Deshalb eignet sie sich vor allem für Künstler, Bastler und Programmiereinsteiger. Die aus Java abgeleitete Sprache wurde geschaffen, um schnell und effektiv mit relativ wenig Aufwand zu beeindruckenden Ergebnissen zu kommen. Processing führt den Leser zügig in die Programmieressentials ein und geht dann unmittelbar zur Programmierung grafisch anspruchsvoller Anwendungen über. Spielerisch wird dem Leser die 2D- und 3D-Programierung, Textrendering, die Bildbearbeitung und sogar die Videomanipulation nahe gebracht." -

    + @@ -612,7 +694,8 @@

    Books. Processing books cove During the 50‘s ”era of cybernetics“, computer entered into the history of art simultaneously in different parts of the world. Art and science were in great turmoil. Science, with its theories and experiments, was approaching artificially mimicking both natural phenomena, such as light and sound, and the human phenomena of language and communication. Art, with its aesthetic and exhibitions, had transcended the boundaries of the avant-garde. Now, with the computer, it was confronting a reality that challenged ”the where“ and ”the how“ of doing art and the very meaning of ”masterpiece“. Antonio Rollo takes us on a tour of these seminal works from his unique perspective of the artist, through the code!

    - There's additional information on the publisher's website. + There's additional information on the publisher's website. + @@ -632,7 +715,8 @@

    Books. Processing books cove
    Note from Casey: "I received a copy of this book from the authors on a recent trip to Japan. It's a beautifully produced full-color book with sections introducing Processing, featuring work created with Processing (many are from the Exhibition section of the Processing website), and introducing programming through progressively complicated examples. The majority of the book is an introduction to programming. There are many good examples and the code is color-coded like in the Processing Environment. This book is less comprehensive than the Greenberg and Reas/Fry books, but it appears to be a good, brief introduction."

    - There's additional information on the publisher's website. + There's additional information on the publisher's website. + @@ -662,49 +746,5 @@

    Books. Processing books cove - - - -

     

    -

     

    - - -

     

    - - Processing is also discussed through examples and projects in the following books: - -
    - -
    - - 10 PRINT CHR$(205.5+RND(1)); : GOTO 10
    By Nick Montfort, Patsy Baudoin, John Bell, Ian Bogost, Jeremy Douglass, Mark C. Marino, Michael Mateas, Casey Reas, Mark Sample, Noah Vawter. Examples use Processing to explore a modern interpretation of a 1982 Commodore 64 program.
    - -
    - - Make: Getting Started with Arduino
    By Massimo Banzi. Examples use Processing to communicate with an Arduino board.
    - -
    - - Building Wireless Sensor Networks: with ZigBee, XBee, Arduino, and Processing
    By Robert Faludi. Network examples use Processing.
    - -
    - - Physical Computing: Sensing and Controlling the Physical World with Computers
    - By Dan O'Sullivan and Tom Igoe. Examples using Processing for RS-232 communication and - computer vision.
    - -
    - - Aesthetic Computing.
    - Edited by Paul Fishwick. Casey Reas and Ben Fry contributed a chapter entitled - "Processing Code: Programming within the Context of Visual Art and Design."
    - -
    - - Hacking Roomba: ExtremeTech
    By Tod E. Kurt. Processing is introduced and used to design an application to control a Roomba (a robot vacuum cleaner).
    - -
    - Analog In, Digital Out
    By Brendan Dawes. Numerous projects created with Processing are illustrated and discussed.
    -

    diff --git a/content/static/download.html b/content/static/download.html index 8083ee8c1..122db5e30 100644 --- a/content/static/download.html +++ b/content/static/download.html @@ -9,15 +9,19 @@

    Download Processing. Process
    - 3.3.5 - (23 June 2017) + 4.0b1 + (9 August 2021)
    @@ -25,12 +29,12 @@

    Download Processing. Process
    - Read about the changes in 3.0. The list of revisions covers the differences between releases in detail. + Read about the changes in 4.0. The list of revisions covers the differences between releases in detail.
    @@ -38,126 +42,205 @@

    Download Processing. Process

    Stable Releases

    +
  • + 4.0b1 + (9 August 2021) + Windows 64 + Linux 64 + macOS +
  • +
  • + 3.5.4 + (17 January 2020) + Win 32 + Win 64 + Linux 64 + Mac OS X +
  • +
  • 3.3 (12 February 2017) Win 32 - Win 64 - Linux 32 + Win 64 + Linux 32 Linux 64 Linux ARMv6hf - Mac OS X + Mac OS X
  • - @@ -165,19 +248,19 @@

    Stable Releases

    2.2.1 (19 May 2014) Win 32 - Win 64 - Linux 32 + Win 64 + Linux 32 Linux 64 - Mac OS X + Mac OS X

  • 1.5.1 (15 May 2011) Win (standard) - Win (no Java) - Linux x86 - Mac OS X + Win (no Java) + Linux x86 + Mac OS X
  • Earlier releases have been removed because we can only support the current versions of the software. To update old code, read the changes page. Changes for each release can be found in revisions.txt. If you have problems with the current release, please file a bug so that we can fix it. Older releases can also be built from the source. Read More about the releases and their numbering. To use Android Mode, Processing 3 or later is required.

    @@ -187,170 +270,65 @@

    Stable Releases

    Pre-Releases

    -

    The revisions cover incremental changes between releases, and are especially important to read for pre-releases.

    +

    The changes document covers incremental updates between 4.x releases, and is especially important to read for pre-releases.

    - Processing is Open Source Software. The PDE (Processing Development Environment) is released under the GNU GPL (General Public License). The export libraries (also known as 'core') are released under the GNU LGPL (Lesser General Public License). There's more information about Processing and Open Source in the FAQ and more information about the GNU GPL and GNU LGPL at opensource.org. Please support Processing! + Processing is Open Source Software. The PDE (Processing Development Environment) is released under the GNU GPL (General Public License). The export libraries (also known as 'core') are released under the GNU LGPL (Lesser General Public License). There's more information about Processing and Open Source in the FAQ and more information about the GNU GPL and GNU LGPL at opensource.org. Please support Processing!
    diff --git a/content/static/handbook.html b/content/static/handbook.html index e1fbca351..27ef76ed6 100644 --- a/content/static/handbook.html +++ b/content/static/handbook.html @@ -6,13 +6,13 @@

    Processing: A Programming Handbook Published December 2014, The MIT Press.
    720 Pages. Hardcover.

    - » Order from MIT Press
    + » Order from MIT Press
    » Order from Amazon

    » Download Examples
    » Errata

    - If you are an educator, you can request a desk/exam copy from the MIT Press website. + If you are an educator, you can request a desk/exam copy from the MIT Press website.

    @@ -28,7 +28,7 @@

    Processing: A Programming Handbook

    - Interviews with SUE.C, Larry Cuba, Mark Hansen, Lynn Hershman Leeson, Jürg Lehni, LettError, Golan Levin and Zachary Lieberman, Benjamin Maus, Manfred Mohr, Ash Nehru, Josh On, Bob Sabiston, Jennifer Steinkamp, Jared Tarbell, Steph Thirion, and Robert Winter. + Interviews with SUE.C, Larry Cuba, Mark Hansen, Lynn Hershman Leeson, Jürg Lehni, LettError, Golan Levin and Zachary Lieberman, Benjamin Maus, Manfred Mohr, Ash Nehru, Josh On, Bob Sabiston, Jennifer Steinkamp, Jared Tarbell, Steph Thirion, and Robert Winter.

    diff --git a/content/static/overview.html b/content/static/overview.html index 13349191d..d5d3d30ff 100644 --- a/content/static/overview.html +++ b/content/static/overview.html @@ -6,14 +6,11 @@

    Overview. A short introducti

    - For the past fourteen years, Processing has promoted software literacy, particularly within the visual arts, and visual literacy within technology. Initially created to serve as a software sketchbook and to teach programming fundamentals within a visual context, Processing has also evolved into a development tool for professionals. The Processing software is free and open source, and runs on the Mac, Windows, and GNU/Linux platforms. - -

    - Processing continues to be an alternative to proprietary software tools with restrictive and expensive licenses, making it accessible to schools and individual students. Its open source status encourages the community participation and collaboration that is vital to Processing’s growth. Contributors share programs, contribute code, and build libraries, tools, and modes to extend the possibilities of the software. The Processing community has written more than a hundred libraries to facilitate computer vision, data visualization, music composition, networking, 3D file exporting, and programming electronics. + For the past sixteen years, Processing has promoted software literacy, particularly within the visual arts, and visual literacy within technology. Initially created to serve as a software sketchbook and to teach programming fundamentals within a visual context, Processing has also evolved into a development tool for professionals. The Processing software is free and open source, and runs on the Mac, Windows, and GNU/Linux platforms.

    - Processing is currently developed primarily in Boston (at Fathom Information Design), Los Angeles (at the UCLA Arts Software Studio), and New York City (at NYU’s ITP). + Processing continues to be an alternative to proprietary software tools with restrictive and expensive licenses, making it accessible to schools and individual students. Its open source status encourages the community participation and collaboration that is vital to Processing’s growth. Contributors share programs, contribute code, and build libraries, tools, and modes to extend the possibilities of the software. The Processing community has written more than a hundred libraries to facilitate computer vision, data visualization, music composition, networking, 3D file exporting, and programming electronics.

    Education

    @@ -27,7 +24,7 @@

    Education

    - The innovations in teaching through Processing have been adapted for the Khan Academy computer science tutorials, offered online for free. The tutorials begin with drawing, using most of the Processing functions for drawing. The Processing approach has also been applied to electronics through the Arduino and Wiring projects. Arduino uses a syntax inspired by that used with Processing, and continues to use a modified version of the Processing programming environment to make it easier for students to learn how to program robots and countless other electronics projects. + The innovations in teaching through Processing have been adapted for the Khan Academy computer science tutorials, offered online for free. The tutorials begin with drawing, using most of the Processing functions for drawing. The Processing approach has also been applied to electronics through the Arduino and Wiring projects. Arduino uses a syntax inspired by that used with Processing, and continues to use a modified version of the Processing programming environment to make it easier for students to learn how to program robots and countless other electronics projects.

    Culture

    @@ -45,21 +42,23 @@

    Research

    Foundation

    -The primary charge of the Foundation is to develop and distribute the Processing software. This includes the original Processing (Java), p5.js (Javascript), and Processing.py (Python). There is more information about the Foundation at http://foundation.processing.org/. +The primary charge of the Foundation is to develop and distribute the Processing software. This includes the original Processing (Java), p5.js (Javascript), and Processing.py (Python). There is more information about the Foundation at https://processingfoundation.org/.

    History

    - Processing was started by Ben Fry and Casey Reas in the spring of 2001, while both were graduate students at the MIT Media Lab within John Maeda's Aesthetics and Computation research group. Development continued in their free time while Casey pursued his artistic and teaching career and Ben pursued a Ph.D. and founded Fathom Information Design. Many of the ideas in Processing go back to Muriel Cooper's Visual Language Workshop, and it grew directly out of Maeda's Design By Numbers project, developed at the Media Lab and released in 1999. The Wiring and Arduino projects, in turn, grew out of Processing while Casey was teaching at the Interaction Design Institute Ivrea in Italy. Processing also prompted John Resig (jQuery) to build Processing.js, a JavaScript version that then inspired more related work such as the Khan Academy curriculum in computer science. Versions of Processing that use Python, Ruby, ActionScript, and Scala are also in development. Processing and its sister projects have inspired over twenty educational books. + Processing was started by Ben Fry and Casey Reas in the spring of 2001, while both were graduate students at the MIT Media Lab within John Maeda's Aesthetics and Computation research group. Development continued in their free time while Casey pursued his art and teaching career and Ben pursued a Ph.D. and founded Fathom Information Design. Many of the ideas in Processing go back to Muriel Cooper's Visual Language Workshop, and it grew directly out of Maeda's Design By Numbers project, developed at the Media Lab and released in 1999. The Wiring and Arduino projects, in turn, grew out of Processing while Casey was teaching at the Interaction Design Institute Ivrea in Italy.

    +

    For more information, please write to foundation@processing.org diff --git a/content/static/people.html b/content/static/people.html index ed14bc057..d406b648c 100755 --- a/content/static/people.html +++ b/content/static/people.html @@ -6,78 +6,57 @@

    People. Processing is a comm

    - Lead Developers
    + Project Leads
    Ben Fry and Casey Reas started Processing in Spring 2001 and continue to obsessively work on it. In 2012, they started the Processing Foundation along with Dan Shiffman, who formally joined as a third project lead.

    - Senior Developers
    - Andres Colubri (Boston), OpenGL / Video
    - Florian Jenett (Frankfurt), Forum
    - Elie Zananiri (Montreal), Contributed Libraries / Tools
    - Scott Murray (San Francisco), Website / Reference / UI
    + Developers
    + Andres Colubri (Boston), OpenGL / Video
    + Elie Zananiri (New York), Contributed Libraries / Tools
    + Samuel Pottinger (San Francisco), Processing Core

    -

    + -

    +

    Libraries, Tools
    - The core Processing software is augmented by libraries and tools contributed through the community. - These inventive extensions are a bright future for the project. We have a list of - Contributed Libraries and + The core Processing software is augmented by libraries and tools contributed through + the community. These inventive extensions are a bright future for the project. We have a + list of Contributed Libraries and Contributed Tools posted online. - These contributions can't be underestimated. For example, see how - Karsten Schmidt (London) has transformed Processing - through the toxiclibs library and how - Damien Di Fede (Austin) has extended the project - into programming sound through his minim - library.
    -

    - - - -

    - Fellowship Alumni
    - Lauren McCarthy (New York), Spring/Summer/Fall 2013
    - Greg Borenstein (New York), Spring/Summer 2013
    - Wilm Thoben (Los Angeles), Fall 2013/Winter 2014
    + These contributions can't be underestimated. For example, see how Karsten Schmidt (London) has + transformed Processing through the toxiclibs library and how Damien Di Fede (Austin) has extended + the project into programming sound through his minim library.

    - Developer Alumni
    + Alumni
    + Jakub Valtar (Brno), Processing Core
    + Scott Garner (New York), Hello Processing Website
    + Scott Murray (San Francisco), Website / Reference / UI
    + Gottfried Haider (Los Angeles), Processing for Pi
    + Florian Jenett (Frankfurt), Forum
    + Jamie Kosoy (San Francisco), Website
    + Manindra Moharana (San Diego), PDE / Core
    + James Grady (Boston), Visual Design
    + + Patrick Hebron, Video Library (Summer 2011)
    Peter Kalauskas, Library/Tool/Mode Install Utility (Summer, Fall 2011)
    Andreas Schlegel, Libraries (Winter 2008 - Summer 2011)
    Harshani Nawarathna, Processing Development Environment (Summer 2011)
    Cindy Chi, Reference Editing (Summer 2011)
    - Jonathan Feinberg, Parsing & Android Hacking (Spring 2011)
    + Jonathan Feinberg, Parsing & Android Hacking (Spring 2011)
    Chris Lonnen, Processing Development Environment (Summer 2011)
    Eric Jordan, Graphics Weapon (2007 - 2009)
    Tom Carden, Processing Hacks Director (Summer 2005 - Fall 2008)
    @@ -132,13 +111,9 @@

    People. Processing is a comm Burak Arikan, Turkish

    -

    -   -

    -

    We offer a special "Thank You!" to Sami Arola for writing the base of the original P3D - and Simon Greenwold for incorporting camera and lights. Tom Carden contributed great + and Simon Greenwold for incorporating camera and lights. Tom Carden contributed great energy by co-creating Processing Hacks and maintaining Processing Blogs. Andreas Schlegel did amazing work for over three years organizing the Contributed Libraries and building templates and documentation. diff --git a/content/static/support.html b/content/static/support.html index 91cb0754f..2a8f77f05 100644 --- a/content/static/support.html +++ b/content/static/support.html @@ -1,67 +1,48 @@ -

    Processing is free, open-source software. Your donation supports our worldwide community. We need your help!

    + -

    - One way to donate is to become a Processing Foundation Member. Please become a member today to help us continue to provide access to quality, free, open-source software. +

    + We need your help! Please support Processing by making a donation to the Processing Foundation. Your donation contributes to software development, education resources like code examples and tutorials, Fellowships, and community events. +

    + + + + + + + + + +
    + +
    + + -

    - The Processing Foundation was founded in 2012 after more than a decade of work with the original Processing software. The Foundation’s mission is to promote software literacy within the visual arts, and visual literacy within technology-related fields — and to make these fields accessible to diverse communities. Our goal is to empower people of all interests and backgrounds to learn how to program and make creative work with code, especially those who might not otherwise have access to these tools and resources. -

    +

    + The Processing Foundation was established in 2012 after more than a decade of work with the Processing software. The Foundation’s mission is to promote software literacy within the visual arts, and visual literacy within technology-related fields — and to make these fields accessible to diverse communities. Our goal is to empower people of all interests and backgrounds to learn how to program and make creative work with code, especially those who might not otherwise have access to these tools and resources. You can read more about the history of Processing in the short essay "A Modern Prometheus." +

    diff --git a/content/static/tutorials/android/index.html b/content/static/tutorials/android/index.html index f339fd9ba..75a355092 100644 --- a/content/static/tutorials/android/index.html +++ b/content/static/tutorials/android/index.html @@ -121,7 +121,7 @@

    Step Three: Running the App on a Device

    Some helpful tips when you’re working with Processing & Android:

    - I know I’ve said this before, but be patient. Canceling a process (ie. the emulator load or a device compile) can cause problems. If you do this inadvertently, you’re best off restarting Processing.

    -

    - Make sure to check out the Processing Android Wiki, where you’ll find some troubleshooting advice, and some tips on how to get your sketches working properly on your device.

    +

    - Make sure to check out the Processing Android Wiki, where you’ll find some troubleshooting advice, and some tips on how to get your sketches working properly on your device.

    This tutorial is for Processing version 2.0+. If you see any errors or have comments, please let us know. This tutorial is adapted from 'Processing & Android: Mobile App Development Made (Very) Easy' by Jer Thorp

    diff --git a/content/static/tutorials/arraylist/index.html b/content/static/tutorials/arraylist/index.html index 613ffee6a..5f24a6ad5 100644 --- a/content/static/tutorials/arraylist/index.html +++ b/content/static/tutorials/arraylist/index.html @@ -1,4 +1,4 @@ -In truth, we could use a simple array to manage our Particle objects. Some particle systems might have a fixed number of particles, and arrays are magnificently efficient in those instances. Processing also offers expand(), contract(), subset(), splice() and other methods for resizing arrays. However, for these examples, the Java class ArrayList (found in the java.util package: http://download.oracle.com/javase/6/docs/api/java/util/ArrayList.html) will prove to be the best solution.

Using an ArrayList is conceptually similar to a standard array, but the syntax is different. Here is some code (that assumes the existence of a generic Particle class) demonstrating identical results: first with an array, and second with an ArrayList. +In truth, we could use a simple array to manage our Particle objects. Some particle systems might have a fixed number of particles, and arrays are magnificently efficient in those instances. Processing also offers expand(), contract(), subset(), splice() and other methods for resizing arrays. However, for these examples, the Java class ArrayList (found in the java.util package: https://docs.oracle.com/javase/8/docs/api/java/util/ArrayList.html) will prove to be the best solution.

Using an ArrayList is conceptually similar to a standard array, but the syntax is different. Here is some code (that assumes the existence of a generic Particle class) demonstrating identical results: first with an array, and second with an ArrayList. // THE STANDARD ARRAY WAY int total = 10; diff --git a/content/static/tutorials/data/index-old.html b/content/static/tutorials/data/index-old.html index 0df744e1b..6221a4a80 100644 --- a/content/static/tutorials/data/index-old.html +++ b/content/static/tutorials/data/index-old.html @@ -17,7 +17,7 @@

    Daniel Shiffman

    Manipulating Strings

    - In Strings and Drawing Text, we touched on a few of the basic functions available in the Java String class, such as charAt(), toUpperCase(), equals(), and length(). These functions are documented on the Processing reference page for Strings. Nevertheless, in order to perform some more advanced data parsing techniques, we'll need to explore some additional String manipulation functions documented in the Java API. + In Strings and Drawing Text, we touched on a few of the basic functions available in the Java String class, such as charAt(), toUpperCase(), equals(), and length(). These functions are documented on the Processing reference page for Strings. Nevertheless, in order to perform some more advanced data parsing techniques, we'll need to explore some additional String manipulation functions documented in the Java API.

    @@ -518,7 +518,7 @@

    Threads

    Two examples that follow this methodology can be found under Topics --> Advanced Data in the Processing examples.

    -

    While using the thread() function is a very simple way of getting an independent thread, it should be noted that it is somewhat limited. Being able to make a thread object is a great deal more powerful, and this can be done by extending the Java Thread class.

    +

    While using the thread() function is a very simple way of getting an independent thread, it should be noted that it is somewhat limited. Being able to make a thread object is a great deal more powerful, and this can be done by extending the Java Thread class.

    diff --git a/content/static/tutorials/data/index.html b/content/static/tutorials/data/index.html index d45a525a6..ebafcce92 100644 --- a/content/static/tutorials/data/index.html +++ b/content/static/tutorials/data/index.html @@ -17,7 +17,7 @@

    Daniel Shiffman

    Manipulating Strings

    - In Strings and Drawing Text, we touched on a few of the basic functions available in the Java String, such as charAt(), toUpperCase(), equals(), and length(). These functions are documented on the Processing reference page for Strings. Nevertheless, in order to perform some more advanced data parsing techniques, we'll need to explore some additional String manipulation functions documented in the Java API. + In Strings and Drawing Text, we touched on a few of the basic functions available in the Java String, such as charAt(), toUpperCase(), equals(), and length(). These functions are documented on the Processing reference page for Strings. Nevertheless, in order to perform some more advanced data parsing techniques, we'll need to explore some additional String manipulation functions documented in the Java API.

    Let's take a closer look at the following two String functions: indexOf() and substring().

    indexOf() locates a sequence of characters within a string. It takes one argument — a search string — and returns a numeric value that corresponds to the first occurrence of the search string inside of the String object being searched.
    @@ -493,7 +493,7 @@

    Data that is not in a Standardized Format

    In code, this looks like:

    -int start      = stuff.indexOf("apples:" ) + 8;  // STEP 1 
    +int start      = stuff.indexOf("apples:" ) + 7;  // STEP 1 
     // The index where a string ends can be found by 
     // searching for that string and adding its length (here, 8).
     int end        = stuff.indexOf(".", start);      // STEP 2
    @@ -1404,6 +1404,34 @@ 

    Threads

    JSONObject json = loadJSONObject("http://time.jsontest.com/"); time = json.getString("time"); } + + +class Timer { + + int savedTime; + boolean running = false; + int totalTime; + + Timer(int tempTotalTime) { + totalTime = tempTotalTime; + } + + void start() { + running = true; + savedTime = millis(); + } + + boolean isFinished() { + int passedTime = millis() - savedTime; + if (running && passedTime > totalTime) { + running = false; + return true; + } else { + return false; + } + } + +}

    APIs

    diff --git a/content/static/tutorials/drawing/imgs/drawing-05.svg b/content/static/tutorials/drawing/imgs/drawing-05.svg index 0f55e2269..44653c110 100644 --- a/content/static/tutorials/drawing/imgs/drawing-05.svg +++ b/content/static/tutorials/drawing/imgs/drawing-05.svg @@ -1,166 +1,210 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -Example: - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/content/static/tutorials/eclipse/index.html b/content/static/tutorials/eclipse/index.html index b5084926c..1dde1915c 100644 --- a/content/static/tutorials/eclipse/index.html +++ b/content/static/tutorials/eclipse/index.html @@ -1,22 +1,22 @@

    Processing in Eclipse

    Shane White

    - -

    +

     

    diff --git a/content/static/tutorials/electronics/imgs/fg39-16.svg b/content/static/tutorials/electronics/imgs/fg39-16.svg index 46abb2371..92324f100 100644 --- a/content/static/tutorials/electronics/imgs/fg39-16.svg +++ b/content/static/tutorials/electronics/imgs/fg39-16.svg @@ -1,1112 +1,3907 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + +image/svg+xml \ No newline at end of file diff --git a/content/static/tutorials/electronics/index.html b/content/static/tutorials/electronics/index.html index 9777b0f8f..02b31bdcc 100644 --- a/content/static/tutorials/electronics/index.html +++ b/content/static/tutorials/electronics/index.html @@ -635,9 +635,10 @@

    Code

     // Read data from the serial port and set the position of a servomotor 
     // according to the value
    +#include <Servo.h>
     
     Servo myservo;                   // Create servo object to control a servo
    -int servoPin = 4;                // Connect yellow servo wire to digital I/O pin 4 
    +int servoPin = 3;                // Connect yellow servo wire to digital I/O pin 3 (must be PWM) 
     int val = 0;                     // Data received from the serial port
     
     void setup() {
    @@ -672,7 +673,12 @@ 

    Code

    noStroke(); frameRate(10); // Open the port that the board is connected to and use the same speed (9600 bps) - port = new Serial(this, 9600); + port = new Serial(this, 9600); // Comment this line if it's not the correct port + // If the above does not work uncomment the lines below to choose the correct port + // List all the available serial ports, preceded by their index number: + //printArray(Serial.list()); + // Instead of 0 input the index number of the port you are using: + //port = new Serial(this, Serial.list()[0], 9600); } void draw() { @@ -918,4 +924,4 @@

    Resources

    -

    This tutorial is for Processing version 3.0+. If you see any errors or have comments, please let us know. This work is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License.

    +

    The Long Version

    In order to use the Processing library to create our graphics while coding in Eclipse, we need to do a couple things. The first thing we need to do is import the Processing core as a library for our project, and the second is to set up our client class to take into consideration some of the processes (pun intended) that the Processing IDE does for us in the background.

    This guide is written for Processing 3+, with the intended audience of someone who has already downloaded Eclipse, but may have never used it before. If you are experienced with Java and Eclipse, you can jump to the bottom for a quick summary of the steps involved.

    Create a new Project

    First create a new project. It just needs to be a regular Java Project.

    File > New > Java Project

    -

    Let's name it 'Hello Processing'. Leave all the default settings and click Finish.

    +

    Let's name it 'Hello Processing'. Leave all the default settings and click Finish.

    Next, create a new class.

    File > New > Class

    -

    Let's name it 'UsingProcessing'. You can choose to include public static void main.

    -

    Creating a new Class

    +

    Let's name it 'UsingProcessing'. You can choose to include public static void main.

    +

    Creating a new Class

    We should now have a new class that probably looks like this:

    public class UsingProcessing {
    @@ -30,28 +30,28 @@ 

    Create a new Project

    Now that we have our project and client class ready to go, we need to get the Processing core as a library.

    The idea of Libraries

    -

    One of the most important aspects of Java (or nearly any programming environment) is the idea of a Library. A Library is a collection of code that performs related tasks. They can be one class, or many. Some Libraries are so powerful and robust that they can almost be considered a "Language" themselves. When you combine the Processing library with the Processing IDE, you end up with something that most people refer to as the Processing 'Language', but technically, at it's heart, it's a collection of Java code.

    +

    One of the most important aspects of Java (or nearly any programming environment) is the idea of a Library. A Library is a collection of code that performs related tasks. They can be one class, or many. Some Libraries are so powerful and robust that they can almost be considered a "Language" themselves. When you combine the Processing library with the Processing IDE, you end up with something that most people refer to as the Processing 'Language', but technically, at it's heart, it's a collection of Java code.

    To make it work, the Processing IDE does a lot of stuff for us in the background 'Java' environment in order to make it really easy for us as programmers to create sketches. However, to make full use of all the Java awesomeness at our disposal, it's helpful to use a more robust IDE, which is why we are jumping into Eclipse. So let's get Eclipse to use Processing as a Library.

    Import the Processing Core

    In order for Eclipse to see the code that makes up Processing, we need to import it into our project.

    File > Import > General > File System

    Click next. On Windows, click "Browse..." and select the Processing jar files inside PATH_TO_PROCESSING/core/library/. On OS X, do not use the "Browse..." button. Instead, use the "From directory:" field to manually enter the path to Processing's jar files, which is typically /Applications/Processing 3.app/Contents/Java/core/library/. At minimum, select the "core.jar" file inside the "library" folder.

    -

    Importing the Processing Core

    +

    Importing the Processing Core

    A .jar file is a compiled collection of Java code. The core.jar is the core of the Processing libraries, it has all the code that does the stuff that we are used to doing in Processing, like drawing shapes. Once we have it, we can make use of all the normal Processing commands that are found on the reference page.

    Click Finish. If you look at the Package Explorer, you'll notice that there is a new file in our project, called 'core.jar'.

    -

    A new file in our project!

    +

    A new file in our project!

    Now that we have the file in our project, we need to tell Eclipse that this file is part of the code base that is used to build, or compile and run, this project. Do this by right clicking on the core.jar, going to Build Path, and then Add to Build Path

    -

    Adding the core.jar to the build path

    +

    Adding the core.jar to the build path

    You'll notice the project will expand to have a new section called 'Referenced Libraries', where there is a new core.jar file. You can expand this to see a hierarchy of it's contents, if you are really interested.

    -

    A successful add to build path

    -

    We are finally ready to set up our client class (the class with our main function, where the program starts), to run the project like a Processing sketch.

    +

    A successful add to build path

    +

    We are finally ready to set up our client class (the class with our main function, where the program starts), to run the project like a Processing sketch.

    Setting up the Client Class

    -

    A Processing window is a special type of Java program called a PApplet. This is technically a Java Class, which has its own main function (or method) and does all kinds of fancy stuff that we don't need to worry about to create a new window and draw graphics onto it. In order for us to make use of the PApplet class, we want our program to BE a PApplet. To make this happen, we use the keyword extends in our class declaration. This will allow our class to 'inherit' all the PApplet class' functions and variables. Change the first line of code to be:

    +

    A Processing window is a special type of Java program called a PApplet. This is technically a Java Class, which has its own main function (or method) and does all kinds of fancy stuff that we don't need to worry about to create a new window and draw graphics onto it. In order for us to make use of the PApplet class, we want our program to BE a PApplet. To make this happen, we use the keyword extends in our class declaration. This will allow our class to 'inherit' all the PApplet class' functions and variables. Change the first line of code to be:

    public class UsingProcessing extends PApplet{

    You'll notice this will give you an error. This occurs because, although we have included the core.jar to our project, we still have to link to the library in the code. We do this by using an import statement, at the top of the Java file. Anytime we are going to reference a function, variable, or class outside of the Java file we are writing in, we need to tell Java where it is by importing it. Eclipse will help you by suggesting to do this. Hover over the error (where it's underlined in red) and choose from the options "Import 'PApplet' (processing.core)".

    -

    Import PApplet

    +

    Import PApplet

    This will auto add a new line of code to the top of the file: import processing.core.PApplet; You can also type this in yourself if you choose. This will allow Java to see all the public parts of the PApplet class.

    The next step is to simply start a PApplet application, and tell it to use this class,UsingProcessing, as the program to run. This is done by calling PApplet's main method and giving it the name of this class as a parameter.

    Add the following line to the main function (method), and if the TODO comment is still there, you can delete/replace it.

    @@ -71,11 +71,11 @@

    Setting up the Client Class

    } -

    NOTE: If your class is part of a package other than the default package, you must call PApplet's main using the package name as well, like this:

    +

    NOTE: If your class is part of a package other than the default package, you must call PApplet's main using the package name as well, like this:

    PApplet.main("packageName.ClassName");
    -

    At this point, you can run the program. If Eclipse asks, choose to run the program as a Java Application. Processing no longer extends the Applet class, so you can't run it as an Applet!

    +

    At this point, you can run the program. If Eclipse asks, choose to run the program as a Java Application. Processing no longer extends the Applet class, so you can't run it as an Applet!

    This will run a PApplet as if you had run an empty sketch. You will get a new 100x100 window open with a blank canvas!

    Now we are ready to add the final touches to be ready to program like we were before. After main(), add three new functions: settings()setup(), and draw(). It's just like we did in Processing, but you will also need to include the public declaration before the void declaration. Now we have this:

    @@ -127,7 +127,7 @@

    Setting up the Client Class

    }

    We did it! We have a Processing application running from Eclipse, and now we can take advantage of all the powerful tools that Eclipse has to offer. From here, you can develop your processing sketch to your heart's content.

    -

    The Short Version

    +

    The Short Version

    The quick break down of what we did here:

    1. Create a new Java Project
    2. @@ -137,7 +137,8 @@

      The Short Version

    3. Add a public void settings()public void setup(), and public void draw().
    4. Use the size() call inside of settings(), and other than that, use setup() and draw() like normal!
    -

    It runs!

    +

    It runs!

    +

     

    Processing in Eclipse with Multiple Classes

    Take a look at this example Processing sketch. The example is object-oriented and contains a class called "Stripe." In Processing, all classes are treated as "inner classes," meaning they are not individual entities unto themselves, but rather are classes inside of the larger PApplet. This is why you can do anything you can do in a PApplet inside of the Stripe class. You can draw onto the window calling rect() and access the PApplet variables such as width and height. To get this example working in Eclipse, it's perfectly reasonable to just copy it in as is and include the Stripe class code below setup() and draw() inside the parent PApplet class. However, the inner class methodology can quickly become unwieldy in the case of larger applications with lots and lots of classes.

    And so we find ourselves in need of a means for creating separate Java classes in Eclipse that we can use in conjunction with a Processing-based application.

    First thing first, we can put all the code that is not the Stripe class in a Java class like with the first example.

    import processing.core.*;
    @@ -220,7 +221,22 @@ 

    Processing in Eclipse with Multiple Classes


    and if you are in another class and have to refer to the "parent" PApplet:

    int pink = parent.color(255,200,200);
    -

     

    +

    Globally Available Functions

    +

    Pretty much anything you can find in the reference can be used in Eclipse the same way, with some concesssions to be made for proper Java syntax. For example, any of the mouse Event functions, including mouseClicked(), mousePressed(), mouseDragged(), and mouseWheel().

    +

    These can be added in the exact same way as setup(), and draw(), just by adding the keyword 'public' to the declaration. So, looking at the reference example of mousePressed():

    +
    void mousePressed() {
    +  if (value == 0) {
    +    ...
    +}
    +

    Would be declared instead as:

    +
    public void mousePressed() { 
    +  if (value == 0) {
    +    ...
    +}
    +

    That's all there is to it! The same process works for all the mouse, keyboard, and other event based functions.

    +

    Note, however, that these functions are inherited from PApplet, thus you will only be able to use them in your client class, and not in any other object classes.

    +

    Exporting in Eclipse

    +

    You can export a project from eclipse the same way you export any project in Eclipse. For more information, visit Eclipse's documentation. How to export a runnable .jar in Eclipse.

    This tutorial is for Processing version 3.0+. If you see any errors or have comments, please let us know. This work is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License.

    \ No newline at end of file + diff --git a/content/static/tutorials/gettingstarted/index.html b/content/static/tutorials/gettingstarted/index.html index 5def1e1a5..2ebe7335b 100644 --- a/content/static/tutorials/gettingstarted/index.html +++ b/content/static/tutorials/gettingstarted/index.html @@ -34,7 +34,7 @@

    Casey Reas and Ben Fry

    ./processing -

    With any luck, the main Processing window will now be visible. Everyone's setup is different, so if the program didn't start, or you're otherwise stuck, visit the troubleshooting page for possible solutions.

    +

    With any luck, the main Processing window will now be visible. Everyone's setup is different, so if the program didn't start, or you're otherwise stuck, visit the troubleshooting page for possible solutions.

    diff --git a/content/static/tutorials/index.html b/content/static/tutorials/index.html index 17369c6a1..7434e5bbb 100644 --- a/content/static/tutorials/index.html +++ b/content/static/tutorials/index.html @@ -294,16 +294,21 @@

    Text Tutorials. A collection

    Level: Advanced

    -
    - preview image -


    Anatomy of a Program
    - by J David Eisenberg

    -

    How do you analyze a problem and break it down into steps that the computer can do?

    -

    Level: Advanced

    + +
    + preview image +


    Anatomy of a Program
    + by J David Eisenberg

    +

    How do you analyze a problem and break it down into steps that the computer can do?

    +

    Level: Advanced

    +
    + +
    + - + Electronics diff --git a/content/static/tutorials/typography/index.html b/content/static/tutorials/typography/index.html index c71b0d284..931690834 100644 --- a/content/static/tutorials/typography/index.html +++ b/content/static/tutorials/typography/index.html @@ -156,7 +156,7 @@

    Draw text

    Vector Fonts

    - To work with fonts different than the default, more functions are needed to prepare a font to be used with Processing. The createFont() function is used to convert a TrueType font (.ttf) or OpenType font (.otf) so that is can display through text(). The textFont() function is used to define the current font to display. Any compatible font installed on the computer running Processing or stored in the sketch’s data folder may be used. The following short program is used to print the list of the available installed fonts to the console: + To work with fonts different than the default, more functions are needed to prepare a font to be used with Processing. The createFont() function is used to convert a TrueType font (.ttf) or OpenType font (.otf) so that it can display through text(). The textFont() function is used to define the current font to display. Any compatible font installed on the computer running Processing or stored in the sketch’s data folder may be used. The following short program is used to print the list of the available installed fonts to the console:

    diff --git a/content/static/tutorials/video/index.html b/content/static/tutorials/video/index.html
    index 7336bac6e..22ccf759b 100644
    --- a/content/static/tutorials/video/index.html
    +++ b/content/static/tutorials/video/index.html
    @@ -33,7 +33,7 @@ 

    Live Video

    Capture video;
    -Step 3. Initailize the Capture object. +Step 3. Initialize the Capture object.

    The Capture object “video” is just like any other object — to construct an object, you use the new operator followed by the constructor. With a Capture object, this code typically appears in setup().
    @@ -50,12 +50,12 @@ 

    Live Video

    Let’s walk through the arguments used in the Capture constructor.
      -
    • this: If you’re confused by what this means, you are not alone. Technically speaking, this refers to the instance of a class in which the word this appears. Unfortunately, such a definition is likely to induce head spinning. Anicer way to think of it is as a self-referential statement. After all, what if you needed to refer to your Processing program within your own code? You might try to say “me” or “I.” Well, these words are not available in Java, so instead you say this. The reason you pass this into the Capture object is you are telling it: “Hey listen, I want to do video capture and when the camera has a new image I want you to alert this sketch.”
    • -
    • 320: Fortunately, the first argument, this, is the only confusing one. 320 refers to the width of thevideo captured by the camera.
    • +
    • this: If you’re confused by what this means, you are not alone. Technically speaking, this refers to the instance of a class in which the word this appears. Unfortunately, such a definition is likely to induce head spinning. A nicer way to think of it is as a self-referential statement. After all, what if you needed to refer to your Processing program within your own code? You might try to say “me” or “I.” Well, these words are not available in Java, so instead you say this. The reason you pass this into the Capture object is you are telling it: “Hey listen, I want to do video capture and when the camera has a new image I want you to alert this sketch.”
    • +
    • 320: Fortunately, the first argument, this, is the only confusing one. 320 refers to the width of the video captured by the camera.
    • 240: The height of the video.
    -There are some cases, however, where the above will not do. For example, what if you have multiple cameras attached to your computer. How do you select the one you want to capture? In addition, in some rare cases, you might also want to specify a frame rate from the camera. For these cases, Processing will give you a list of all possible camera configurations via Capture.list(). You can display these in your message console, for example, by saying:
    +There are some cases, however, where the above will not do. For example, what if you have multiple cameras attached to your computer? How do you select the one you want to capture? In addition, in some rare cases, you might also want to specify a frame rate from the camera. For these cases, Processing will give you a list of all possible camera configurations via Capture.list(). You can display these in your message console, for example, by saying:
     printArray(Capture.list());
     
    @@ -81,6 +81,7 @@

    Live Video



    Step 5. Read the image from the camera. +

    There are two strategies for reading frames from the camera. I will briefly look at both and choose one forthe remainder of the examples in this chapter. Both strategies, however, operate under the same fundamental principle: I only want to read an image from the camera when a new frame is available to be read.

    @@ -115,7 +116,7 @@

    Live Video

    All of this is put together in the following code:
     // Step 1. Import the video library.
    -import processing video.
    +import processing.video.*;
     
     //Step 2. Declare a capture object.
     Capture video;
    @@ -146,7 +147,9 @@ 

    Live Video

     import processing.video.*;
     
    -Capture video;void setup() {  
    +Capture video;
    +
    +void setup() {
       size(320, 240);  
       video = new Capture(this, 320, 240); 
       video.start();
    @@ -297,14 +300,16 @@ 

    Recorded video

    }
    -Although Processing is by no means the most sophisticated environment for displaying and manipulating recorded video, there are some more advanced features available in the video library. There are function sfor obtaining the duration (length measured in seconds) of a video, for speeding it up and slowing it down, and for jumping to a specific point in the video (among others). If you find that performance is sluggish and the video playback is choppy, I would suggest trying the P2D or P3D renderers. +Although Processing is by no means the most sophisticated environment for displaying and manipulating recorded video, there are some more advanced features available in the video library. There are functions for obtaining the duration (length measured in seconds) of a video, for speeding it up and slowing it down, and for jumping to a specific point in the video (among others). If you find that performance is sluggish and the video playback is choppy, I would suggest trying the P2D or P3D renderers.

    Following is an example that makes use of jump() (jump to a specific point in the video) and duration() (returns the length of movie in seconds). In this example, if mouseX equals 0, the video jumps to the beginning. If mouseX equals width, it jumps to the end. Any other value is in between. The jump() function allows you to jump immediately to a point of time within the video. duration() returns the total length of the movie in seconds.
     import processing.video.*;
     
    -Movie movie;void setup() {  
    +Movie movie;
    +
    +void setup() {
       size(200, 200);  
       background(0);  
       movie = new Movie(this, "testmovie.mov");
    @@ -375,6 +380,8 @@ 

    Software mirrors



    For every square at column i and row j, I look up the color at pixel (i, j) in the video image and color it accordingly. See the following example with the new parts in bold:
    +import processing.video.*;
    +
     // Size of each cell in the grid, ratio of window size to video size
     int videoScale = 8;
     // Number of columns and rows in the system
    @@ -388,7 +395,8 @@ 

    Software mirrors

    cols = width/videoScale; rows = height/videoScale; background(0); - video = new Capture(this, cols, rows); + video = new Capture(this, cols, rows); + video.start() } // Read image from the camera @@ -535,13 +543,14 @@

    Software mirrors

    } void captureEvent(Capture video) { - // Read image from the camera video.read(); + // Read image from the camera + video.read(); } void draw() { video.loadPixels(); float newx = constrain(x + random(-20, 20), 0, width); - float newy = constrain(y + random(-20, 20), 0, height); + float newy = constrain(y + random(-20, 20), 0, height-1); // Find the midpoint of the line int midx = int((newx + x) / 2); diff --git a/contrib_generate/broken.conf b/contrib_generate/broken.conf index 0dfa3f8c7..39f170b32 100644 --- a/contrib_generate/broken.conf +++ b/contrib_generate/broken.conf @@ -25,7 +25,6 @@ 120 123 129 -130 136 141 144 diff --git a/contrib_generate/build_listing.py b/contrib_generate/build_listing.py index ee4dbd052..2c4a43b22 100755 --- a/contrib_generate/build_listing.py +++ b/contrib_generate/build_listing.py @@ -228,7 +228,7 @@ def missing_key(exports): key = missing_key(exports) if key: - print 'Error reading', prop_url + print 'Error missing key', prop_url print " No value for '%s'. Maybe it's a 404 page" % key continue # if no download is explicitly provided, use the default download url diff --git a/contrib_generate/skipped.conf b/contrib_generate/skipped.conf index f4e2bf989..fb4891e7a 100644 --- a/contrib_generate/skipped.conf +++ b/contrib_generate/skipped.conf @@ -1,6 +1,5 @@ 007 039 -041 050 051 052 diff --git a/contrib_generate/sources.conf b/contrib_generate/sources.conf index b5cf6c171..8fc82f839 100644 --- a/contrib_generate/sources.conf +++ b/contrib_generate/sources.conf @@ -1,10 +1,10 @@ -# Next ID: 222 +# Next ID: 273 # Increment after assigning ID to new contribution [Library : 3D] 001 \ https://github.com/remixlab/proscene/releases/download/latest/proscene.txt 006 \ http://www.die-seite.ch/colladaloader/colladaLoader.txt -009 \ http://www.wblut.com/hemesh/hemesh.txt +# 009 \ http://www.wblut.com/hemesh/hemesh.txt 017 \ http://mrfeinberg.com/peasycam/peasycam.txt # 022 \ http://fluidforms.eu/processing/fluid-forms-libs/download/FluidFormsLibs.txt 032 \ http://n.clavaud.free.fr/processing/library/picking/download/Picking.txt @@ -18,10 +18,13 @@ 120 \ https://simple-openni.googlecode.com/svn/trunk/SimpleOpenNI-2.0/dist/all/SimpleOpenNI.txt 123 \ http://igeo.jp/igeo.txt 130 \ https://github.com/codeanticode/planetarium/releases/download/latest/planetarium.txt -174 \ http://ixora.io/downloads/camera3D/Camera3D.txt +174 \ https://ixora.io/downloads/camera3D/Camera3D.txt 195 \ http://culebra.technology/culebra.txt 196 \ https://github.com/jrc03c/queasycam/releases/download/latest/queasycam.txt 215 \ http://maxlfarrell.gitlab.io/extruder/extruder.txt +244 \ http://giftedapprentice.com/ewbIK/ewbIK.txt +245 \ https://github.com/VisualComputing/nub/releases/download/latest/nub.txt +252 \ http://www.bdhont.net/lunar.txt [Library : Animation] 001 \ https://github.com/remixlab/proscene/releases/download/latest/proscene.txt @@ -31,7 +34,12 @@ 062 \ http://www.lagers.org.uk/processing/sprites/Sprites.txt 083 \ http://rdlester.github.com/hermes/downloads/hermes.txt 095 \ https://dl.dropbox.com/u/87680069/frames.txt -219 \ http://teddavis.org/xyscope/download/XYscope.txt +219 \ https://teddavis.org/xyscope/download/XYscope.txt +231 \ http://objectstothinkwith.com/tracer/tracer.txt +244 \ http://giftedapprentice.com/ewbIK/ewbIK.txt +245 \ https://github.com/VisualComputing/nub/releases/download/latest/nub.txt +253 \ https://ztdp.ca/projects/school/Green/Green.txt +272 \ https://fox-gieg.com/patches/processing/libraries/tiltProcessing/tiltProcessing.txt [Library : Compilation] 004 \ http://staff.city.ac.uk/~jwo/giCentre/utils/gicentreUtils.txt @@ -42,12 +50,12 @@ [Library : Data] 008 \ http://www.saint-clair.net/download/gml4u/GML4U.txt -011 \ http://www.shiffman.net/p5/libraries/sftp/sftp.txt +011 \ https://github.com/shiffman/SFTP-Processing/releases/download/latest/sftp.txt 012 \ http://www.shiffman.net/p5/libraries/qrcode/qrcodeprocessing.txt 040 \ http://r-s-g.org/carnivore/download/carnivore_p5lib.txt # 042 \ http://wyldco.com/romefeeder/download/romefeeder.txt 044 \ http://www.reades.com/MapThing/MapThing.txt -053 \ http://mrzl.net/yahooweather/YahooWeather.txt +#053 \ http://mrzl.net/yahooweather/YahooWeather.txt #404# 065 \ http://blog.stainpixels.com/public/share.txt 072 \ http://sojamo.de/libraries/oscp5/oscP5.txt 073 \ http://ubaa.net/shared/processing/udp/udp.txt @@ -60,7 +68,7 @@ #404# 128 \ http://dasmithii.com/GNet.txt 133 \ https://raw.githubusercontent.com/nok/redis-processing/master/download/Redis.txt 135 \ https://temboo.com/files/temboo-processing.txt -137 \ http://shiffman.net/p5/libraries/httprequests_processing/httprequests_processing.txt +137 \ https://github.com/runemadsen/HTTP-Requests-for-Processing/releases/download/latest/httprequests_processing.txt 144 \ http://unfoldingmaps.org/Unfolding.txt 175 \ https://github.com/alexandrainst/processing_websockets/releases/download/latest/webSockets.txt 183 \ https://github.com/onlylemi/processing-android-capture/releases/download/latest/AndroidCaptureForProcessing.txt @@ -68,6 +76,13 @@ 203 \ https://github.com/OliverColeman/hivis/releases/download/latest/HiVis.txt 206 \ https://ap-sync.github.io/libs/AP_sync_processing/APsync.txt 208 \ https://github.com/gohai/processing-simpletweet/releases/download/latest/processing-simpletweet.txt +229 \ https://github.com/Shinhoo/Wooting-Keyboard-Library/releases/download/lastest/WootingKeyboard.txt +230 \ https://github.com/cansik/artnet4j/releases/download/latest/artnet4j.txt +241 \ http://agathelenclen.fr/downloads/Squarify.txt +248 \ https://github.com/runwayml/processing-library/releases/download/latest/RunwayML.txt +262 \ https://github.com/SamuelAl/SQuelized-for-Processing/releases/latest/download/SQuelized.txt +267 \ https://github.com/cansik/deep-vision-processing/releases/download/contribution/deepvision.txt +270 \ https://ronghaoliang.page/Weka4P/download/Weka4P.txt [Library : Fabrication] # 078 \ http://s373.net/code/marchingcubes/download/marchingcubes.txt @@ -81,6 +96,9 @@ 195 \ http://culebra.technology/culebra.txt 204 \ https://github.com/thwegene/OCT/releases/download/latest/OCT.txt 214 \ http://www.garciadelcastillo.es/dashedlines/dashedlines.txt +231 \ http://objectstothinkwith.com/tracer/tracer.txt +237 \ http://gicentre.org/handy/handy.txt +241 \ http://agathelenclen.fr/downloads/Squarify.txt [Library : GUI] 001 \ https://github.com/remixlab/proscene/releases/download/latest/proscene.txt @@ -90,13 +108,16 @@ 058 \ http://www.sojamo.de/libraries/controlP5/controlP5.txt # 061 \ https://dl.dropbox.com/u/87680069/piccolo2d.txt 180 \ http://interfascia.berg.industries/download/interfascia.txt +224 \ https://github.com/BillKujawa/meter/releases/download/latest/meter.txt +237 \ http://gicentre.org/handy/handy.txt +256 \ https://github.com/Milchreis/uibooster-for-processing/releases/latest/download/UiBooster.txt [Library : Hardware] 015 \ http://www.shiffman.net/p5/libraries/sms/sms.txt 024 \ https://github.com/firmata/processing/releases/download/latest/processing-arduino.txt 028 \ http://projects.formatlos.de/ambientlightsensor/download/AmbientLightSensor.txt # 064 \ http://www.muvium.com/frappuccino/frappuccino.txt -066 \ http://ketailibrary.org/ketai.txt +066 \ http://ketai.org/ketai.txt 071 \ http://motscousus.com/stuff/2011-01_dmxP512/dmxP512.txt 090 \ https://dl.dropbox.com/u/87680069/LeapMotion.txt # 102 \ http://s176381904.onlinehome.fr/processing/MoveLib/download/MoveLib.txt @@ -108,27 +129,33 @@ 188 \ http://developers.gausstoys.com/processing/GaussSense.txt 189 \ http://ciaron.net/hpglgraphics/download/hpglgraphics.txt 190 \ https://github.com/gohai/processing/releases/download/latest/io.txt -197 \ https://github.com/sgeigers/Phidgets-For-Processing/releases/download/latest/PhidgetsForProcessing.txt +# 197 \ https://github.com/sgeigers/Phidgets-For-Processing/releases/download/latest/PhidgetsForProcessing.txt 211 \ https://github.com/diwi/PS3Eye/releases/download/latest/PS3Eye.txt 218 \ https://github.com/cansik/sweep-processing/releases/download/latest/SweepProcessing.txt -219 \ http://teddavis.org/xyscope/download/XYscope.txt +219 \ https://teddavis.org/xyscope/download/XYscope.txt +224 \ https://github.com/BillKujawa/meter/releases/download/latest/meter.txt +225 \ http://web.tecnico.ulisboa.pt/augusto.esteves/GazeTrack/GazeTrack.txt +238 \ https://github.com/cansik/realsense-processing/releases/download/contributed/RealSenseProcessing.txt +239 \ http://skweezee.net/processing/download/SkweezeeForProcessing.txt +266 \ https://github.com/sgeigers/SimplePhidgets/releases/download/latest/SimplePhidgets.txt +268 \ http://github.com/jaysonh/Dmx4Artists/releases/latest/download/Dmx4Artists.txt [Library : I/O] 001 \ https://github.com/remixlab/proscene/releases/download/latest/proscene.txt 016 \ http://www.silentlycrashing.net/ezgestures/files/ezgestures.txt 025 \ http://jorgecardoso.eu/processing/NXTComm/NXTComm.txt 026 \ http://jorgecardoso.eu/processing/MindSetProcessing/download/MindsetProcessing.txt -039 \ https://github.com/codeanticode/tablet/releases/tag/latestv2/Tablet.txt +039 \ https://github.com/codeanticode/tablet/releases/download/latestv2/Tablet.txt 060 \ https://dl.dropbox.com/u/87680069/gamepad.txt 067 \ http://www.graffitiresearchlab.de/wp-content/uploads/proJMS.txt 084 \ http://iddi.github.io/oocsi-processing/oocsi.txt 091 \ http://n-e-r-v-o-u-s.com/tools/obj/OBJExport.txt -097 \ http://pif.github.com/android-select-file/download/SelectFile.txt +097 \ https://andrusiv.com/android-select-file/download/SelectFile.txt 098 \ http://vialab.science.uoit.ca/smt/dl/SMT.txt 105 \ http://paulhertz.net/ignocodelib/download/IgnoCodeLib.txt 121 \ https://github.com/codeanticode/tablet/releases/download/latest/Tablet.txt 136 \ http://www.extrapixel.ch/processing/gifAnimation/gifAnimation.txt -139 \ http://erniejunior.github.io/VSync-for-Processing/download/VSync.txt +139 \ http://ernestum.github.io/VSync-for-Processing/download/VSync.txt 143 \ http://www.lagers.org.uk/processing/gamecontrol/GameControlPlus.txt 167 \ http://www.lagers.org.uk/processing3/gamecontrol/GameControlPlus.txt 168 \ http://transfluxus.github.io/SimpleHTTPServer/download/SimpleHTTPServer.txt @@ -143,6 +170,12 @@ 206 \ https://ap-sync.github.io/libs/AP_sync_processing/APsync.txt 209 \ https://github.com/gohai/processing-simplereceiptprinter/releases/download/latest/processing-simplereceiptprinter.txt 217 \ https://pierdr.github.io/Tramontana-for-Processing/tramontana.txt +229 \ https://github.com/Shinhoo/Wooting-Keyboard-Library/releases/download/lastest/WootingKeyboard.txt +232 \ https://github.com/haschdl/pLaunchController/releases/download/latest/pLaunchController.txt +239 \ http://skweezee.net/processing/download/SkweezeeForProcessing.txt +247 \ https://github.com/orgicus/image-sequence-player/releases/download/latest/ImageSequencePlayer.txt +258 \ https://github.com/Transmedia-Gx/grab/releases/latest/download/Grab.txt +269 \ http://augmenta-tech.com/libs/processing/Augmenta.txt [Library : Language] 063 \ http://rednoise.org/rita/rita.txt @@ -157,11 +190,13 @@ 131 \ http://www.lagers.org.uk/processing/qscript/QScript.txt 156 \ http://www.lagers.org.uk/processing/jasmine/Jasmine.txt 203 \ https://github.com/OliverColeman/hivis/releases/download/latest/HiVis.txt +251 \ https://github.com/pallav12/matrixMath-for-processing/releases/download/latest/MatrixMath.txt [Library : Other] 093 \ http://www.lagers.org.uk/processing/pathfinder/Path_Finder.txt 157 \ http://www.lagers.org.uk/processing/steganos/Steganos.txt 185 \ http://softlab.pt/ptmx/ptmx.txt +253 \ https://ztdp.ca/projects/school/Green/Green.txt [Library : Simulation] 018 \ http://www.ricardmarxer.com/fisica/download/fisica.txt @@ -180,6 +215,8 @@ 195 \ http://culebra.technology/culebra.txt 201 \ https://github.com/diwi/PixelFlow/releases/download/latest/PixelFlow.txt 216 \ https://github.com/diwi/LiquidFunProcessing/releases/download/latest/LiquidFunProcessing.txt +244 \ http://giftedapprentice.com/ewbIK/ewbIK.txt +261 \ https://github.com/dennisppaul/teilchen/releases/latest/download/teilchen.txt [Library : Sound] 153 \ https://github.com/processing/processing-sound/releases/download/latest/sound.txt @@ -191,7 +228,11 @@ 147 \ http://code.compartmental.net/minim/distro/minim_for_processing.txt 151 \ https://corajr.github.io/loom/download/loom.txt 170 \ https://github.com/shlomihod/cassette/releases/download/latest/cassette.txt -219 \ http://teddavis.org/xyscope/download/XYscope.txt +219 \ https://teddavis.org/xyscope/download/XYscope.txt +254 \ http://www.kramann.info/ComposingForEveryone.txt +260 \ https://github.com/sphaero/procmod/releases/latest/download/procmod.txt +264 \ https://github.com/dennisppaul/wellen/releases/latest/download/wellen.txt +271 \ https://www.robertesler.com/software/Pd4P3.txt [Library : Utilities] 001 \ https://github.com/remixlab/proscene/releases/download/latest/proscene.txt @@ -219,23 +260,32 @@ 192 \ https://github.com/barelief/freeTransform-processing/releases/download/latest/FreeTransform.txt 193 \ http://shiffman.net/p5/libraries/processing3/mpe/mpe.txt 201 \ https://github.com/diwi/PixelFlow/releases/download/latest/PixelFlow.txt -202 \ http://ixora.io/downloads/colorblindness/ColorBlindness.txt +202 \ https://ixora.io/downloads/colorblindness/ColorBlindness.txt 207 \ https://github.com/Lord-of-the-Galaxy/Timing-Utilities/releases/download/latest/timing_utils.txt 210 \ http://cagewebdev.com/colorharmony/colorharmony.txt 212 \ https://github.com/cansik/processing-postfx/releases/download/latest/PostFX.txt 213 \ https://github.com/AlexPoupakis/mouse2DTransformations/releases/download/latest/Mouse2DTransformations.txt 217 \ https://pierdr.github.io/Tramontana-for-Processing/tramontana.txt +229 \ https://github.com/Shinhoo/Wooting-Keyboard-Library/releases/download/lastest/WootingKeyboard.txt +235 \ https://www.barkmin.eu/processing-library-scratch/download/scratch.txt +240 \ https://commonpike.github.io/nl.kw.processing.portmods/dist/PortMods.txt +245 \ https://github.com/VisualComputing/nub/releases/download/latest/nub.txt +246 \ https://github.com/federico-pepe/nice-color-palettes/releases/download/latest/NiceColorPalettes.txt +248 \ https://github.com/runwayml/processing-library/releases/download/latest/RunwayML.txt +255 \ https://bdhont.net/LiveBrush.txt +257 \ https://rect.dev/processing/infinidecimal/GRInfinidecimalCanvas.txt +258 \ https://github.com/Transmedia-Gx/grab/releases/latest/download/Grab.txt [Library : Typography] 038 \ http://www.ricardmarxer.com/geomerative/geomerative.txt 088 \ https://raw.github.com/andreaskoller/Fontastic/master/download/Fontastic.txt -116 \ https://github.com/prisonerjohn/NextText/releases/download/latest/NextText.txt +# 116 \ https://github.com/prisonerjohn/NextText/releases/download/latest/NextText.txt [Library : Video & Vision] 150 \ https://github.com/processing/processing-video/releases/download/latest/video.txt 013 \ http://shiffman.net/p5/libraries/openkinect_processing/openkinect_processing.txt 023 \ http://www.v3ga.net/processing/BlobDetection/blobDetection.txt -041 \ https://github.com/Syphon/Processing/releases/download/latestv2/Syphon.txt +041 \ https://github.com/Syphon/Processing/releases/latest/download/Syphon.txt # 059 \ http://thomasdiewald.at/processing/libraries/dLibs_freenect/download/dLibs_freenect.txt # 077 \ http://s373.net/code/flob/download/flob.txt # 081 \ http://ubaa.net/shared/processing/opencv/download/opencv.txt @@ -243,7 +293,7 @@ 132 \ https://github.com/atduskgreg/opencv-processing/releases/download/latest/opencv_processing.txt 134 \ http://decoder.x10host.com/blobscanner/blobscanner.txt 146 \ http://boofcv.org/processing/boofcv_processing.txt -148 \ https://github.com/Syphon/Processing/releases/download/latest/Syphon.txt +# 148 \ https://github.com/Syphon/Processing/releases/download/latest/Syphon.txt 149 \ http://www.magicandlove.com/software/Kinect4WinSDK.txt 161 \ http://codigogenerativo.com/KinectPV2.txt 176 \ http://www.stefanobaldan.com/projects/ipcapture/download/IPCapture.txt @@ -251,6 +301,10 @@ 186 \ https://github.com/leadedge/SpoutProcessing/releases/download/latest/spout.txt 201 \ https://github.com/diwi/PixelFlow/releases/download/latest/PixelFlow.txt 211 \ https://github.com/diwi/PS3Eye/releases/download/latest/PS3Eye.txt +222 \ https://pierdr.github.io/tramontanaCV/download/tramontanaCV.txt +223 \ https://github.com/nyatla/NyARToolkit-for-Processing/releases/download/latest/nyar4psg.txt +227 \ https://github.com/Milchreis/processing-imageprocessing/releases/download/latest/processing-imageprocessing.txt +236 \ http://softlab.pt/VLCJVideo/VLCJVideo.txt [Examples : Books] 154 \ http://shiffman.net/p5/examples/natureofcode.txt @@ -258,9 +312,13 @@ 165 \ https://processing.org/handbook/handbook_2e.txt 166 \ https://processing.org/books/gswp_2e.txt 205 \ http://mad4j.github.io/book-mdpc/book-mdpc.txt +265 \ https://codingart-book.github.io/examples/CodingArtBookExamples.txt [Examples : ] 194 \ http://damellis.github.io/wovns-processing-examples/WOVNS.txt +226 \ https://github.com/Apress/processing-for-android/releases/download/latest/processing-for-android-examples.txt +243 \ https://coding-creative.dringtech.com/examples/coding-creative-examples.txt +249 \ https://github.com/jeremydouglass/rosetta_examples_p5/releases/latest/download/rosetta_examples_p5.txt [Tool : ] 020 \ https://dl.dropboxusercontent.com/u/69944346/ColorSelectorPlus/ColorSelectorPlusTool.txt @@ -278,7 +336,12 @@ 181 \ https://github.com/joelmoniz/Shape-Sketch/releases/download/latest/ShapeSketch.txt 182 \ https://github.com/rzats/font-highlighting-editor/releases/download/latest/FontHighlightingEditor.txt 191 \ https://github.com/gohai/processing-uploadtopi/releases/download/latest/UploadToPiTool.txt -# 221 \ http://jonathan.dahlberg.media/ecc/ecc.txt +221 \ http://jonathan.dahlberg.media/ecc/ecc.txt +228 \ https://perceptualcolor.org/distribution/PerceptualColorPicker/download/PerceptualColorPicker.txt +233 \ https://github.com/jaewhyun/GettingStarted/releases/download/latest/GettingStarted.txt +234 \ https://github.com/jaewhyun/ReferenceTool/releases/download/latest/ReferenceTool.txt +242 \ https://jwilder4690.github.io/tools/ArtStation/ArtStation.txt +263 \ http://jonathan.dahlberg.media/processing2js/Processing2JSTool.txt [Mode : ] 070 \ http://bezier.de/processing/modes/CoffeeScriptMode.txt @@ -286,8 +349,9 @@ 101 \ https://github.com/processing/processing-android/releases/download/latest/AndroidMode.txt # 122 \ http://galsasson.com/tweakmode/tweakmode.txt # 124 \ http://download.processing.org/pdeX.txt -142 \ http://py.processing.org/PythonMode.txt +# 142 \ http://py.processing.org/PythonMode.txt 162 \ https://github.com/joelmoniz/REPLmode/releases/download/latest/REPLMode.txt -169 \ http://py.processing.org/3/PythonMode.txt +169 \ https://py.processing.org/3/PythonMode.txt 199 \ https://github.com/fathominfo/processing-p5js-mode/releases/download/latest/p5jsMode.txt -220 \ http://gaocegege.com/Processing.R/RLangMode.txt +220 \ https://github.com/processing-r/Processing.R/releases/latest/download/RLangMode.txt +250 \ https://github.com/Izza11/shader-mode/releases/download/latest/ShaderMode.txt diff --git a/css/style.css b/css/style.css index f7b639c5a..65fd77ba4 100755 --- a/css/style.css +++ b/css/style.css @@ -7,12 +7,10 @@ Reworked by CR, 23 Sep 2011 Reworked by Jon Gacnik, 19 Feb 2013 Created: 2005.08.29 04:28PM -Last Modified: 2014.11.15 by Scott Murray +Last Modified: 2019.07.26 by Casey Reas to remove Foundation Site CSS "-f" */ - - @font-face { font-family: 'theSerifItalic'; src: url(fonts/TheSerif_B4_Italic.eot), @@ -54,7 +52,6 @@ Last Modified: 2014.11.15 by Scott Murray } - /* ================ GLOBAL ================== */ body { @@ -70,7 +67,7 @@ body { -webkit-text-size-adjust: none; font-size : 100%; - font-size : 0.79em; + font-size : 0.85em; /* 0.79em; */ font-weight : normal; line-height : 1.5em; color : #252525; @@ -79,6 +76,7 @@ body { img { border: 0px solid #000000; } a { + cursor: pointer; text-decoration: none; font-weight: normal; color: #2c7bb5; @@ -102,6 +100,7 @@ a.large-link:before { content: ''; } + /* ================ COVER SLIDESHOW ================== */ #slideshow { @@ -127,7 +126,6 @@ a.large-link:before { } - /* ================ LAYOUT ================== */ #container { @@ -137,7 +135,6 @@ a.large-link:before { } - /* ================ RIBBON ================== */ #ribbon { @@ -179,6 +176,8 @@ a.large-link:before { border-right: 1px solid #1a1a1a; } + + #ribbon ul.right li { float: right; border-left: 1px solid #1a1a1a; @@ -209,12 +208,48 @@ a.large-link:before { font-weight: bold; } +#ribbon-announce { + text-align: center; + width: 900px; + height: auto; + background-color: #d1f94e; + background: linear-gradient(to bottom, #1d517e, #d1f94e); + margin-bottom: 30px; /* added when placed below the header */ +} + +#ribbon-announce ul { + display: inline-block; + margin: 0; + padding: 0; +} + +#ribbon-announce ul.center { + float: center; +} + +#ribbon-announce ul li { + display: inline-block; + margin: 0; + padding: 6px 10px 5px 10px; + list-style: none; +} + +#ribbon-announce ul.center li { + float: center; +} + +#ribbon-announce ul li a { + color: white; + font-weight: bold; +} + /* ================ HEADER ================== */ + #header { width: 900px; height: 106px; - margin-bottom: 30px; + margin-bottom: 30px; /* was 30px, but changed to 0 when ribbon placed below header */ overflow: hidden; background: #0c2033 url(../img/processing-web.png) center center no-repeat; background-position: bottom; @@ -222,16 +257,6 @@ a.large-link:before { position: relative; } -#header-f { - width: 900px; - height: 106px; - margin-bottom: 30px; - overflow: hidden; - background: #0c2033 url(/images/processing-site.png) center center no-repeat; - background-size: 900px 106px; - position: relative; -} - #header .processing-logo { width: 206px; height: 38px; @@ -243,17 +268,6 @@ a.large-link:before { background-image: linear-gradient(transparent, transparent), url(../img/processing-logo.svg); } -#header-f .processing-logo { - width: 370px; - height: 38px; - margin: 20px 0 0 30px; - /* -- NEW FOUNDATION LOGO GOES HERE -- */ - background: transparent url(/images/processing-foundation-logo.svg) center center no-repeat; - background-image: -webkit-linear-gradient(transparent, transparent), url(/images/processing-foundation-logo.svg); - background-image: -moz-linear-gradient(transparent, transparent), url(/images/processing-foundation-logo.svg); - background-image: linear-gradient(transparent, transparent), url(/images/processing-foundation-logo.svg); -} - #header .processing-logo.no-cover:before { position: relative; top: 3px; @@ -262,14 +276,6 @@ a.large-link:before { content: '\2039'; } -#header-f .processing-logo.no-cover:before { - position: relative; - top: 3px; - left: -18px; - font-size: 24px; - content: '\2039'; -} - #Overview2 .processing-logo.no-cover:before { position: relative; top: 3px; @@ -284,23 +290,11 @@ a.large-link:before { color: white; } -#header-f a { - font-family: 'theSerif', 'Enriqueta', georgia, times, sans-serif; - text-decoration: none; - border: none; - color: white; -} - #header h1 { display: none; float: left; } -#header-f h1 { - display: none; - float: left; -} - #header form { position: absolute; top: 20px; @@ -309,14 +303,6 @@ a.large-link:before { color: #959595; } -#header-f form { - position: absolute; - top: 20px; - right: 5px; - width: 176px; - color: #959595; -} - #header form input { float: left; border: 1px solid #136796; @@ -328,29 +314,12 @@ a.large-link:before { color: #959595; } -#header-f form input { - float: left; - border: 1px solid #136796; - outline: none; - height: 18px; - background: #fff; - font-family: 'theSerif', 'Enriqueta', georgia, times, serif; - font-size: 1em; - color: #959595; -} - #header form input[type="text"]{ padding-left: 3px; width: 127px; border-right: none; } -#header-f form input[type="text"]{ - padding-left: 3px; - width: 127px; - border-right: none; -} - #header form input[type="submit"]{ height: 22px; width: 22px; @@ -362,21 +331,8 @@ a.large-link:before { cursor: pointer; } -#header-f form input[type="submit"]{ - height: 22px; - width: 22px; - border-left: none; - background: white url(/images/search-f.svg) center center no-repeat; - background-image: -webkit-linear-gradient(transparent, transparent), url(/images/search-f.svg); - background-image: -moz-linear-gradient(transparent, transparent), url(/images/search-f.svg); - background-image: linear-gradient(transparent, transparent), url(/images/search-f.svg); - cursor: pointer; -} - #header form p { margin: 0; } -#header-f form p { margin: 0; } - /* ================ NAVBAR ================== */ #navigation { @@ -407,6 +363,7 @@ a.large-link:before { position: relative; } + /* ================ FOOTER ================== */ #footer { @@ -428,26 +385,6 @@ a.large-link:before { padding-top: 10px; } -/* === FOUNDATION FOOTER === */ - -#footer-f { - clear: both; - padding: 100px 30px 20px 30px; - line-height: 23px; - color: #959595; -} -#footer-f a { - color: #959595; - border-bottom: 1px solid #CECECE; -} -#footer-f #copyright, -#footer-f #colophon { - -} -#footer-f #copyright { - border-top: 1px solid #A6BCCF; - padding-top: 10px; -} /* ================ TYPOGRAPHY ================== */ @@ -524,13 +461,12 @@ li {margin-bottom: 1em; } .large-header .black { color: #000; } .error { color: #f00; margin: 0; } -/* ================ UI Elements ================== */ - - /* ================== RANDOM CLASSES =============== */ + .clear { clear: both; } + /* ================== PAGE SPECIFIC CSS =============== */ /**************************************************************** Cover ***/ @@ -678,15 +614,8 @@ dl.network dt { font-style: normal; } dl.network dd { margin: 0; } dl.network dd.date { color: #999999; margin-bottom: 1em; } -//p.network { margin: 0 23px 1em 0; width:200px; } -//p.network span.date { color: #999999; } - p.exhibition-nav { margin-top: 20px; margin-bottom: 10px; } -/**************************************************************** Foundation ***/ - -.foundation-p { line-height: 0em; } - /**************************************************************** Reference ***/ @@ -694,8 +623,6 @@ p.exhibition-nav { margin-top: 20px; margin-bottom: 10px; } #Language h5 a { float: left; margin-left: -30px; } - - .skinny { margin-left : 0px; margin-right : 50px; @@ -711,7 +638,7 @@ p.exhibition-nav { margin-top: 20px; margin-bottom: 10px; } margin-bottom: 20px; } -.ref-notice { margin: 0 0 2.5em 0; color: #FF3399; clear: both; margin-right: 40px;} +.ref-notice { margin: 0 0 2.5em 0; color: #666666; clear: both; margin-right: 40px;} .ref-item { margin-bottom: 60px; } .ref-item th { width: 100px; font-weight: bold; text-align: left; vertical-align: top; } @@ -879,8 +806,6 @@ div.ref-col { /**************************************************************** download ***/ -/* download */ - #Download .download ul { list-style: none; margin: 0; padding: 0; } #Download span.version-date { color: #959595; } #Download h5 { @@ -1059,16 +984,13 @@ div.ref-col { /************************************************************** contribute ***/ -/*#Contribute h1 { margin-bottom: 0; }*/ #Contribute .message { margin-top: 0; margin-right: 40px; } #Contribute .threecol { float: left; width: 210px; margin-right: 20px; } #Contribute .threecol p { margin-bottom: 2em; } - /************************************************************** learning ***/ -/*#Learning h1 { margin-bottom: 0; margin-top: 0;}*/ #Learning .message { margin-top: 0; margin-right: 40px; } #Learning .threecol { float: left; width: 200px; margin-right: 30px; margin-top: 0px;} #Learning .threecol p { margin-bottom: 2em; } @@ -1080,13 +1002,10 @@ div.ref-col { .doc-float { margin-right: 40px;} - - h2 { margin-bottom: 0; margin-top: 0;} .example-notice { margin: -1.0em 0 2.5em 0; color: #FF3399; clear: both; margin-right: 40px;} - #Copyright p { margin-right: 20px; } @@ -1097,37 +1016,6 @@ h2 { margin-bottom: 0; margin-top: 0;} #Tutorials .colthree { width: 224px; float: left; margin-right: 20px; } #Tutorials h2 { margin: 0 0 20px 0; font-size: 1em; } -/*#Tutorials p { - margin-top: 2.0em; - margin-bottom: 2.0em; - font-size : 1.0em; - font-weight : normal; - line-height : 2.0em; - }*/ - -/*#Tutorials h3 { - font-family : Verdana, Geneva, Arial, Helvetica, sans-serif; - font-size : 1.3em; - font-weight : bold; - margin-bottom : 0.4em; - margin-top : 1.8em; -} - -#Tutorials h5 { - font-family : Verdana, Geneva, Arial, Helvetica, sans-serif; - font-weight : bold; - font-size : 1.0em; - margin-bottom : 0.4em; - margin-top : 1.4em; -}*/ - -/*#Tutorials h1 { - font-family : Verdana, Geneva, Arial, Helvetica, sans-serif; - font-size : 2.0em; - font-weight : normal; - font-style : normal; -}*/ - /*--------------------TUTORIAL HEADER SPACING------------------*/ .Tutorials { line-height: 0em; } @@ -1176,6 +1064,7 @@ h2 { margin-bottom: 0; margin-top: 0;} background-color: #eee; } +/* #Tutorials p.txt { margin-top: 0em; margin-bottom: 2em; @@ -1183,10 +1072,10 @@ h2 { margin-bottom: 0; margin-top: 0;} font-weight: normal; line-height: 200%; } +*/ /************************************************************** Books ***/ -/*#Books h1 { margin-bottom: 0; margin-top: 0;}*/ #Books td { vertical-align: top; font-size: 1.0em} @@ -1210,9 +1099,6 @@ h2 { margin-bottom: 0; margin-top: 0;} margin-top: 30px; } - - - #Tools-index h5 { margin-bottom: 0; font-size: 1em; } #Tools-index .twocol p { margin-top: 0; } .lib-nav { display: block; @@ -1231,7 +1117,6 @@ h2 { margin-bottom: 0; margin-top: 0;} #Tools h4 { font-size: 1em; margin-bottom: .5em; } #Tools h4 a {float:left; margin-left:-30px; martin-top:-5px; } - #Tools .threecol { float: left; width: 210px; @@ -1241,10 +1126,8 @@ h2 { margin-bottom: 0; margin-top: 0;} .threecol:nth-child(5) { margin: 0 !important; } - /************************************************************** Library Indices ***/ - #Libraries .colone { width: 300px; float: left; @@ -1266,10 +1149,8 @@ h2 { margin-bottom: 0; margin-top: 0;} #Libraries .twocol-alt { width: 330px; float: left; - //background: #cccccc; } - #Libraries .twocol p { margin-top: 0; } #Libraries .full { @@ -1294,8 +1175,6 @@ h2 { margin-bottom: 0; margin-top: 0;} margin-bottom: 2px; } - - #Libraries .lib-nav { display: block; margin-bottom: 10px; margin-left: -30px; @@ -1306,7 +1185,6 @@ h2 { margin-bottom: 0; margin-top: 0;} #Libraries pre { margin-left: 30px; margin-bottom: 30px; } #Libraries h2 { margin-top: 2em; } -/*#Libraries h3 { clear: both; margin-bottom: 0; }*/ #Libraries h3 { margin-top: 0; margin-bottom: 0;} @@ -1329,13 +1207,13 @@ h2 { margin-bottom: 0; margin-top: 0;} /************************************************************** environment ***/ -/*#Environment h1 { margin-top: 2em; }*/ -#Environment h5 { margin-top: 3em; } + +#Environment h5 { margin-top: 2em; margin-bottom: 1em; } #Environment h6 { margin-bottom: 0em; } #Environment h5 a { float: left; margin-left: -30px; } ul.nostyle { margin: 0; padding: 0; list-style: none outside; } #Environment td { padding-bottom: 1em; } -#Environment .content p, +/*#Environment .content p,*/ #Environment .content ul, #Environment .content table { width: 560px; @@ -1343,31 +1221,22 @@ ul.nostyle { margin: 0; padding: 0; list-style: none outside; } /************************************************************** overview ***/ + #Overview .content p, #Overview .content ul, -#Overview .content table { - width: 560px; -} +#Overview .content table { width: 560px; } #Foundation .content p, #Foundation .content ul, -#Foundation .content table { - width: 560px; -} - +#Foundation .content table { width: 560px; } #People .content p, #People .content ul, -#People .content table { - width: 560px; -} +#People .content table { width: 560px; } #people-f .content p, #people-f .content ul, -#people-f .content table { - width: 680px; -} - +#people-f .content table { width: 680px; } /************************************************************** examples ***/ @@ -1377,16 +1246,12 @@ p.doc-float { margin-left: 250px; } p.doc { margin-right: 40px; margin-top: 30px;} pre.code { clear: both; margin-top: 10px; } -/* #examples-nav { margin-left: -44px; display: relative; } */ //#examples-nav { margin-left: 0px; display: relative; } .examples-nav-div { margin-left: -44px; margin-top: -10px; width: 480px; display: relative; align: left; } #examples-nav img { display: absolute; top: 15px; left: 100px; } -/*#Examples h1 { margin-bottom: 0; }*/ - - div.updateRequired { color:#999; } @@ -1402,7 +1267,9 @@ ul.examples { -webkit-column-count:3; /* Safari and Chrome */ column-count:3; } + ul.examples li { margin: 0; padding: 0; } + ul.examples ul { list-style: none; padding: 0; @@ -1410,14 +1277,17 @@ ul.examples ul { margin-bottom: 17px; width: 100%; } + ul.examples ul li { margin: 0; } + div.examples-nav { margin-left: -41px; margin-bottom: 17px; position: relative; } + div.examples-nav img { position: relative; top: 11px; } .donate-card-row { @@ -1430,6 +1300,7 @@ div.examples-nav img { position: relative; top: 11px; } margin-left: -10px; margin-right: -10px; } + .donate-card { text-align: center; width: 30%; @@ -1447,28 +1318,35 @@ div.examples-nav img { position: relative; top: 11px; } -ms-flex-pack: center; justify-content: center; } + .donate-card h4 { line-height: 1.3; - margin: 0 0 0.5em 0; + margin: 0 0 0 0; color: #2c7bb5; } + a.donate-card { color: #252525; } + a.donate-card:hover { border-color: #2c7bb5; } + .donate-list { list-style: none; margin-left: 0; padding-left: 0; } + .donate-list li { margin-bottom: 0; } + .donate-list li:before { content: '» ' } + .donate-content hr { margin-top: 2em; margin-bottom: 2em; @@ -1476,48 +1354,3 @@ div.examples-nav img { position: relative; top: 11px; } border: none; border-top: 1px solid #CBCBCB; } - -/**************************************************************** updates, courses, happenings ***/ -/* -#Courses .content, #Updates .content, #Happenings .content { - width: 595px; - } -#Updates h2 { margin-top: 0 0 20px 0; } - - -.course-desc p { margin: 0; } -.course-desc p.date { margin: 0; } -.course-desc h3 { margin: 0; font-size: 1em; font-weight: bold; line-height: 1em; } -.course-desc { margin-bottom: 2em; } -*/ - -/************************************************************** comparison ***/ -/* - -#Compare h1 { margin-top: 2em; } -#Compare h2 { margin-bottom: 0; } -#Compare .threecol { float: left; width: 210px; margin-right: 20px; } -#Compare .threecol p { margin-top: 0; } - - -#Compare .content { - margin-left : 55px; - margin-right : 0px; - position: relative; -} -*/ - -/************************************************************** troubleshooting ***/ -/* -#Troubleshooting h1 { margin-top: 2em; } -#Troubleshooting h5 a { float: left; margin-left: -30px; } -ul.nostyle { margin: 0; padding: 0; list-style: none outside; } -#Troubleshooting td { padding-bottom: 1em; } -*/ - -/************************************************************** FAQ ***/ - -/* -#FAQ h5 a { float: left; margin-left: -30px; } -*/ - diff --git a/download/install-arm.sh b/download/install-arm.sh index b755d62f1..b70361d77 100755 --- a/download/install-arm.sh +++ b/download/install-arm.sh @@ -4,16 +4,13 @@ # Run it like this: "curl https://processing.org/download/install-arm.sh | sudo sh" # check if on a 64-bit operating system -if [[ $(file $(which file)) == *aarch64* ]] -then - FLAVOR="arm64" - TAR="$(curl -sL https://api.github.com/repos/processing/processing/releases | grep -oh -m 1 'https.*linux-arm64.tgz')" -else - FLAVOR="armv6hf" - TAR="$(curl -sL https://api.github.com/repos/processing/processing/releases | grep -oh -m 1 'https.*linux-armv6hf.tgz')" -fi - -echo "\nDownloading $TAR..." +case "$(file $(which file))" in + *aarch64*) FLAVOR="arm64"; TAR="$(curl -sL https://api.github.com/repos/processing/processing/releases | grep -oh -m 1 'https.*linux-arm64.tgz')" ;; + *) FLAVOR="armv6hf"; TAR="$(curl -sL https://api.github.com/repos/processing/processing/releases | grep -oh -m 1 'https.*linux-armv6hf.tgz')" ;; +esac + +echo "" +echo "Downloading $TAR..." curl -L $TAR > processing-linux-$FLAVOR-latest.tgz echo "Installing in /usr/local..." @@ -40,4 +37,5 @@ sed -i 's|/opt/processing|/usr/local/lib/processing|' /usr/local/share/applicati # silence validation errors desktop-file-install /usr/local/share/applications/processing.desktop >/dev/null 2>&1 -echo "Done! You can start Processing by running \"processing\" in the terminal, or through the applications menu (might require a restart).\n" +echo "Done! You can start Processing by running processing in the terminal, or through the applications menu (might require a restart)." +echo "" diff --git a/download/latest.txt b/download/latest.txt index 4689cf158..98de25a15 100644 --- a/download/latest.txt +++ b/download/latest.txt @@ -1,2 +1,2 @@ -0262 +1276 diff --git a/exhibition/works/discom/Thumbs.db b/exhibition/works/discom/Thumbs.db deleted file mode 100644 index 93ae137df..000000000 Binary files a/exhibition/works/discom/Thumbs.db and /dev/null differ diff --git a/exhibition/works/superhero/img/Thumbs.db b/exhibition/works/superhero/img/Thumbs.db deleted file mode 100755 index 9f2257887..000000000 Binary files a/exhibition/works/superhero/img/Thumbs.db and /dev/null differ diff --git a/generate/README.md b/generate/README.md new file mode 100644 index 000000000..e38655a77 --- /dev/null +++ b/generate/README.md @@ -0,0 +1,9 @@ +These are the scripts that generate most of the the processing.org website and Reference that's included with the Processing software. The language Reference scripts are in the ../java_generate/ directory and that's a whole other thing... + +The generator scripts are written in PHP using an old version of DOMIT: https://sourceforge.net/projects/domit-xmlparser/ + +The files that are appended with "local" generate alternate versions of those pages for the Reference that comes included with the Processing software. + +This directory also contains the files to generate the "keywords.txt" file that controls the syntax highlighting for the Processing Development Environment (PDE). The Perl script "keywords_create.cgi" generates this file by combining "keywords_base.txt" with the Reference XML files. + +The data used to generate the site pages are in the ../content/ directory. diff --git a/generate/index.php b/generate/index.php index 62a281526..d907d26aa 100755 --- a/generate/index.php +++ b/generate/index.php @@ -23,6 +23,7 @@

    Hello, this is a notice!

    +

    Presets

    @@ -32,13 +33,13 @@ Filip Dan Elie - Scott - Philip + +

    - Everything - Site + Everything + Site Nothing

    @@ -99,10 +100,12 @@

    +

    Contributions diff --git a/generate/keywords_base.txt b/generate/keywords_base.txt index a89afdf87..7757bb46f 100755 --- a/generate/keywords_base.txt +++ b/generate/keywords_base.txt @@ -1,17 +1,18 @@ -# THE TEXT BELOW IS HAND WRITTEN AND FOUND IN THE FILE "keywords_base.txt" -# IN THE PROCESSING-DOCS REPO. DON'T EDITS THE keywords.txt FILE DIRECTLY. +# THIS TEXT IS FROM keywords_base.txt IN THE PROCESSING-DOCS REPO: +# https://github.com/processing/processing-docs/blob/master/generate/keywords_base.txt +# MAKE CHANGES THERE: DO NOT EDIT THE keywords.txt FILE DIRECTLY. -# For an explanation of these tags, see Token.java +# For an explanation of these tags, see Token.java # trunk/processing/app/src/processing/app/syntax/Token.java ADD LITERAL2 blend_ -ALIGN_CENTER LITERAL2 -ALIGN_LEFT LITERAL2 -ALIGN_RIGHT LITERAL2 +ALIGN_CENTER LITERAL2 +ALIGN_LEFT LITERAL2 +ALIGN_RIGHT LITERAL2 ALPHA LITERAL2 ALPHA_MASK LITERAL2 ALT LITERAL2 -AMBIENT LITERAL2 +AMBIENT LITERAL2 ARC LITERAL2 createShape_ ARROW LITERAL2 cursor_ ARGB LITERAL2 @@ -24,7 +25,7 @@ BLUR LITERAL2 filter_ BOTTOM LITERAL2 textAlign_ BOX LITERAL2 createShape_ BURN LITERAL2 blend_ -CENTER LITERAL2 +CENTER LITERAL2 CHATTER LITERAL2 CHORD LITERAL2 arc_ CLAMP LITERAL2 @@ -88,7 +89,7 @@ GIF LITERAL2 GRAY LITERAL2 filter_ GREEN_MASK LITERAL2 GROUP LITERAL2 -HALF LITERAL2 +HALF LITERAL2 HALF_PI LITERAL2 HALF_PI HAND LITERAL2 cursor_ HARD_LIGHT LITERAL2 blend_ @@ -97,7 +98,7 @@ HSB LITERAL2 colorMode_ IMAGE LITERAL2 textureMode_ INVERT LITERAL2 filter_ JAVA2D LITERAL2 size_ -JPEG LITERAL2 +JPEG LITERAL2 LEFT LITERAL2 keyCode LIGHTEST LITERAL2 blend_ LINE LITERAL2 createShape_ @@ -105,18 +106,18 @@ LINES LITERAL2 beginShape_ LINUX LITERAL2 MACOSX LITERAL2 MAX_FLOAT LITERAL2 -MAX_INT LITERAL2 +MAX_INT LITERAL2 MIN_FLOAT LITERAL2 MIN_INT LITERAL2 MITER LITERAL2 stokeJoin_ MODEL LITERAL2 textMode_ MOVE LITERAL2 cursor_ MULTIPLY LITERAL2 blend_ -NORMAL LITERAL2 +NORMAL LITERAL2 NORMALIZED LITERAL2 textureMode_ NO_DEPTH_TEST LITERAL2 NTSC LITERAL2 -ONE LITERAL2 +ONE LITERAL2 OPAQUE LITERAL2 filter_ OPEN LITERAL2 ORTHOGRAPHIC LITERAL2 @@ -127,13 +128,13 @@ P2D LITERAL2 size_ P3D LITERAL2 size_ PERSPECTIVE LITERAL2 PI LITERAL2 PI -PIE LITERAL2 +PIE LITERAL2 PIXEL_CENTER LITERAL2 POINT LITERAL2 -POINTS LITERAL2 +POINTS LITERAL2 POSTERIZE LITERAL2 filter_ PRESS LITERAL2 -PROBLEM LITERAL2 +PROBLEM LITERAL2 PROJECT LITERAL2 strokeCap_ QUAD LITERAL2 createShape_ QUAD_STRIP LITERAL2 beginShape_ @@ -146,23 +147,23 @@ RECT LITERAL2 RED_MASK LITERAL2 RELEASE LITERAL2 REPEAT LITERAL2 -REPLACE LITERAL2 +REPLACE LITERAL2 RETURN LITERAL2 RGB LITERAL2 colorMode_ RIGHT LITERAL2 keyCode ROUND LITERAL2 strokeCap_ SCREEN LITERAL2 blend_ -SECAM LITERAL2 +SECAM LITERAL2 SHAPE LITERAL2 textMode_ SHIFT LITERAL2 -SPAN LITERAL2 fullScreen_ +SPAN LITERAL2 fullScreen_ SPECULAR LITERAL2 SPHERE LITERAL2 createShape_ SOFT_LIGHT LITERAL2 blend_ SQUARE LITERAL2 strokeCap_ SUBTRACT LITERAL2 blend_ SVG LITERAL2 -SVIDEO LITERAL2 +SVIDEO LITERAL2 TAB LITERAL2 keyCode TARGA LITERAL2 TAU LITERAL2 TAU @@ -181,17 +182,17 @@ TWO LITERAL2 TWO_PI LITERAL2 TWO_PI UP LITERAL2 keyCode WAIT LITERAL2 cursor_ -WHITESPACE LITERAL2 +WHITESPACE LITERAL2 # Java keywords (void, import, , etc.) - + abstract KEYWORD1 break KEYWORD1 break class KEYWORD1 class continue KEYWORD1 continue -default KEYWORD1 default -enum KEYWORD1 +default KEYWORD1 default +enum KEYWORD1 extends KEYWORD1 extends false KEYWORD1 false final KEYWORD1 final @@ -199,17 +200,17 @@ finally KEYWORD1 implements KEYWORD1 implements import KEYWORD1 import instanceof KEYWORD1 -interface KEYWORD1 +interface KEYWORD1 native KEYWORD1 new KEYWORD1 new null KEYWORD1 null -package KEYWORD1 +package KEYWORD1 private KEYWORD1 private -protected KEYWORD1 +protected KEYWORD1 public KEYWORD1 public static KEYWORD1 static -strictfp KEYWORD1 -throws KEYWORD1 +strictfp KEYWORD1 +throws KEYWORD1 transient KEYWORD1 true KEYWORD1 true void KEYWORD1 void @@ -220,7 +221,7 @@ volatile KEYWORD1 assert KEYWORD6 case KEYWORD6 case -return KEYWORD6 return +return KEYWORD6 return super KEYWORD6 super this KEYWORD6 this throw KEYWORD6 @@ -230,18 +231,17 @@ throw KEYWORD6 Array KEYWORD5 Array ArrayList KEYWORD5 ArrayList -Boolean KEYWORD5 -Byte KEYWORD5 +Boolean KEYWORD5 +Byte KEYWORD5 BufferedReader KEYWORD5 BufferedReader -Character KEYWORD5 +Character KEYWORD5 Class KEYWORD5 class -Double KEYWORD5 -Float KEYWORD5 -Integer KEYWORD5 +Float KEYWORD5 +Integer KEYWORD5 HashMap KEYWORD5 HashMap PrintWriter KEYWORD5 PrintWriter String KEYWORD5 String -StringBuffer KEYWORD5 +StringBuffer KEYWORD5 StringBuilder KEYWORD5 Thread KEYWORD5 boolean KEYWORD5 boolean @@ -252,7 +252,7 @@ double KEYWORD5 double float KEYWORD5 float int KEYWORD5 int long KEYWORD5 long -short KEYWORD5 +var KEYWORD5 # Flow structures @@ -386,7 +386,7 @@ pixelHeight KEYWORD4 pixelHeight # # THE TEXT BELOW IS AUTO-GENERATED # -# SO -# DON'T -# TOUCH +# SO +# DON'T +# TOUCH # IT diff --git a/generate/lib/Curated.class.php b/generate/lib/Curated.class.php index d2837ac5b..d9e70dfad 100755 --- a/generate/lib/Curated.class.php +++ b/generate/lib/Curated.class.php @@ -22,7 +22,8 @@ function Curated($xml) $this->width = getAttribute($xml, 'width'); $this->height = getAttribute($xml, 'height'); $this->image = getValue($xml, 'image'); - $this->description = innerHTML($xml, 'description'); + //$this->description = innerHTML($xml, 'description'); + $this->description = getValue($xml, 'description'); $this->location = getValue($xml, 'location'); $links = $xml->getElementsByTagName('link'); diff --git a/generate/libraries.php b/generate/libraries.php index ee8bc5652..d34c53ba2 100755 --- a/generate/libraries.php +++ b/generate/libraries.php @@ -19,7 +19,7 @@ //`cd $path && /usr/bin/git pull https://github.com/processing/processing-docs/`; -$libraries = array('net', 'serial', 'video', 'dxf', 'pdf', 'sound', 'io'); +$libraries = array('net', 'serial', 'video', 'dxf', 'pdf', 'sound', 'io', 'svg'); $lib_dir = REFERENCEDIR.'libraries/'; // Create Index @@ -47,7 +47,7 @@ // template and copy index $index = CONTENTDIR.$source.'/index.html'; - if($lib == 'pdf' || $lib == 'dxf') { + if($lib == 'pdf' || $lib == 'dxf' || $lib == 'svg') { //$page = new Page(strtoupper($lib) . ' \\ Libraries', 'Libraries', 'Library-index'); $page = new Page(strtoupper($lib) . ' \\ Libraries', 'Libraries'); } else { diff --git a/generate/libraries_local.php b/generate/libraries_local.php index 7c946d94f..ddaeaff96 100755 --- a/generate/libraries_local.php +++ b/generate/libraries_local.php @@ -8,7 +8,7 @@ $benchmark_start = microtime_float(); -$libraries = array('net', 'serial', 'video', 'dxf', 'pdf', 'sound', 'io'); +$libraries = array('net', 'serial', 'video', 'dxf', 'pdf', 'sound', 'io', 'svg'); $lib_dir = DISTDIR.'libraries'; diff --git a/generate/reference.php b/generate/reference.php index b1a0aeeed..5e2a7532c 100644 --- a/generate/reference.php +++ b/generate/reference.php @@ -38,7 +38,9 @@ function out($output) { out("Pulling in latest changes from processing/processing-sound/..."); $soundRepoPath = "{$path}../processing-sound"; -$shell_output = shell_exec("cd $soundRepoPath && /usr/bin/git pull https://github.com/processing/processing-sound/ 2>&1"); +//$shell_output = shell_exec("cd $soundRepoPath && /usr/bin/git pull https://github.com/processing/processing-sound/ 2>&1"); +// clone new processing-sound library from work-in-progress repository instead +$shell_output = shell_exec("rm -rf $soundRepoPath && mkdir $soundRepoPath && cd $soundRepoPath && /usr/bin/git clone https://github.com/processing/processing-sound.git . 2>&1"); out($shell_output); out("---------------"); @@ -84,4 +86,4 @@ function out($output) { $execution_time = round($benchmark_end - $benchmark_start, 4); out("Generated files in $execution_time seconds."); -?> \ No newline at end of file +?> diff --git a/generate/staticpages.php b/generate/staticpages.php index db3b0422b..1a60b6291 100755 --- a/generate/staticpages.php +++ b/generate/staticpages.php @@ -28,9 +28,9 @@ writeFile('overview/index.html', $page->out()); #copydirr($source.'/images', $path.'/images'); -$page = new Page("Foundation", "Foundation"); -$page->content(file_get_contents($source."foundation.html")); -writeFile('foundation/index.html', $page->out()); +#$page = new Page("Foundation", "Foundation"); +#$page->content(file_get_contents($source."foundation.html")); +#writeFile('foundation/index.html', $page->out()); $page = new Page("People", "People"); $page->content(file_get_contents($source."people.html")); @@ -65,21 +65,21 @@ writeFile('copyright.html', $page->out()); // Copy over the images for the shop index -if (!is_dir($path.'shop')) { - mkdir($path.'shop', 0757); -} +#if (!is_dir($path.'shop')) { +# mkdir($path.'shop', 0757); +#} -if (!is_dir($path.'shop/imgs')) { - mkdir($path.'shop/imgs', 0757); -} +#if (!is_dir($path.'shop/imgs')) { +# mkdir($path.'shop/imgs', 0757); +#} -if (is_dir($path.'shop/imgs')) { - copydirr($source.'shop/imgs', $path.'shop/imgs', null, 0757, false); -} +#if (is_dir($path.'shop/imgs')) { +# copydirr($source.'shop/imgs', $path.'shop/imgs', null, 0757, false); +#} -$page = new Page("Shop", "Shop"); -$page->content(file_get_contents($source.'shop/'."index.html")); -writeFile('shop/index.html', $page->out()); +#$page = new Page("Shop", "Shop"); +#$page->content(file_get_contents($source.'shop/'."index.html")); +#writeFile('shop/index.html', $page->out()); $benchmark_end = microtime_float(); $execution_time = round($benchmark_end - $benchmark_start, 4); diff --git a/img/cc.png b/img/cc.png new file mode 100644 index 000000000..4acf8c4ec Binary files /dev/null and b/img/cc.png differ diff --git a/img/learning/books/coding-art.jpg b/img/learning/books/coding-art.jpg new file mode 100644 index 000000000..79fa91e5a Binary files /dev/null and b/img/learning/books/coding-art.jpg differ diff --git a/img/learning/books/o-codigo.jpg b/img/learning/books/o-codigo.jpg new file mode 100644 index 000000000..e70fad0e9 Binary files /dev/null and b/img/learning/books/o-codigo.jpg differ diff --git a/img/learning/books/opencv.jpg b/img/learning/books/opencv.jpg new file mode 100644 index 000000000..826db6e99 Binary files /dev/null and b/img/learning/books/opencv.jpg differ diff --git a/img/learning/books/pro-processing.jpg b/img/learning/books/pro-processing.jpg new file mode 100644 index 000000000..25e7f6863 Binary files /dev/null and b/img/learning/books/pro-processing.jpg differ diff --git a/img/learning/books/processing-android-sm.jpg b/img/learning/books/processing-android-sm.jpg new file mode 100644 index 000000000..a6b81a2a0 Binary files /dev/null and b/img/learning/books/processing-android-sm.jpg differ diff --git a/img/learning/books/processing-android.jpg b/img/learning/books/processing-android.jpg new file mode 100644 index 000000000..e66bc832f Binary files /dev/null and b/img/learning/books/processing-android.jpg differ diff --git a/img/learning/books/programming-101.jpg b/img/learning/books/programming-101.jpg new file mode 100644 index 000000000..3749c36a2 Binary files /dev/null and b/img/learning/books/programming-101.jpg differ diff --git a/img/pcd17.png b/img/pcd17.png new file mode 100644 index 000000000..cb5f2b18c Binary files /dev/null and b/img/pcd17.png differ diff --git a/java_generate/templates/class.template.html b/java_generate/templates/class.template.html index 598ddfd15..96634b4c1 100644 --- a/java_generate/templates/class.template.html +++ b/java_generate/templates/class.template.html @@ -1,7 +1,7 @@ - <!-- classname --> \ Language (API) \ Processing 2+ + <!-- classname --> \ Language (API) \ Processing 3+ @@ -23,12 +23,13 @@ -

    - - + diff --git a/java_generate/templates/generic.template.html b/java_generate/templates/generic.template.html index 4d9163a9b..d8858a537 100644 --- a/java_generate/templates/generic.template.html +++ b/java_generate/templates/generic.template.html @@ -1,7 +1,7 @@ - <!-- require:classname --><!-- classname -->::<!-- end --><!-- name --> \ Language (API) \ Processing 2+ + <!-- require:classname --><!-- classname -->::<!-- end --><!-- name --> \ Language (API) \ Processing 3+ @@ -23,13 +23,13 @@ - + diff --git a/java_generate/templates/index.alphabetical.template.html b/java_generate/templates/index.alphabetical.template.html index 0f865fac0..1c52fca5c 100644 --- a/java_generate/templates/index.alphabetical.template.html +++ b/java_generate/templates/index.alphabetical.template.html @@ -1,7 +1,7 @@ - Alphabetical Language Reference (API) \ Processing 2+ + Alphabetical Language Reference (API) \ Processing 3+ @@ -28,6 +28,7 @@
  • p5.js
  • Processing.py
  • Processing for Android
  • +
  • Processing for Pi
    • Processing Foundation
    • @@ -42,6 +43,12 @@

      + diff --git a/java_generate/templates/index.template.html b/java_generate/templates/index.template.html index 2204a2ad0..12b460548 100644 --- a/java_generate/templates/index.template.html +++ b/java_generate/templates/index.template.html @@ -1,7 +1,7 @@ - Language Reference (API) \ Processing 2+ + Language Reference (API) \ Processing 3+ @@ -27,6 +27,7 @@
    • p5.js
    • Processing.py
    • Processing for Android
    • +
    • Processing for Pi
    • Processing Foundation
    • @@ -41,6 +42,12 @@

      + diff --git a/java_generate/templates/library.index.template.html b/java_generate/templates/library.index.template.html index ee0d6a6cd..98c01d64e 100644 --- a/java_generate/templates/library.index.template.html +++ b/java_generate/templates/library.index.template.html @@ -1,7 +1,7 @@ - Video \ Libraries \ Processing 2+ + Video \ Libraries \ Processing 3+ @@ -23,12 +23,13 @@ - + diff --git a/java_generate/templates/nav.web.template.html b/java_generate/templates/nav.web.template.html index a557955b9..43f41939c 100644 --- a/java_generate/templates/nav.web.template.html +++ b/java_generate/templates/nav.web.template.html @@ -4,7 +4,7 @@ Download
      Donate

      - Exhibition

      + Reference
      Libraries
      @@ -13,21 +13,21 @@ Tutorials
      Examples
      - Books
      - Handbook

      + Books

      + Overview
      People

      - Shop

      + - »Forum
      + »Forum
      »GitHub
      »Issues
      »Wiki
      »FAQ
      »Twitter
      - »Facebook
      + »Medium \ No newline at end of file diff --git a/subscribe/index.php b/subscribe/index.php index 09b856f39..a684a7fc8 100755 --- a/subscribe/index.php +++ b/subscribe/index.php @@ -94,9 +94,9 @@ Shop

      »Forum
      »GitHub
      - »Issues
      - »Wiki
      - »FAQ
      + »Issues
      + »Wiki
      + »FAQ
      »Twitter
      »Facebook
      diff --git a/templates/template.cover.html b/templates/template.cover.html index 0c4d3621d..4e776eb87 100755 --- a/templates/template.cover.html +++ b/templates/template.cover.html @@ -7,53 +7,34 @@ Download Processing
      Browse Tutorials
      Visit the Reference
      - -
      -

      - Processing is a flexible software sketchbook and a language for learning how to code within the context of the visual arts. Since 2001, Processing has promoted software literacy within the visual arts and visual literacy within technology. There are tens of thousands of students, artists, designers, researchers, and hobbyists who use Processing for learning and prototyping. - -

        -
      • » Free to download and open source
      • -
      • » Interactive programs with 2D, 3D or PDF output
      • -
      • » OpenGL integration for accelerated 2D and 3D
      • -
      • » For GNU/Linux, Mac OS X, Windows, Android, and ARM
      • -
      • » Over 100 libraries extend the core software
      • -
      • » Well documented, with many books available
      • -
      -
      -

      +
      +

      + Processing is a flexible software sketchbook and a language for learning how to code within the context of the visual arts. Since 2001, Processing has promoted software literacy within the visual arts and visual literacy within technology. There are tens of thousands of students, artists, designers, researchers, and hobbyists who use Processing for learning and prototyping. +

        +
      • » Free to download and open source
      • +
      • » Interactive programs with 2D, 3D, PDF, or SVG output
      • +
      • » OpenGL integration for accelerated 2D and 3D
      • +
      • » For GNU/Linux, Mac OS X, Windows, Android, and ARM
      • +
      • » Over 100 libraries extend the core software
      • +
      • » Well documented, with many books available
      • +
      +

      -

      Books

      - The 2nd edition of Getting Started with Processing is here and it's updated for Processing 3. It's now in full color and there's a new chapter on working with data. The 2nd edition of the Processing Handbook is here too. Every chapter has been revised, and new chapters introduce more ways to work with data and geometry. New “synthesis” chapters offer discussion and worked examples of such topics as sketching with code, modularity, and algorithms.
      -
      - New Book! -

      - - - - - + Processing Books +

      + +
      - - - -

      Donate

      - Please join us as a member of the Processing Foundation. We need your help! + Please support the Processing Foundation. We need your help!
      -
      -

      Exhibition

      - exhibition + + +
      + PCD 2020
      +
      + The Processing Community Day (PCD) initiative is evolving. For 2020, we will offer a mentorship program for PCD Worldwide Organizers who are interested in learning from past community organizers and mentors. The goal is to help a diverse group of organizers launch a PCD in their local communities. Check out the PCD @ Worldwide site to learn more about starting or attending an event in 2020!
      +
      - -

      To see more of what people are doing with Processing, check out these sites:

      - -

      » CreativeApplications.Net
      - » OpenProcessing
      - » For Your Processing
      - » Processing Subreddit
      - » Vimeo
      - - » Studio Sketchpad
      +

      + To see more of what people are doing with Processing, check out these sites:
      + » CreativeApplications.Net
      + » OpenProcessing
      + » For Your Processing
      + » Processing Subreddit
      + » Vimeo
      + » Studio Sketchpad

      -

      - To contribute to the development, please visit +

      + To contribute to Processing development, please visit Processing on GitHub to read instructions for downloading the code, building from the source, - reporting and tracking bugs, and + reporting and tracking bugs, and creating libraries and tools.

      -

      -

      Partners
      - » Fathom
      +
      Partners
      + » Fathom
      » NYU ITP
      » UCLA Design Media Arts

      - -

      Contact
      foundation@processing.org diff --git a/templates/template.html b/templates/template.html index b90627d71..b3836287a 100755 --- a/templates/template.html +++ b/templates/template.html @@ -27,6 +27,7 @@
    • p5.js
    • Processing.py
    • Processing for Android
    • +
    • Processing for Pi
    • Processing Foundation
    • @@ -42,6 +43,13 @@

      + + diff --git a/templates/template.nav.php b/templates/template.nav.php index 415d91811..01dd329bd 100755 --- a/templates/template.nav.php +++ b/templates/template.nav.php @@ -8,11 +8,9 @@ 'Learning' => array('/learning/', 1), 'Tutorials' => array('/tutorials/', 2), - 'Examples' => array('/examples/', 2), - # '3D' => array('/learning/3d/', 2), - # 'Library' => array('/learning/library/', 2), - 'Books' => array('/books/', 2), - 'Handbook' => array('/handbook/', 2), + 'Examples' => array('/examples/', 2), + 'Books' => array('/books/', 2), + 'Handbook' => array('/handbook/', 2), 'Reference' => array('/reference/', 1), @@ -23,7 +21,7 @@ 'Environment' => array('/reference/environment/', 2), 'Download' => array('/download/', 1), - 'Donate' => array('/download/support.html', 1), + 'Donate' => array('/download/support.html', 1), 'Shop' => array('/shop/', 1), @@ -33,7 +31,7 @@ 'People' => array('/people/', 2), 'Foundation' => array('/foundation/', 2), - 'FAQ' => array('http://wiki.processing.org/w/FAQ', 1), + 'FAQ' => array('https://github.com/processing/processing/wiki', 1), ); @@ -60,7 +58,7 @@ function navigation($section = '') $html .= "\t\t\t\t\t" . l('Download', $section == 'Download') . "
      \n"; $html .= "\t\t\t\t\t" . l('Donate', $section == 'Donate') . "

      \n"; - $html .= "\t\t\t\t\t" . l('Exhibition', $section == 'Exhibition') . "

      \n"; + #$html .= "\t\t\t\t\t" . l('Exhibition', $section == 'Exhibition') . "

      \n"; $html .= "\t\t\t\t\t" . l('Reference', $section == 'Reference') . "
      \n"; $html .= "\t\t\t\t\t" . l('Libraries', $section == 'Libraries') . "
      \n"; @@ -69,22 +67,22 @@ function navigation($section = '') $html .= "\t\t\t\t\t" . l('Tutorials', $section == 'Tutorials') . "
      \n"; $html .= "\t\t\t\t\t" . l('Examples', $section == 'Examples') . "
      \n"; - $html .= "\t\t\t\t\t" . l('Books', $section == 'Books') . "
      \n"; - $html .= "\t\t\t\t\t" . l('Handbook', $section == 'Handbook') . "

      \n"; + $html .= "\t\t\t\t\t" . l('Books', $section == 'Books') . "

      \n"; + #$html .= "\t\t\t\t\t" . l('Handbook', $section == 'Handbook') . "

      \n"; $html .= "\t\t\t\t\t" . l('Overview', $section == 'Overview') . "
      \n"; $html .= "\t\t\t\t\t" . l('People', $section == 'People') . "

      \n"; # $html .= "\t\t\t\t\t" . l('Foundation', $section == 'Foundation') . "

      \n"; - $html .= "\t\t\t\t\t" . l('Shop', $section == 'Shop') . "

      \n"; + #$html .= "\t\t\t\t\t" . l('Shop', $section == 'Shop') . "

      \n"; - $html .= "\t\t\t\t\t" . "»Forum
      \n"; + $html .= "\t\t\t\t\t" . "»Forum
      \n"; $html .= "\t\t\t\t\t" . "»GitHub
      \n"; $html .= "\t\t\t\t\t" . "»Issues
      \n"; $html .= "\t\t\t\t\t" . "»Wiki
      \n"; $html .= "\t\t\t\t\t" . "»FAQ
      \n"; $html .= "\t\t\t\t\t" . "»Twitter
      \n"; - $html .= "\t\t\t\t\t" . "»Facebook
      \n"; + #$html .= "\t\t\t\t\t" . "»Facebook
      \n"; $html .= "\t\t\t\t\t" . "»Medium
      \n"; $html .= "\t\t\t\t\n"; diff --git a/templates/template.php b/templates/template.php index d01db7566..f7ecfe4ea 100755 --- a/templates/template.php +++ b/templates/template.php @@ -92,7 +92,7 @@ function ReferencePage(&$ref, $translation, $lang = 'en') global $LANGUAGES; $this->filepath = 'reference/' . ($lang == 'en' ? '' : "$lang/") . $ref->name(); - $title = $ref->title() . ($lang == 'en' ? '' : " \ {$LANGUAGES[$lang][0]}") .' \ Language (API) \ Processing 2+'; + $title = $ref->title() . ($lang == 'en' ? '' : " \ {$LANGUAGES[$lang][0]}") .' \ Language (API) \ Processing 3+'; $xhtml = new xhtml_page(TEMPLATEDIR.'template.translation.html'); $xhtml->set('header', HEADER_LINK); @@ -152,7 +152,7 @@ function LibReferencePage(&$ref, $lib, $translation, $lang = 'en') $this->libdir = $this->libsdir . "/$lib"; $this->filepath = $this->libdir . '/' . $ref->name(); - $title = $ref->title() . ($lang == 'en' ? '' : " \ {$LANGUAGES[$lang][0]}") .' \ Language (API) \ Processing 2+'; + $title = $ref->title() . ($lang == 'en' ? '' : " \ {$LANGUAGES[$lang][0]}") .' \ Language (API) \ Processing 3+'; $xhtml = new xhtml_page(TEMPLATEDIR.'template.translation.html'); $xhtml->set('header', HEADER_LINK); @@ -197,7 +197,7 @@ function LocalPage($title = '', $section = '', $bodyid = '', $rel_path = '') { $this->xhtml = new xhtml_page(TEMPLATEDIR.'template.local.html'); $this->xhtml->set('header', ''); - $title = ($title == '') ? 'Processing 2+' : $title . ' \ Processing 2+'; + $title = ($title == '') ? 'Processing 3+' : $title . ' \ Processing 3+'; $this->xhtml->set('title', $title); $this->xhtml->set('navigation', local_nav($section, $rel_path)); $this->set('relpath', $rel_path); @@ -215,7 +215,7 @@ class LocalReferencePage extends ReferencePage function LocalReferencePage(&$ref, $translation, $lang = 'en', $rel_path = '') { $this->filepath = 'distribution/' . $ref->name(); - $title = $ref->title() .' \ Language (API) \ Processing 2+'; + $title = $ref->title() .' \ Language (API) \ Processing 3+'; $xhtml = new xhtml_page(TEMPLATEDIR.'template.local.html'); $xhtml->set('header', ''); @@ -255,7 +255,7 @@ function LocalLibReferencePage(&$ref, $lib, $translation, $rel_path = '../../') $this->filepath = "distribution/libraries/$lib/" . $ref->name(); - $title = $ref->title() . "\\ $lib \\ Language (API) \\ Processing 2+"; + $title = $ref->title() . "\\ $lib \\ Language (API) \\ Processing 3+"; $xhtml = new xhtml_page(TEMPLATEDIR.'template.local.html'); $xhtml->set('header', ''); diff --git a/todo-web.txt b/todo-web.txt index ef1c459d5..9ce53ba0b 100644 --- a/todo-web.txt +++ b/todo-web.txt @@ -83,7 +83,7 @@ Shop > Twitter > Forum -> Wiki +> Wiki > Issues > GitHub