# Processing

**URL:** https://discourse.processing.org/c/processing/6.md?no_subcategories=false&page=332

[Latest](https://discourse.processing.org/latest.md) · [Categories](https://discourse.processing.org/categories.md) · [Tags](https://discourse.processing.org/tags.md)

**Page:** 333

---

## [Adding integer to an array (Java)](https://discourse.processing.org/t/adding-integer-to-an-array-java/7247)

<div class="topic-metadata">

**Author:** [@J0R1AN](https://discourse.processing.org/u/J0R1AN)\
**Replies:** 4\
**Last updated:** [January 6, 2019, 5:54pm UTC](https://discourse.processing.org/t/adding-integer-to-an-array-java/7247 "2019-01-06T17:54:16Z")

</div>

Hello everyone, I was experimenting a bit with arrays and integers but I found myself having trouble with adding numbers to an array. I want to create an array, add a number to the array (so the length increases) and pr…

---

## [Program which changes the color of a circle based on which key is pressed](https://discourse.processing.org/t/program-which-changes-the-color-of-a-circle-based-on-which-key-is-pressed/7233)

<div class="topic-metadata">

**Author:** [@Umar2003](https://discourse.processing.org/u/Umar2003)\
**Replies:** 5\
**Last updated:** [January 6, 2019, 10:47am UTC](https://discourse.processing.org/t/program-which-changes-the-color-of-a-circle-based-on-which-key-is-pressed/7233 "2019-01-06T10:47:21Z")

</div>

I’m trying to write a Write a program which changes the color of a circle based on which key is pressed. Here are the colors and their corresponding keys: Nothing Pressed - Black Y - Yellow G - Green R - Red B - Bl…

---

## [Question: Processing on Archlinux | Using Emacs as external editor](https://discourse.processing.org/t/question-processing-on-archlinux-using-emacs-as-external-editor/6809)

<div class="topic-metadata">

**Author:** [@nyquil](https://discourse.processing.org/u/nyquil)\
**Replies:** 3\
**Last updated:** [January 6, 2019, 7:01am UTC](https://discourse.processing.org/t/question-processing-on-archlinux-using-emacs-as-external-editor/6809 "2019-01-06T07:01:58Z")

</div>

Hello, I just got interested in Processing lately and thinking of trying it out. Does anyone run archlinux by any chance? There is this processing package (Processing 3.4-2) in arch’s official repo, but after the insta…

---

## [How to deduct 1 health point if a moving triangle collides with a moving point?](https://discourse.processing.org/t/how-to-deduct-1-health-point-if-a-moving-triangle-collides-with-a-moving-point/7240)

<div class="topic-metadata">

**Author:** [@francium401](https://discourse.processing.org/u/francium401)\
**Replies:** 4\
**Last updated:** [January 6, 2019, 2:36am UTC](https://discourse.processing.org/t/how-to-deduct-1-health-point-if-a-moving-triangle-collides-with-a-moving-point/7240 "2019-01-06T02:36:57Z")

</div>

I want to figure out how to deduct 1 health point if a moving triangle collides with any moving point, and make that one particular point that has the triangle collided with disappear (if that’s possible). Just to note t…

---

## [Functions Problem; Rows of squares](https://discourse.processing.org/t/functions-problem-rows-of-squares/7231)

<div class="topic-metadata">

**Author:** [@Umer1](https://discourse.processing.org/u/Umer1)\
**Replies:** 5\
**Last updated:** [January 6, 2019, 12:52am UTC](https://discourse.processing.org/t/functions-problem-rows-of-squares/7231 "2019-01-06T00:52:07Z")

</div>

Hi does anyone know how to do rows of squares using functions? This is what I have so far: void setup() { size(500,500); background(255); } void draw() { background(255); stroke(5); int x = 10; int …

---

## [Program which draws an \`I\` if no keys are pressed, and an \`E\`or an \`F\`if those keys are pressed](https://discourse.processing.org/t/program-which-draws-an-i-if-no-keys-are-pressed-and-an-e-or-an-f-if-those-keys-are-pressed/7207)

<div class="topic-metadata">

**Author:** [@Umar2003](https://discourse.processing.org/u/Umar2003)\
**Replies:** 9\
**Last updated:** [January 5, 2019, 9:49pm UTC](https://discourse.processing.org/t/program-which-draws-an-i-if-no-keys-are-pressed-and-an-e-or-an-f-if-those-keys-are-pressed/7207 "2019-01-05T21:49:04Z")

</div>

I’m trying to write a program which draws an I if no keys are pressed, and an Eor an Fif those keys are pressed. Use straight lines to draw these letters. The window size is (120,120).

---

## [Problem with this triangle that keeps randomly changing size](https://discourse.processing.org/t/problem-with-this-triangle-that-keeps-randomly-changing-size/7232)

<div class="topic-metadata">

**Author:** [@francium401](https://discourse.processing.org/u/francium401)\
**Replies:** 1\
**Last updated:** [January 5, 2019, 9:48pm UTC](https://discourse.processing.org/t/problem-with-this-triangle-that-keeps-randomly-changing-size/7232 "2019-01-05T21:48:39Z")

</div>

I’m only guessing that it has something to do with the fact that the moving circles are changing size, that it somehow makes the triangle do so as well. How would I go about keeping the triangle at a fixed size? (917, y…

---

## [Perspective bug in eclipse?](https://discourse.processing.org/t/perspective-bug-in-eclipse/7220)

<div class="topic-metadata">

**Author:** [@vjjv](https://discourse.processing.org/u/vjjv)\
**Replies:** 3\
**Last updated:** [January 5, 2019, 9:26pm UTC](https://discourse.processing.org/t/perspective-bug-in-eclipse/7220 "2019-01-05T21:26:34Z")

</div>

hello! im trying to do this en eclipse, using perspective to set the nearClip (is there any other way to set the near and far clip without the perspective() function?) in eclipse the function dont work fine, please take …

---

## [Screen with two buttons not showing the buttons](https://discourse.processing.org/t/screen-with-two-buttons-not-showing-the-buttons/7230)

<div class="topic-metadata">

**Author:** [@Banansplitt](https://discourse.processing.org/u/Banansplitt)\
**Replies:** 1\
**Last updated:** [January 5, 2019, 7:46pm UTC](https://discourse.processing.org/t/screen-with-two-buttons-not-showing-the-buttons/7230 "2019-01-05T19:46:18Z")

</div>

I tried making a programme that shows a screen with two buttons but all it shows is a blank screen. This is my code: int rect1X, rect1Y; //Position Button 1 (Option 1) int rect2X, rect2Y; //Position Button 2 (Option 2) …

---

## [Catching Balls Game Collision Problem](https://discourse.processing.org/t/catching-balls-game-collision-problem/7221)

<div class="topic-metadata">

**Author:** [@yamiyugi](https://discourse.processing.org/u/yamiyugi)\
**Replies:** 1\
**Last updated:** [January 5, 2019, 6:06pm UTC](https://discourse.processing.org/t/catching-balls-game-collision-problem/7221 "2019-01-05T18:06:16Z")

</div>

Hello, I’m trying to make a game with a stick figure with a basket that you can move with the right and left arrow key to catch balls falling from the top. So far I have the figure that moves and one ball falling and I …

---

## [Add "Kinect Camera" to processing.video\* Library](https://discourse.processing.org/t/add-kinect-camera-to-processing-video-library/7223)

<div class="topic-metadata">

**Author:** [@Hassan](https://discourse.processing.org/u/Hassan)\
**Replies:** 0\
**Last updated:** [January 5, 2019, 4:54pm UTC](https://discourse.processing.org/t/add-kinect-camera-to-processing-video-library/7223 "2019-01-05T16:54:00Z")

</div>

Hi, I recently watched a video named “11.1: Capture and Live Video - Processing Tutorial” by Mr. Daniel Shiffman on YouTube. My Problem is How to Add Kinect Camera in Processing for that Video. Mr. Daniel Shiffman says…

---

## [Creating a drawing environment in 3D](https://discourse.processing.org/t/creating-a-drawing-environment-in-3d/6952)

<div class="topic-metadata">

**Author:** [@helplouis](https://discourse.processing.org/u/helplouis)\
**Replies:** 12\
**Last updated:** [January 5, 2019, 3:57pm UTC](https://discourse.processing.org/t/creating-a-drawing-environment-in-3d/6952 "2019-01-05T15:57:13Z")

</div>

Hi! School project and I’m sort of a processing amateur but I get confused with a lot of stuff so I want to create a canvas in 3D that I can draw on, like literally draw continous lines and have other things around tha…

---

## [Processing on Debian: library initialization failed](https://discourse.processing.org/t/processing-on-debian-library-initialization-failed/7217)

<div class="topic-metadata">

**Author:** [@nex](https://discourse.processing.org/u/nex)\
**Replies:** 5\
**Last updated:** [January 5, 2019, 3:48pm UTC](https://discourse.processing.org/t/processing-on-debian-library-initialization-failed/7217 "2019-01-05T15:48:29Z")

</div>

I am having an issue running Processing 3.4 on Debian GNU/Linux sid. Processing would immediately terminate and show the error “library initialization failed - unable to allocate file descriptor table - out of memory”. …

---

## [\[Pong Game\] More relistic ball ricochet?](https://discourse.processing.org/t/pong-game-more-relistic-ball-ricochet/7215)

<div class="topic-metadata">

**Author:** [@Sky](https://discourse.processing.org/u/Sky)\
**Replies:** 1\
**Last updated:** [January 5, 2019, 2:20pm UTC](https://discourse.processing.org/t/pong-game-more-relistic-ball-ricochet/7215 "2019-01-05T14:20:16Z")

</div>

I am going to program a 2pl pong game, and I was wondering if there was a way to make ball ricochet a bit more realistic, because now I use a random num that I add to my Y. (The players will be on the left and right of …

---

## [Pixel Processing: Grabbing the Canvas, and Where's the Alpha?](https://discourse.processing.org/t/pixel-processing-grabbing-the-canvas-and-wheres-the-alpha/7162)

<div class="topic-metadata">

**Author:** [@Aleksi](https://discourse.processing.org/u/Aleksi)\
**Replies:** 14\
**Last updated:** [January 5, 2019, 12:03pm UTC](https://discourse.processing.org/t/pixel-processing-grabbing-the-canvas-and-wheres-the-alpha/7162 "2019-01-05T12:03:19Z")

</div>

Hello again. I’d like to be able to grab a small area from the canvas and process the pixels in such a way that I can alter the color of intersecting lines. Here’s an example of what I’m trying to accomplish. void setu…

---

## [Serialization and deserialization](https://discourse.processing.org/t/serialization-and-deserialization/6906)

<div class="topic-metadata">

**Author:** [@MoonMoon](https://discourse.processing.org/u/MoonMoon)\
**Replies:** 22\
**Last updated:** [January 5, 2019, 11:57am UTC](https://discourse.processing.org/t/serialization-and-deserialization/6906 "2019-01-05T11:57:52Z")

</div>

Hi! I’m new to processing, so please be patient and gentle :wink: I’ve installed the latest version (3.4) and I’m running Windows 10(x64) I’m quite advanced in programming Arduino Microcontroller and usually I use a co…

---

## [Basic calculator code error: "it looks like you are mixing active and static modes"](https://discourse.processing.org/t/basic-calculator-code-error-it-looks-like-you-are-mixing-active-and-static-modes/7194)

<div class="topic-metadata">

**Author:** [@bossofeng](https://discourse.processing.org/u/bossofeng)\
**Replies:** 13\
**Last updated:** [January 5, 2019, 7:15am UTC](https://discourse.processing.org/t/basic-calculator-code-error-it-looks-like-you-are-mixing-active-and-static-modes/7194 "2019-01-05T07:15:32Z")

</div>

I have a error it looks like you are mixing active and static modes can you help me My code: String input = ""; float input1 = 0; float input2 = 0; float result = 0; int operator = 0; boolean drawResult = false; vo…

---

## [Unable to figure out how to make these objects go in the opposite direction](https://discourse.processing.org/t/unable-to-figure-out-how-to-make-these-objects-go-in-the-opposite-direction/7155)

<div class="topic-metadata">

**Author:** [@francium401](https://discourse.processing.org/u/francium401)\
**Replies:** 3\
**Last updated:** [January 5, 2019, 6:44am UTC](https://discourse.processing.org/t/unable-to-figure-out-how-to-make-these-objects-go-in-the-opposite-direction/7155 "2019-01-05T06:44:04Z")

</div>

I want to make these circles go in the opposite direction (right to left, instead of left to right), but I can’t seem to figure out how. I managed to get them moving right to left by changing the speed value to a negati…

---

## [Lost My File on My Processing](https://discourse.processing.org/t/lost-my-file-on-my-processing/7182)

<div class="topic-metadata">

**Author:** [@Xaynerd](https://discourse.processing.org/u/Xaynerd)\
**Replies:** 1\
**Last updated:** [January 5, 2019, 1:00am UTC](https://discourse.processing.org/t/lost-my-file-on-my-processing/7182 "2019-01-05T01:00:05Z")

</div>

I lost all of the things I had programmed on to one of my files after an update that I never installed. I was wondering of any good way of recovering the file.

---

## [Basic calculator for android](https://discourse.processing.org/t/basic-calculator-for-android/7172)

<div class="topic-metadata">

**Author:** [@bossofeng](https://discourse.processing.org/u/bossofeng)\
**Replies:** 5\
**Last updated:** [January 4, 2019, 10:53pm UTC](https://discourse.processing.org/t/basic-calculator-for-android/7172 "2019-01-04T22:53:03Z")

</div>

I have a basic problem i write a basic calculator it works but i pressed then equal symbol if i press a new number first answer stay there and new answer write up last answer my english not very well so i will upload a p…

---

## [Processing wont start](https://discourse.processing.org/t/processing-wont-start/2193)

<div class="topic-metadata">

**Author:** [@matess7](https://discourse.processing.org/u/matess7)\
**Replies:** 7\
**Last updated:** [January 4, 2019, 2:38pm UTC](https://discourse.processing.org/t/processing-wont-start/2193 "2019-01-04T14:38:59Z")

</div>

Hey, i wanted to play around with processing but i cant seem to get it working. These are some things i found out: when i launch processing for the first time it starts up but if i try to run some code it crashes if i …

---

## [No working sql under apde](https://discourse.processing.org/t/no-working-sql-under-apde/3691)

<div class="topic-metadata">

**Author:** [@BodaciousBrian](https://discourse.processing.org/u/BodaciousBrian)\
**Replies:** 3\
**Last updated:** [January 4, 2019, 1:56pm UTC](https://discourse.processing.org/t/no-working-sql-under-apde/3691 "2019-01-04T13:56:55Z")

</div>

Under the bezier library, sqlite example 1 does the following: Failed to delete old APK file Sorry can't find any file named test.db make sure it exists and the path is correct. Using this database: test.db SQL.connect(…

---

## [Pong Game glitch!](https://discourse.processing.org/t/pong-game-glitch/7158)

<div class="topic-metadata">

**Author:** [@Benasin](https://discourse.processing.org/u/Benasin)\
**Replies:** 6\
**Last updated:** [January 4, 2019, 12:47pm UTC](https://discourse.processing.org/t/pong-game-glitch/7158 "2019-01-04T12:47:22Z")

</div>

I have been using Processing for a week and I have created a simple pong game but I have a problem is that when the ball hit the side parts of the rectangle movable bar it shows glitches and the ball doesn’t bounce but m…

---

## [Playing Multiple sounds at different times](https://discourse.processing.org/t/playing-multiple-sounds-at-different-times/7142)

<div class="topic-metadata">

**Author:** [@kristianjones81](https://discourse.processing.org/u/kristianjones81)\
**Replies:** 4\
**Last updated:** [January 4, 2019, 11:10am UTC](https://discourse.processing.org/t/playing-multiple-sounds-at-different-times/7142 "2019-01-04T11:10:54Z")

</div>

Hello everyone, my first post here. I’ve been wrestling with this code for a while now, I have managed to get it working to some degree, but I’ve run into an issue I can’t get my head around. I want load sounds into an …

---

## [Trying to combine two files - peasy cam issue](https://discourse.processing.org/t/trying-to-combine-two-files-peasy-cam-issue/7146)

<div class="topic-metadata">

**Author:** [@kritid](https://discourse.processing.org/u/kritid)\
**Replies:** 5\
**Last updated:** [January 4, 2019, 10:49am UTC](https://discourse.processing.org/t/trying-to-combine-two-files-peasy-cam-issue/7146 "2019-01-04T10:49:43Z")

</div>

I have two files A tree that grows. (branches grow organically from the root) This example is based on the 3D Fractal Tree Example by The Coding Train aka Daniel Shiffman. A movement trigger. That activates i++ each ti…

---

## [Buddhabrot : What is wrong in this algo?](https://discourse.processing.org/t/buddhabrot-what-is-wrong-in-this-algo/7075)

<div class="topic-metadata">

**Author:** [@NaoSi](https://discourse.processing.org/u/NaoSi)\
**Replies:** 0\
**Last updated:** [January 1, 2019, 6:57pm UTC](https://discourse.processing.org/t/buddhabrot-what-is-wrong-in-this-algo/7075 "2019-01-01T18:57:09Z")

</div>

Hey, I’m working in buddhabrot and I have a little issue in my algorithm and I don’t know how I can fix it. I followed lot of pseudo code in Google but it’s not enough… Can you help me? I think my problem is when I s…

---

## [Problem with char coordinates](https://discourse.processing.org/t/problem-with-char-coordinates/7120)

<div class="topic-metadata">

**Author:** [@lolonulu](https://discourse.processing.org/u/lolonulu)\
**Replies:** 3\
**Last updated:** [January 3, 2019, 6:42pm UTC](https://discourse.processing.org/t/problem-with-char-coordinates/7120 "2019-01-03T18:42:53Z")

</div>

Hello everybody, I would like to select the same chars in a String and to give each char the same coordinate… Here is my attempt below. I can only move the last char, why ?! Thanks alot in advance for your help. Best, …

---

## [Game Control Plus Unplug method](https://discourse.processing.org/t/game-control-plus-unplug-method/7139)

<div class="topic-metadata">

**Author:** [@robotijo](https://discourse.processing.org/u/robotijo)\
**Replies:** 0\
**Last updated:** [January 3, 2019, 5:46pm UTC](https://discourse.processing.org/t/game-control-plus-unplug-method/7139 "2019-01-03T17:46:48Z")

</div>

Hi, The class ControlButton has a method called plug(), it connects a button to a method . Are there any unplug method? or anyway to disconnect the button from a method. Thx!

---

## [Export to PDF will not render vectors](https://discourse.processing.org/t/export-to-pdf-will-not-render-vectors/7064)

<div class="topic-metadata">

**Author:** [@Hub33s](https://discourse.processing.org/u/Hub33s)\
**Replies:** 13\
**Last updated:** [January 3, 2019, 5:09pm UTC](https://discourse.processing.org/t/export-to-pdf-will-not-render-vectors/7064 "2019-01-03T17:09:14Z")

</div>

I am new to processing and was motivated to work on something I found interesting, things are coming along just fine but I can’t export vector based output from my sketch. I am using the Hype libraries hypeframework-dot-…

---

## [Issues with sound output](https://discourse.processing.org/t/issues-with-sound-output/7104)

<div class="topic-metadata">

**Author:** [@mllobet](https://discourse.processing.org/u/mllobet)\
**Replies:** 2\
**Last updated:** [January 3, 2019, 8:49am UTC](https://discourse.processing.org/t/issues-with-sound-output/7104 "2019-01-03T08:49:54Z")

</div>

I’m new in this stuff and my code can’t sound. Someone can help me to make that code sound? Thank you import ddf.minim.\*; import ddf.minim.ugens.\*; Minim minim; AudioOutput out; void setup(){ minim = new Minim(this); …

[Previous page](https://discourse.processing.org/c/processing/6.md?no_subcategories=false&page=331)

[Next page](https://discourse.processing.org/c/processing/6.md?no_subcategories=false&page=333)
