# Processing

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

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

**Page:** 319

---

## [Issue with Geomerative library](https://discourse.processing.org/t/issue-with-geomerative-library/8684)

<div class="topic-metadata">

**Author:** [@lolonulu](https://discourse.processing.org/u/lolonulu)\
**Replies:** 3\
**Last updated:** [March 1, 2019, 5:25pm UTC](https://discourse.processing.org/t/issue-with-geomerative-library/8684 "2019-03-01T17:25:25Z")

</div>

Hello, I face an issue I don’t mange to solve. I show a multilines text written with the Geomerative library, to each sentence corresponds a sound, when the stanza is written the program switch to the next one. My quest…

---

## [Storing previous points when using a for-loop?](https://discourse.processing.org/t/storing-previous-points-when-using-a-for-loop/8829)

<div class="topic-metadata">

**Author:** [@JsRambles](https://discourse.processing.org/u/JsRambles)\
**Replies:** 2\
**Last updated:** [March 1, 2019, 2:11pm UTC](https://discourse.processing.org/t/storing-previous-points-when-using-a-for-loop/8829 "2019-03-01T14:11:41Z")

</div>

Hello, I am trying to make a 9 sided polygon using points and than connecting the points with lines. Reading other forums I know there is a way to do this using the vertex() commands and using arrays however this is fo…

---

## [Help making a diagonal ellipse](https://discourse.processing.org/t/help-making-a-diagonal-ellipse/8827)

<div class="topic-metadata">

**Author:** [@Velouria](https://discourse.processing.org/u/Velouria)\
**Replies:** 1\
**Last updated:** [March 1, 2019, 4:53am UTC](https://discourse.processing.org/t/help-making-a-diagonal-ellipse/8827 "2019-03-01T04:53:36Z")

</div>

Hi everyone! So i´ve been trying to make an ellipse that crosses the screen diagonally but even with the different types of ellipseMode i can only do them cross the screen either horizontally or vertically. Any suggesti…

---

## [Problem with AI for 2D games libr](https://discourse.processing.org/t/problem-with-ai-for-2d-games-libr/2068)

<div class="topic-metadata">

**Author:** [@Tymek](https://discourse.processing.org/u/Tymek)\
**Replies:** 1\
**Last updated:** [February 28, 2019, 11:00pm UTC](https://discourse.processing.org/t/problem-with-ai-for-2d-games-libr/2068 "2019-02-28T23:00:21Z")

</div>

Hello, im trying to make bot for simple pong game. I have problem with reseting bots position after scoring point. Any suggestions? //main func. import game2dai.\*; import game2dai.entities.\*; import game2dai.entityshap…

---

## [Adding wind to bouncing ball example](https://discourse.processing.org/t/adding-wind-to-bouncing-ball-example/8748)

<div class="topic-metadata">

**Author:** [@pieceofcrazy](https://discourse.processing.org/u/pieceofcrazy)\
**Replies:** 1\
**Last updated:** [February 28, 2019, 7:07pm UTC](https://discourse.processing.org/t/adding-wind-to-bouncing-ball-example/8748 "2019-02-28T19:07:00Z")

</div>

I’m pretty new to coding and while playing around with the BouncingBall example I tried to add some air pushing the ball up if the mouse button in pressed, but it looks really goofy because the ball just goes up in a str…

---

## [Sending images/JSON data over OSC w. oscP5?](https://discourse.processing.org/t/sending-images-json-data-over-osc-w-oscp5/8734)

<div class="topic-metadata">

**Author:** [@AndreasRef](https://discourse.processing.org/u/AndreasRef)\
**Replies:** 2\
**Last updated:** [February 28, 2019, 5:54pm UTC](https://discourse.processing.org/t/sending-images-json-data-over-osc-w-oscp5/8734 "2019-02-28T17:54:30Z")

</div>

Hi Perhaps a bit of a weird question, but are there any tutorials on how to send images and/or data in JSON-format over OSC using the oscP5 library? Or anyone here who has experience doing that kind of thing?

---

## [Corrupted .pde?](https://discourse.processing.org/t/corrupted-pde/8789)

<div class="topic-metadata">

**Author:** [@kigro](https://discourse.processing.org/u/kigro)\
**Replies:** 4\
**Last updated:** [February 28, 2019, 11:54am UTC](https://discourse.processing.org/t/corrupted-pde/8789 "2019-02-28T11:54:30Z")

</div>

So after working on a project for 5 hours on my Ubuntu laptop, I get home and try to open it on my pc: Is the file simply corrupt? Any way of recovering it? EDIT: Someone suggested checking for temp files on a Window…

---

## [Processing for arduino](https://discourse.processing.org/t/processing-for-arduino/8775)

<div class="topic-metadata">

**Author:** [@help](https://discourse.processing.org/u/help)\
**Replies:** 1\
**Last updated:** [February 28, 2019, 1:47am UTC](https://discourse.processing.org/t/processing-for-arduino/8775 "2019-02-28T01:47:00Z")

</div>

hi im fake joe ! i am trying to send f to my arduino and it fights me ! posting the arduino and the processing clip ! small clip of much larger program ! the arduino runs fine if i use the serial monitor ! i just typ…

---

## [Minification question](https://discourse.processing.org/t/minification-question/8724)

<div class="topic-metadata">

**Author:** [@Tsskyx](https://discourse.processing.org/u/Tsskyx)\
**Replies:** 6\
**Last updated:** [February 27, 2019, 8:02pm UTC](https://discourse.processing.org/t/minification-question/8724 "2019-02-27T20:02:05Z")

</div>

The following code cycles the value of the variable NET within a range of 0 to 4. int NET; void setup() { println(NET); } void draw() { } void keyPressed() { if (keyCode == UP || keyCode == DOWN) NET = ((NET += keyC…

---

## [How to scale text and distance proportionally to avoid overlap?](https://discourse.processing.org/t/how-to-scale-text-and-distance-proportionally-to-avoid-overlap/8763)

<div class="topic-metadata">

**Author:** [@jacobo](https://discourse.processing.org/u/jacobo)\
**Replies:** 1\
**Last updated:** [February 27, 2019, 6:52pm UTC](https://discourse.processing.org/t/how-to-scale-text-and-distance-proportionally-to-avoid-overlap/8763 "2019-02-27T18:52:17Z")

</div>

Hi! I want to be able to scale text size and spacing/leading proportionally to avoid overlaps of text. I’d like to be able to scale the text from it’s current size in 5 columns to a bigger text size in for example 3 colu…

---

## [Problem with adding objects to ArrayList](https://discourse.processing.org/t/problem-with-adding-objects-to-arraylist/8764)

<div class="topic-metadata">

**Author:** [@Tymek](https://discourse.processing.org/u/Tymek)\
**Replies:** 3\
**Last updated:** [February 27, 2019, 5:27pm UTC](https://discourse.processing.org/t/problem-with-adding-objects-to-arraylist/8764 "2019-02-27T17:27:48Z")

</div>

Hello, I wonder how to add object to ArrayList, when some conditions have been fullfiled. For example, i want to add new cell only if my mouse coursor is over one of each cells. Code is here. Thanks in advance :slight\_s…

---

## [Calling a function that returns array stops printArray](https://discourse.processing.org/t/calling-a-function-that-returns-array-stops-printarray/6108)

<div class="topic-metadata">

**Author:** [@thenewkgb](https://discourse.processing.org/u/thenewkgb)\
**Replies:** 15\
**Last updated:** [February 27, 2019, 3:59pm UTC](https://discourse.processing.org/t/calling-a-function-that-returns-array-stops-printarray/6108 "2019-02-27T15:59:13Z")

</div>

Try uncommenting grabline’s (r\[\]=details;) line. I haven’t been instructed where to place things really. Any help? int ws=6; int ls=6; int sx=0; int ex=findex(); int myline\[\]; void setup() { background(255); size(…

---

## [I'd like to convert Processing code into C++ code](https://discourse.processing.org/t/id-like-to-convert-processing-code-into-c-code/8752)

<div class="topic-metadata">

**Author:** [@AngelsApple](https://discourse.processing.org/u/AngelsApple)\
**Replies:** 5\
**Last updated:** [February 27, 2019, 11:07am UTC](https://discourse.processing.org/t/id-like-to-convert-processing-code-into-c-code/8752 "2019-02-27T11:07:34Z")

</div>

Hi boys&girls, I want to Processing code into C++ code Since I studied Processing as a first coding language, It feels so confused when I try to study other coding languages. Language that I’m studying now is C++ langu…

---

## [Where is "Enable code folding" in Processing IDE?](https://discourse.processing.org/t/where-is-enable-code-folding-in-processing-ide/8710)

<div class="topic-metadata">

**Author:** [@miasoft](https://discourse.processing.org/u/miasoft)\
**Replies:** 5\
**Last updated:** [February 27, 2019, 4:26am UTC](https://discourse.processing.org/t/where-is-enable-code-folding-in-processing-ide/8710 "2019-02-27T04:26:29Z")

</div>

In Arduino IDE code folding is availabel, but in Processing IDE isn’t. Why?

---

## [PImages change to null in separate class](https://discourse.processing.org/t/pimages-change-to-null-in-separate-class/8403)

<div class="topic-metadata">

**Author:** [@Kyle](https://discourse.processing.org/u/Kyle)\
**Replies:** 9\
**Last updated:** [February 27, 2019, 4:05am UTC](https://discourse.processing.org/t/pimages-change-to-null-in-separate-class/8403 "2019-02-27T04:05:49Z")

</div>

I am using Processing core in Eclipse IDE, and I’m currently working on some code where I have many object classes inside of the main class. Recently I decided to move one of those classes (a class called bat) into a sep…

---

## [Text() on Mac causes program to pause](https://discourse.processing.org/t/text-on-mac-causes-program-to-pause/8353)

<div class="topic-metadata">

**Author:** [@sgolanka](https://discourse.processing.org/u/sgolanka)\
**Replies:** 3\
**Last updated:** [February 26, 2019, 6:36pm UTC](https://discourse.processing.org/t/text-on-mac-causes-program-to-pause/8353 "2019-02-26T18:36:00Z")

</div>

This problem occurs on Apple computers, but not not on Windows. The code below comes from a simple game. When the condition is true, the program (on a Mac), stops for a few seconds, and then displays “You Lose.” When…

---

## [Proper wraparound](https://discourse.processing.org/t/proper-wraparound/8702)

<div class="topic-metadata">

**Author:** [@LordCacops](https://discourse.processing.org/u/LordCacops)\
**Replies:** 2\
**Last updated:** [February 26, 2019, 5:11pm UTC](https://discourse.processing.org/t/proper-wraparound/8702 "2019-02-26T17:11:26Z")

</div>

Hey! I have these colored grids, 192 pixels wide, 120 pixels tall, and they move. I want them to wraparound the horizontal dimension so that when they start going out one side, right away they start popping out of the o…

---

## [\[SOLVED\] Using minim getLineIn() to listen to the speaker output](https://discourse.processing.org/t/solved-using-minim-getlinein-to-listen-to-the-speaker-output/8723)

<div class="topic-metadata">

**Author:** [@Xabdro](https://discourse.processing.org/u/Xabdro)\
**Replies:** 2\
**Last updated:** [February 26, 2019, 4:21pm UTC](https://discourse.processing.org/t/solved-using-minim-getlinein-to-listen-to-the-speaker-output/8723 "2019-02-26T16:21:31Z")

</div>

I want to use minim to visualise the music playing on my computer from spotify. I have looked around online and the only way I have found to do this is to use stereo mix which my computer doesn’t support. I have found a …

---

## [Draw this Polygon using loops?](https://discourse.processing.org/t/draw-this-polygon-using-loops/1588)

<div class="topic-metadata">

**Author:** [@nerdboybi](https://discourse.processing.org/u/nerdboybi)\
**Replies:** 18\
**Last updated:** [February 26, 2019, 3:50pm UTC](https://discourse.processing.org/t/draw-this-polygon-using-loops/1588 "2019-02-26T15:50:35Z")

</div>

Its from a textbook and I just need a solution so I can get an idea on how to use loops

---

## [How to take frame not from all window](https://discourse.processing.org/t/how-to-take-frame-not-from-all-window/8683)

<div class="topic-metadata">

**Author:** [@Grisha](https://discourse.processing.org/u/Grisha)\
**Replies:** 2\
**Last updated:** [February 26, 2019, 8:48am UTC](https://discourse.processing.org/t/how-to-take-frame-not-from-all-window/8683 "2019-02-26T08:48:45Z")

</div>

How to take frame not from all window? I need to save only one part of my window .

---

## [Animation for a quadrilateral polygon assistance](https://discourse.processing.org/t/animation-for-a-quadrilateral-polygon-assistance/8679)

<div class="topic-metadata">

**Author:** [@NationalRex22](https://discourse.processing.org/u/NationalRex22)\
**Replies:** 3\
**Last updated:** [February 25, 2019, 11:18pm UTC](https://discourse.processing.org/t/animation-for-a-quadrilateral-polygon-assistance/8679 "2019-02-25T23:18:05Z")

</div>

Hello, I’m interested in developing an animated loop for a quadrilateral polygon that slowly moves down vertically from its initial position to the exact position of a quadrilateral polygon of the same size. Finally, th…

---

## [SimpleOpenNI - Kinect depth map size](https://discourse.processing.org/t/simpleopenni-kinect-depth-map-size/8722)

<div class="topic-metadata">

**Author:** [@Jackieh111](https://discourse.processing.org/u/Jackieh111)\
**Replies:** 0\
**Last updated:** [February 25, 2019, 9:44pm UTC](https://discourse.processing.org/t/simpleopenni-kinect-depth-map-size/8722 "2019-02-25T21:44:04Z")

</div>

I’m using a Kinect for Windows on OSx with SimpleOpenNI - can anyone tell me why the depthMap is giving me a size of 640x480 when I am expecting it to be 512x424 which is the resolution for Kinect2?

---

## [How to mute minim filter](https://discourse.processing.org/t/how-to-mute-minim-filter/8610)

<div class="topic-metadata">

**Author:** [@b\_and\_z](https://discourse.processing.org/u/b_and_z)\
**Replies:** 6\
**Last updated:** [February 25, 2019, 5:30pm UTC](https://discourse.processing.org/t/how-to-mute-minim-filter/8610 "2019-02-25T17:30:01Z")

</div>

So I am building a synthesizer using the minim and oscP5 (controlling the synthesizer via touchOSC). Now I have this minim bandPass Filter set up, but I only want the filter to be active when a certain button is active (…

---

## [Draw from text file not working as expected](https://discourse.processing.org/t/draw-from-text-file-not-working-as-expected/8498)

<div class="topic-metadata">

**Author:** [@socraticbot](https://discourse.processing.org/u/socraticbot)\
**Replies:** 21\
**Last updated:** [February 25, 2019, 4:21pm UTC](https://discourse.processing.org/t/draw-from-text-file-not-working-as-expected/8498 "2019-02-25T16:21:52Z")

</div>

Hi all, I have a script which finds all the black pixels in an image along a spiral path and saves it to a text file. float r = 0; float theta = 0; PImage input; String\[\] output; void setup() { size(300, 300); bac…

---

## [keyPresssed not returning proper value](https://discourse.processing.org/t/keypresssed-not-returning-proper-value/8701)

<div class="topic-metadata">

**Author:** [@dragonheart0001](https://discourse.processing.org/u/dragonheart0001)\
**Replies:** 11\
**Last updated:** [February 25, 2019, 5:24am UTC](https://discourse.processing.org/t/keypresssed-not-returning-proper-value/8701 "2019-02-25T05:24:05Z")

</div>

I am trying to create a basic input interface for project I am working on and am running into a bug where the keyPressed variable always returns false. Here’s the basic idea of the code. void setup() { int startTime =…

---

## [Extending Kinect v2.0 cable](https://discourse.processing.org/t/extending-kinect-v2-0-cable/8649)

<div class="topic-metadata">

**Author:** [@Fausto](https://discourse.processing.org/u/Fausto)\
**Replies:** 2\
**Last updated:** [February 25, 2019, 4:49am UTC](https://discourse.processing.org/t/extending-kinect-v2-0-cable/8649 "2019-02-25T04:49:06Z")

</div>

Hi Processing community, for an installation I am working on at the moment, I need to have one Kinect v2.0 about 10m away from my computer. Ideally I would like to have the Kinect at 20m, but 10m away could potentially…

---

## [New Mac, Unable to Use Sound Library!](https://discourse.processing.org/t/new-mac-unable-to-use-sound-library/8695)

<div class="topic-metadata">

**Author:** [@storchzr](https://discourse.processing.org/u/storchzr)\
**Replies:** 1\
**Last updated:** [February 25, 2019, 12:50am UTC](https://discourse.processing.org/t/new-mac-unable-to-use-sound-library/8695 "2019-02-25T00:50:02Z")

</div>

Can anyone help me with this? I have a piece of code that uses input from the mic to create graphics. It worked on my old computer but won’t work on the new mac with touchbar for some reason. // Example 20-5: Live Input…

---

## [Scrubbing video with Microphone input](https://discourse.processing.org/t/scrubbing-video-with-microphone-input/8060)

<div class="topic-metadata">

**Author:** [@Sigsound](https://discourse.processing.org/u/Sigsound)\
**Replies:** 3\
**Last updated:** [February 25, 2019, 12:25am UTC](https://discourse.processing.org/t/scrubbing-video-with-microphone-input/8060 "2019-02-25T00:25:12Z")

</div>

Hello! I’m trying to create an animation that goes from very little complexity to very great complexity based on the volume level in a room. I started with the processing.sound library and this basic tutorial for mic i…

---

## [Array Sorting visually](https://discourse.processing.org/t/array-sorting-visually/803)

<div class="topic-metadata">

**Author:** [@bertin](https://discourse.processing.org/u/bertin)\
**Replies:** 5\
**Last updated:** [June 10, 2018, 2:19am UTC](https://discourse.processing.org/t/array-sorting-visually/803 "2018-06-10T02:19:24Z")

</div>

Hi everyone! This is my first topic, hoping not to do something wrong. I was trying to develop a simple sketch that shows in real time the sorting algorithms of an array of integers, through simple vertical lines which …

---

## [Color image to black and white image](https://discourse.processing.org/t/color-image-to-black-and-white-image/8662)

<div class="topic-metadata">

**Author:** [@Grisha](https://discourse.processing.org/u/Grisha)\
**Replies:** 2\
**Last updated:** [February 24, 2019, 7:07pm UTC](https://discourse.processing.org/t/color-image-to-black-and-white-image/8662 "2019-02-24T19:07:32Z")

</div>

How to make a black and white image from color image . Maybe using OpenCV? Because I don’t need combination of black and white pixels , but I need a gray gradient image ( I hope you understand what I mean )

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

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