# Processing

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

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

**Page:** 287

---

## [How to run half element of array length](https://discourse.processing.org/t/how-to-run-half-element-of-array-length/12439)

<div class="topic-metadata">

**Author:** [@The\_nish](https://discourse.processing.org/u/The_nish)\
**Replies:** 2\
**Last updated:** [July 4, 2019, 11:07pm UTC](https://discourse.processing.org/t/how-to-run-half-element-of-array-length/12439 "2019-07-04T23:07:44Z")

</div>

i have 50 images and i want to run sequential each image in my folder and what i am trying to do is that i am creating an array of 100 images.but i have only 50 image and other 50 images Add in a sequence when program i…

---

## [\[SOLVED\] Class problem with ArrayList](https://discourse.processing.org/t/solved-class-problem-with-arraylist/12475)

<div class="topic-metadata">

**Author:** [@Zephyr](https://discourse.processing.org/u/Zephyr)\
**Replies:** 7\
**Last updated:** [July 4, 2019, 6:14pm UTC](https://discourse.processing.org/t/solved-class-problem-with-arraylist/12475 "2019-07-04T18:14:46Z")

</div>

Hi, I’m a beginner on Processing (thanks to Coding Train btw). I love it and I’ve just achieved a prog about the Fourier decomposition (3Blue1Brown’s videos are really inspiring). I want now to “draw” in this Fourier sty…

---

## [Choppy/Jittery fast motion - hardware or code?](https://discourse.processing.org/t/choppy-jittery-fast-motion-hardware-or-code/12448)

<div class="topic-metadata">

**Author:** [@gudmundursteinn](https://discourse.processing.org/u/gudmundursteinn)\
**Replies:** 7\
**Last updated:** [July 4, 2019, 11:39am UTC](https://discourse.processing.org/t/choppy-jittery-fast-motion-hardware-or-code/12448 "2019-07-04T11:39:11Z")

</div>

Hello. In the following example there is a stripped down version of everything I do in processing or have been doing since 2009, things moving across the screen at equal speed. All this time I have never seen a movemen…

---

## [Delay in Generating Moving Boxes](https://discourse.processing.org/t/delay-in-generating-moving-boxes/12379)

<div class="topic-metadata">

**Author:** [@Bigp0ppa](https://discourse.processing.org/u/Bigp0ppa)\
**Replies:** 23\
**Last updated:** [July 3, 2019, 6:46pm UTC](https://discourse.processing.org/t/delay-in-generating-moving-boxes/12379 "2019-07-03T18:46:46Z")

</div>

I’m attempting to make a game where boxes fly in from the left of the screen and the player must move the cursor to dodge them. However, when I add the delay where I believe it should go, the game stops working. Here is…

---

## [Losing decimals](https://discourse.processing.org/t/losing-decimals/12442)

<div class="topic-metadata">

**Author:** [@Waboqueox](https://discourse.processing.org/u/Waboqueox)\
**Replies:** 2\
**Last updated:** [July 3, 2019, 7:14am UTC](https://discourse.processing.org/t/losing-decimals/12442 "2019-07-03T07:14:08Z")

</div>

Hi people!! I’m getting mad trying to get some points with a lot of decimals… Maybe this is a stupid question or I’m crazy… but I remember using lot of decimals, with float or double variable types (in java). I’m usin…

---

## [Having random select from limited choices](https://discourse.processing.org/t/having-random-select-from-limited-choices/12451)

<div class="topic-metadata">

**Author:** [@pauldefazio](https://discourse.processing.org/u/pauldefazio)\
**Replies:** 3\
**Last updated:** [July 3, 2019, 5:54am UTC](https://discourse.processing.org/t/having-random-select-from-limited-choices/12451 "2019-07-03T05:54:23Z")

</div>

Hello! This is a pretty basic question but I haven’t found the answer yet. I’m working with some code from the loop tutorial to fill a screen with gray rectangles, each assigned a random lightness. I’ve posted my code b…

---

## [Input Data from Command Line](https://discourse.processing.org/t/input-data-from-command-line/12344)

<div class="topic-metadata">

**Author:** [@dlerner](https://discourse.processing.org/u/dlerner)\
**Replies:** 9\
**Last updated:** [July 3, 2019, 5:30am UTC](https://discourse.processing.org/t/input-data-from-command-line/12344 "2019-07-03T05:30:02Z")

</div>

I am trying to create a system to test motors and propellers and include a nice GUI using Processing. I am using an Arduino to measure some data but am also using certain other measurement tools that need to be plugged d…

---

## [save serial data to .txt file on Mac](https://discourse.processing.org/t/save-serial-data-to-txt-file-on-mac/12459)

<div class="topic-metadata">

**Author:** [@jasone](https://discourse.processing.org/u/jasone)\
**Replies:** 1\
**Last updated:** [July 3, 2019, 3:58am UTC](https://discourse.processing.org/t/save-serial-data-to-txt-file-on-mac/12459 "2019-07-03T03:58:25Z")

</div>

I state that I don’t know how to use processing. I need to save data sent via serial from Arduino to a .txt file on my mac. Can anyone help me?

---

## [Menubar with P3D](https://discourse.processing.org/t/menubar-with-p3d/12462)

<div class="topic-metadata">

**Author:** [@brcreswell](https://discourse.processing.org/u/brcreswell)\
**Replies:** 1\
**Last updated:** [July 3, 2019, 3:55am UTC](https://discourse.processing.org/t/menubar-with-p3d/12462 "2019-07-03T03:55:00Z")

</div>

Wondering if it’s possible to implement a system menubar while utilizing P3D. I’ve found ways of doing it with JFrame but this obviously doesn’t help me. I’ve been searching for hours but can’t seem to find anything. If…

---

## [Exception handling in processing.net.\* -- why can't I catch exceptions?](https://discourse.processing.org/t/exception-handling-in-processing-net-why-cant-i-catch-exceptions/12192)

<div class="topic-metadata">

**Author:** [@barryfagin](https://discourse.processing.org/u/barryfagin)\
**Replies:** 5\
**Last updated:** [July 3, 2019, 12:17am UTC](https://discourse.processing.org/t/exception-handling-in-processing-net-why-cant-i-catch-exceptions/12192 "2019-07-03T00:17:04Z")

</div>

ME: Computer science professor. Reasonably adept at processing, though not a guru. GOAL: To handle the exception in the code below, because I figure this is something my students will run into: import processing.net.…

---

## [Processing control of Ethernet to serial board](https://discourse.processing.org/t/processing-control-of-ethernet-to-serial-board/4562)

<div class="topic-metadata">

**Author:** [@glv](https://discourse.processing.org/u/glv)\
**Replies:** 7\
**Last updated:** [July 3, 2019, 12:13am UTC](https://discourse.processing.org/t/processing-control-of-ethernet-to-serial-board/4562 "2019-07-03T00:13:09Z")

</div>

Hello, I would like to use Processing to communicate with an Ethernet to serial device: https://www.usriot.com/products/serial-ttl-to-ethernet-module.html “serial to Ethernet” or “Ethernet to serial” references below …

---

## [Changing colours](https://discourse.processing.org/t/changing-colours/12390)

<div class="topic-metadata">

**Author:** [@karan26](https://discourse.processing.org/u/karan26)\
**Replies:** 4\
**Last updated:** [July 2, 2019, 2:45pm UTC](https://discourse.processing.org/t/changing-colours/12390 "2019-07-02T14:45:23Z")

</div>

hii,i want to change the colour of square with respect to change in the size of the square .i want dark colour in the centre and light colour on the edges. here is my code can anybody tell me what should i do? int squar…

---

## [Visualizing resultant forces](https://discourse.processing.org/t/visualizing-resultant-forces/12423)

<div class="topic-metadata">

**Author:** [@ele](https://discourse.processing.org/u/ele)\
**Replies:** 4\
**Last updated:** [July 2, 2019, 7:40am UTC](https://discourse.processing.org/t/visualizing-resultant-forces/12423 "2019-07-02T07:40:27Z")

</div>

Hello! I am trying to create a visualizer that shows the resultant force of three forces each angeled at 60 degrees from eachother. However - something is off, and I would love to get some help. The forces are values …

---

## [I want to use two-dimensional array to sort the score by the largest to smallest](https://discourse.processing.org/t/i-want-to-use-two-dimensional-array-to-sort-the-score-by-the-largest-to-smallest/12425)

<div class="topic-metadata">

**Author:** [@henry](https://discourse.processing.org/u/henry)\
**Replies:** 2\
**Last updated:** [July 2, 2019, 6:07am UTC](https://discourse.processing.org/t/i-want-to-use-two-dimensional-array-to-sort-the-score-by-the-largest-to-smallest/12425 "2019-07-02T06:07:39Z")

</div>

String\[\]score=loadStrings(“score.csv”); for (int i=1; i\<score.length; i++) { String \[\]\[\]tokens=split(score\[i\]\[\], “,”); int scores=Integer.parseInt(tokens\[i\]\[1\]); } //a = sort(a); //a=reverse(a); scores\[i\]\[1\]=so…

---

## [SEED link server IRIS](https://discourse.processing.org/t/seed-link-server-iris/12346)

<div class="topic-metadata">

**Author:** [@Gus\_Fermin](https://discourse.processing.org/u/Gus_Fermin)\
**Replies:** 0\
**Last updated:** [June 27, 2019, 5:08pm UTC](https://discourse.processing.org/t/seed-link-server-iris/12346 "2019-06-27T17:08:44Z")

</div>

Hello there from the Dom. Republic :slight\_smile: I am a visual artist, printmaking professor, and beginner creative coder. I have devoured @shiffman Daniel Shiffman’s book 'Learning Processing 2nd edition". I would li…

---

## [How to make a processing GUI with a slider and button talking to Arduino](https://discourse.processing.org/t/how-to-make-a-processing-gui-with-a-slider-and-button-talking-to-arduino/11934)

<div class="topic-metadata">

**Author:** [@burak.eral](https://discourse.processing.org/u/burak.eral)\
**Replies:** 8\
**Last updated:** [July 1, 2019, 9:08pm UTC](https://discourse.processing.org/t/how-to-make-a-processing-gui-with-a-slider-and-button-talking-to-arduino/11934 "2019-07-01T21:08:57Z")

</div>

Dear all; I am trying to make a guy with a slider and two buttons talking to Arduino. Unfortunately, I cannot detect the signals send from processing to Arduino. I think I am struggling to separately read the serial sig…

---

## [Shoot image and make it shrink (Processing)](https://discourse.processing.org/t/shoot-image-and-make-it-shrink-processing/12208)

<div class="topic-metadata">

**Author:** [@Hang](https://discourse.processing.org/u/Hang)\
**Replies:** 4\
**Last updated:** [July 1, 2019, 2:45pm UTC](https://discourse.processing.org/t/shoot-image-and-make-it-shrink-processing/12208 "2019-07-01T14:45:16Z")

</div>

Hi, I’m currently learning processing and making the program of rocket moving through middle of the screen. I’m gonna use image (png file) for the rocket. I want to make a rocket shoot with mouse like a sling shot. And …

---

## [Is it possible to create a connection between Server-Client using ipv4 ip?](https://discourse.processing.org/t/is-it-possible-to-create-a-connection-between-server-client-using-ipv4-ip/12410)

<div class="topic-metadata">

**Author:** [@Wirtex](https://discourse.processing.org/u/Wirtex)\
**Replies:** 6\
**Last updated:** [July 1, 2019, 12:46pm UTC](https://discourse.processing.org/t/is-it-possible-to-create-a-connection-between-server-client-using-ipv4-ip/12410 "2019-07-01T12:46:18Z")

</div>

Hi guys, I made some online games thanks to processing.net library but, I got a problem : the only way that I found to create a connection between Server-Client is using ipv6 but the problem is that I asked my operator …

---

## [Rendering image on P3D, is it a bug?](https://discourse.processing.org/t/rendering-image-on-p3d-is-it-a-bug/12367)

<div class="topic-metadata">

**Author:** [@GuilhermeVolker](https://discourse.processing.org/u/GuilhermeVolker)\
**Replies:** 6\
**Last updated:** [July 1, 2019, 8:48am UTC](https://discourse.processing.org/t/rendering-image-on-p3d-is-it-a-bug/12367 "2019-07-01T08:48:06Z")

</div>

I have this problem (show on the first image) that one arc is overlaping other image bellow, i did try to translate translate(0,0,1); it should work just fine but insted i have this very wierd result (2° image). That loo…

---

## [How can I center an object on my screen that moves?](https://discourse.processing.org/t/how-can-i-center-an-object-on-my-screen-that-moves/12196)

<div class="topic-metadata">

**Author:** [@Pan](https://discourse.processing.org/u/Pan)\
**Replies:** 4\
**Last updated:** [July 1, 2019, 7:56am UTC](https://discourse.processing.org/t/how-can-i-center-an-object-on-my-screen-that-moves/12196 "2019-07-01T07:56:56Z")

</div>

I’m trying to make the screen follow my two spaceships and I’m trying to center the middle of the two ships to my screen The coordinates of the point between the two ships are fx and fy. Here the code: boolean pause; …

---

## [Why do I get errors when using my iPad touch screen](https://discourse.processing.org/t/why-do-i-get-errors-when-using-my-ipad-touch-screen/12419)

<div class="topic-metadata">

**Author:** [@rbytes](https://discourse.processing.org/u/rbytes)\
**Replies:** 0\
**Last updated:** [July 1, 2019, 4:14am UTC](https://discourse.processing.org/t/why-do-i-get-errors-when-using-my-ipad-touch-screen/12419 "2019-07-01T04:14:12Z")

</div>

When running Processing sketches in Safari on my iPad, I keep getting the console popping up with “Script Error” every time I touch the screen. Yet the touch is detected properly as mouse input. It is just a nuisance to …

---

## [Multiplayer camera follow?](https://discourse.processing.org/t/multiplayer-camera-follow/12170)

<div class="topic-metadata">

**Author:** [@Pan](https://discourse.processing.org/u/Pan)\
**Replies:** 4\
**Last updated:** [July 1, 2019, 12:56am UTC](https://discourse.processing.org/t/multiplayer-camera-follow/12170 "2019-07-01T00:56:03Z")

</div>

Does anyone know of any method to make the camera follow several players in the Lemming Ball Z style? Thanks you for reading.

---

## [Picture is flickering when collision checked](https://discourse.processing.org/t/picture-is-flickering-when-collision-checked/12414)

<div class="topic-metadata">

**Author:** [@SunnyPlayz](https://discourse.processing.org/u/SunnyPlayz)\
**Replies:** 1\
**Last updated:** [July 1, 2019, 12:21am UTC](https://discourse.processing.org/t/picture-is-flickering-when-collision-checked/12414 "2019-07-01T00:21:42Z")

</div>

Hi, I have made it check for collision and the code works but it makes all the image flicker when it runs. Do i need to change the collision checker to not make images flicker? boolean checkCollision(int bLeft, int bRig…

---

## [Webcam in portrait not landscape with posenet](https://discourse.processing.org/t/webcam-in-portrait-not-landscape-with-posenet/12412)

<div class="topic-metadata">

**Author:** [@pinch](https://discourse.processing.org/u/pinch)\
**Replies:** 0\
**Last updated:** [June 30, 2019, 8:08pm UTC](https://discourse.processing.org/t/webcam-in-portrait-not-landscape-with-posenet/12412 "2019-06-30T20:08:30Z")

</div>

Hello, I try to use webcam in portrait mode with posenet without succes. Have you any example to do this ? Each time detection not working…

---

## [Non square Spritesheets S4P](https://discourse.processing.org/t/non-square-spritesheets-s4p/12369)

<div class="topic-metadata">

**Author:** [@InferNova](https://discourse.processing.org/u/InferNova)\
**Replies:** 12\
**Last updated:** [June 30, 2019, 8:07pm UTC](https://discourse.processing.org/t/non-square-spritesheets-s4p/12369 "2019-06-30T20:07:24Z")

</div>

Given a sprite-sheet which doesn’t have sprites placed out in a square form, what precaution could one take to load it in properly. As I am finding an issue that the sprite-sheet isn’t being ‘cut-up’ properly and the spr…

---

## [Scrolling problem with a bar graph](https://discourse.processing.org/t/scrolling-problem-with-a-bar-graph/12183)

<div class="topic-metadata">

**Author:** [@wordcounter](https://discourse.processing.org/u/wordcounter)\
**Replies:** 4\
**Last updated:** [June 30, 2019, 5:40pm UTC](https://discourse.processing.org/t/scrolling-problem-with-a-bar-graph/12183 "2019-06-30T17:40:02Z")

</div>

Hi! I’m new to processing and working on a data visualization of word frequency in a corpus of poems, shown through a bar graph. My problem is I can’t seem to figure out how to add vertical scroll/panning to my sketch to…

---

## [G4P get main window object](https://discourse.processing.org/t/g4p-get-main-window-object/12166)

<div class="topic-metadata">

**Author:** [@Frank-95](https://discourse.processing.org/u/Frank-95)\
**Replies:** 5\
**Last updated:** [June 30, 2019, 5:25pm UTC](https://discourse.processing.org/t/g4p-get-main-window-object/12166 "2019-06-30T17:25:45Z")

</div>

Hello. I’d like to get the main window GWindow object. My aim is to have the main window with some buttons, which when they are clicked set the main window as invisible and the new one as visible. When the new one is cl…

---

## [G4P changing the default text of DropList Button](https://discourse.processing.org/t/g4p-changing-the-default-text-of-droplist-button/12404)

<div class="topic-metadata">

**Author:** [@EricMo](https://discourse.processing.org/u/EricMo)\
**Replies:** 1\
**Last updated:** [June 30, 2019, 4:24pm UTC](https://discourse.processing.org/t/g4p-changing-the-default-text-of-droplist-button/12404 "2019-06-30T16:24:24Z")

</div>

Hello Is there a way we could customize the content of the DropList Button ? Today it seems to be fixed to “:” Ideally I would like to write here an arrow down sign🢓 Also, an other suggestions :slight\_smile: why no…

---

## [Make a method to get area, result should be 2000→ println(rect1.sumArea(rect2))](https://discourse.processing.org/t/make-a-method-to-get-area-result-should-be-2000-println-rect1-sumarea-rect2/12402)

<div class="topic-metadata">

**Author:** [@henry](https://discourse.processing.org/u/henry)\
**Replies:** 4\
**Last updated:** [June 30, 2019, 12:03pm UTC](https://discourse.processing.org/t/make-a-method-to-get-area-result-should-be-2000-println-rect1-sumarea-rect2/12402 "2019-06-30T12:03:54Z")

</div>

MyRect rect1; MyRect rect2; void setup(){ size(240,120); rectMode(CENTER); rect1=new MyRect(20,20,40,30); rect2=new MyRect(30,50,20,40); println(rect1.sumArea(rect2)); } void draw(){ rect1.drawShape(2); …

---

## [How to get multiple image pixel array](https://discourse.processing.org/t/how-to-get-multiple-image-pixel-array/12382)

<div class="topic-metadata">

**Author:** [@The\_nish](https://discourse.processing.org/u/The_nish)\
**Replies:** 2\
**Last updated:** [June 30, 2019, 4:31am UTC](https://discourse.processing.org/t/how-to-get-multiple-image-pixel-array/12382 "2019-06-30T04:31:06Z")

</div>

…post is deleted

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

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