# Latest

**URL:** https://discourse.processing.org/latest.md?no_subcategories=false&page=616

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

**Page:** 617

---

## [Scrollable list to Bang](https://discourse.processing.org/t/scrollable-list-to-bang/857)

<div class="topic-metadata">

**Author:** [@GarethWilkins](https://discourse.processing.org/u/GarethWilkins)\
**Replies:** 4\
**Last updated:** [June 12, 2018, 9:17am UTC](https://discourse.processing.org/t/scrollable-list-to-bang/857 "2018-06-12T09:17:19Z")

</div>

I have scrollable list and i want to use the picked items in these to feed into 4 bangs which will then play different sets of sounds. I am struggling working out how to get this info to the bangs. Any help will be grea…

---

## [Android: positioning of a toast](https://discourse.processing.org/t/android-positioning-of-a-toast/867)

<div class="topic-metadata">

**Author:** [@noel](https://discourse.processing.org/u/noel)\
**Replies:** 1\
**Last updated:** [June 12, 2018, 1:35am UTC](https://discourse.processing.org/t/android-positioning-of-a-toast/867 "2018-06-12T01:35:09Z")

</div>

Hi. My code for a toast is: void showToast(final String message) { act.runOnUiThread(new Runnable() { public void run() { android.widget.Toast.makeText(act.getApplicationContext(), message, android.widge…

---

## [How do you create a wall?](https://discourse.processing.org/t/how-do-you-create-a-wall/873)

<div class="topic-metadata">

**Author:** [@Ssskyyy](https://discourse.processing.org/u/Ssskyyy)\
**Replies:** 6\
**Last updated:** [June 11, 2018, 5:04pm UTC](https://discourse.processing.org/t/how-do-you-create-a-wall/873 "2018-06-11T17:04:31Z")

</div>

Hi there! I’ve just started with Processing and am still learning. But I’ve ran into a problem already. This is my code: int xPos = 25; int yPos = 25; void setup(){ fullScreen(); } void draw(){ //This is the bac…

---

## [Processing for windows in P5 mode there is no debug options](https://discourse.processing.org/t/processing-for-windows-in-p5-mode-there-is-no-debug-options/820)

<div class="topic-metadata">

**Author:** [@Serge](https://discourse.processing.org/u/Serge)\
**Replies:** 2\
**Last updated:** [June 11, 2018, 4:48pm UTC](https://discourse.processing.org/t/processing-for-windows-in-p5-mode-there-is-no-debug-options/820 "2018-06-11T16:48:40Z")

</div>

Is there a library or something to get the debug option in P5 processing editor

---

## [Multiple windows - clone one to another with pgraphics obj](https://discourse.processing.org/t/multiple-windows-clone-one-to-another-with-pgraphics-obj/869)

<div class="topic-metadata">

**Author:** [@bitCrasher](https://discourse.processing.org/u/bitCrasher)\
**Replies:** 7\
**Last updated:** [June 11, 2018, 4:28pm UTC](https://discourse.processing.org/t/multiple-windows-clone-one-to-another-with-pgraphics-obj/869 "2018-06-11T16:28:52Z")

</div>

hi to all! i want clone one windows into another: if i use this code: PWindow win; PGraphics pg; public void settings() { size(640, 480); } void setup() { win = new PWindow(); pg = createGraphics(width, hei…

---

## [How can I switch between ControlP5s without skipping pages?](https://discourse.processing.org/t/how-can-i-switch-between-controlp5s-without-skipping-pages/864)

<div class="topic-metadata">

**Author:** [@britnicanale](https://discourse.processing.org/u/britnicanale)\
**Replies:** 1\
**Last updated:** [June 11, 2018, 4:15pm UTC](https://discourse.processing.org/t/how-can-i-switch-between-controlp5s-without-skipping-pages/864 "2018-06-11T16:15:38Z")

</div>

I’m creating a game in processing and I’m having issues with my GUI using ControlP5. My current setup is that there is a startwindow ControlP5, a tankswindow ControlP5, a howtoplaywindow ControlP5, etc. My issue is that …

---

## [Array Isn't Detected In Parameter](https://discourse.processing.org/t/array-isnt-detected-in-parameter/862)

<div class="topic-metadata">

**Author:** [@Avid\_Coder](https://discourse.processing.org/u/Avid_Coder)\
**Replies:** 3\
**Last updated:** [June 11, 2018, 3:40pm UTC](https://discourse.processing.org/t/array-isnt-detected-in-parameter/862 "2018-06-11T15:40:28Z")

</div>

I am trying to make an animation system to display images with a certain frame rate. While attempting to pass the function an array, it said I had not created an array or variable with that name. I tried adding square br…

---

## [Inserting a variable into a 2D array](https://discourse.processing.org/t/inserting-a-variable-into-a-2d-array/866)

<div class="topic-metadata">

**Author:** [@JaKa](https://discourse.processing.org/u/JaKa)\
**Replies:** 1\
**Last updated:** [June 11, 2018, 8:15am UTC](https://discourse.processing.org/t/inserting-a-variable-into-a-2d-array/866 "2018-06-11T08:15:41Z")

</div>

Im unsure of how i can put either the x or an o into my 2d array for my 7x7 naughts and crosses type game? class cell{ String player; int turnNum; char shape; cell(int row, int col){ } } cell\[\]\[\] grid=new c…

---

## [Random not working](https://discourse.processing.org/t/random-not-working/838)

<div class="topic-metadata">

**Author:** [@pootis](https://discourse.processing.org/u/pootis)\
**Replies:** 3\
**Last updated:** [June 10, 2018, 8:08pm UTC](https://discourse.processing.org/t/random-not-working/838 "2018-06-10T20:08:51Z")

</div>

im trying to get a ball to spawn on one of three heights: 100, 200 and 300. i set the random to produce a number from 1 to 3. when the outcome is 1 the height is 100, when it’s 2 the height is 200 and when it’s 3 the hei…

---

## [Execution time of one program](https://discourse.processing.org/t/execution-time-of-one-program/253)

<div class="topic-metadata">

**Author:** [@totovr76](https://discourse.processing.org/u/totovr76)\
**Replies:** 8\
**Last updated:** [June 10, 2018, 5:56pm UTC](https://discourse.processing.org/t/execution-time-of-one-program/253 "2018-06-10T17:56:56Z")

</div>

Hello! How can I measure the execution time of one program?

---

## [Inaccuracy in exponential pow() function](https://discourse.processing.org/t/inaccuracy-in-exponential-pow-function/817)

<div class="topic-metadata">

**Author:** [@neoumlaut](https://discourse.processing.org/u/neoumlaut)\
**Replies:** 4\
**Last updated:** [June 10, 2018, 2:50pm UTC](https://discourse.processing.org/t/inaccuracy-in-exponential-pow-function/817 "2018-06-10T14:50:58Z")

</div>

I’m working on a program that displays data from an oscilloscope over a serial connection and have run into a problem converting from scientific notation. If I receive a number, for example, 5.72E-1, I then convert it us…

---

## [Wave displaced circle](https://discourse.processing.org/t/wave-displaced-circle/808)

<div class="topic-metadata">

**Author:** [@josephh](https://discourse.processing.org/u/josephh)\
**Replies:** 4\
**Last updated:** [June 10, 2018, 11:08am UTC](https://discourse.processing.org/t/wave-displaced-circle/808 "2018-06-10T11:08:31Z")

</div>

Hi guys, I’m trying to replicate this animation in processing : But I can’t figure out how to do it, this is my code : Circle c1,c2; void setup() { size(800, 800); c1 = new Circle(0,0,200,0); c…

---

## [Smart TV, RPi, Processing, Arduino and Ambilight](https://discourse.processing.org/t/smart-tv-rpi-processing-arduino-and-ambilight/797)

<div class="topic-metadata">

**Author:** [@jb4x](https://discourse.processing.org/u/jb4x)\
**Replies:** 2\
**Last updated:** [June 10, 2018, 8:50am UTC](https://discourse.processing.org/t/smart-tv-rpi-processing-arduino-and-ambilight/797 "2018-06-10T08:50:23Z")

</div>

Hi guys, I’m not sure I’m in the right place to ask that question and I should probably go on a Raspberry Pi forum but maybe someone here can help me through anyway. I recently bought a smart TV and I wanted to build a…

---

## [Issues creating a metronome](https://discourse.processing.org/t/issues-creating-a-metronome/815)

<div class="topic-metadata">

**Author:** [@ThibaultMuller](https://discourse.processing.org/u/ThibaultMuller)\
**Replies:** 8\
**Last updated:** [June 10, 2018, 6:33am UTC](https://discourse.processing.org/t/issues-creating-a-metronome/815 "2018-06-10T06:33:40Z")

</div>

Hello, I’m trying to build a video game to measure the rhythm accuracy of a player. The program should display rhythms, the player has to play them in sync with a metronome. I’ve been trying to build a sketch that woul…

---

## [Increasing maximum available memory testing. How to get better results?](https://discourse.processing.org/t/increasing-maximum-available-memory-testing-how-to-get-better-results/825)

<div class="topic-metadata">

**Author:** [@bontempos](https://discourse.processing.org/u/bontempos)\
**Replies:** 0\
**Last updated:** [June 10, 2018, 2:27am UTC](https://discourse.processing.org/t/increasing-maximum-available-memory-testing-how-to-get-better-results/825 "2018-06-10T02:27:45Z")

</div>

This is a i7-8700, 32Gb of RAM, NVIDIA GeForce GTX 1080, running Windows 10 and Java 8 (171) installed and heap memory set to max 32Gb(-Xmx32g) (?) on run parameters. I think this is not a question about library. Howev…

---

## [Arduino LED Hello World](https://discourse.processing.org/t/arduino-led-hello-world/819)

<div class="topic-metadata">

**Author:** [@Onsgaannoubraai](https://discourse.processing.org/u/Onsgaannoubraai)\
**Replies:** 0\
**Last updated:** [June 9, 2018, 10:01pm UTC](https://discourse.processing.org/t/arduino-led-hello-world/819 "2018-06-09T22:01:22Z")

</div>

Beginner to P5js and Arduinos. Trying to setup a LED on the Arduino (windows machine + dont have a rgb LED) to blink on arrow key press for the Hello World setup. Using the example files I have commented in the LED on …

---

## [Num undefined, no messages](https://discourse.processing.org/t/num-undefined-no-messages/813)

<div class="topic-metadata">

**Author:** [@Serge](https://discourse.processing.org/u/Serge)\
**Replies:** 6\
**Last updated:** [June 9, 2018, 9:49pm UTC](https://discourse.processing.org/t/num-undefined-no-messages/813 "2018-06-09T21:49:17Z")

</div>

https://p5js.org/examples/structure-functions.html in this example num is use but is not defined What is this num variable? argument not defined? else? Here is the code: function setup() { createCanvas(720, 400); …

---

## [Writing 8-bit tiff images?](https://discourse.processing.org/t/writing-8-bit-tiff-images/726)

<div class="topic-metadata">

**Author:** [@tmhoog](https://discourse.processing.org/u/tmhoog)\
**Replies:** 6\
**Last updated:** [June 9, 2018, 2:22pm UTC](https://discourse.processing.org/t/writing-8-bit-tiff-images/726 "2018-06-09T14:22:04Z")

</div>

Hi, we are using Processing to acquire data and write a video stream to disk. However, we are unable to figure out how to write one-channel 8-bit grayscale tiff images instead of the standard RGB images. Does anyone have…

---

## [Trying to load an array from a JSON](https://discourse.processing.org/t/trying-to-load-an-array-from-a-json/685)

<div class="topic-metadata">

**Author:** [@Red\_Hen](https://discourse.processing.org/u/Red_Hen)\
**Replies:** 3\
**Last updated:** [June 9, 2018, 10:21am UTC](https://discourse.processing.org/t/trying-to-load-an-array-from-a-json/685 "2018-06-09T10:21:36Z")

</div>

Hello! So, I’m trying to get data from a JSON file, where the data was saved as an array. But when I try to retrieve discrete values, they come back as ‘undefined’. Can you help? What am I doing wrong? let locJ = 'des…

---

## [How do I get the keyCode?](https://discourse.processing.org/t/how-do-i-get-the-keycode/794)

<div class="topic-metadata">

**Author:** [@Grimtin10](https://discourse.processing.org/u/Grimtin10)\
**Replies:** 14\
**Last updated:** [June 8, 2018, 4:19pm UTC](https://discourse.processing.org/t/how-do-i-get-the-keycode/794 "2018-06-08T16:19:11Z")

</div>

I want to make a KeyHandler class to make it so I can press multiple keys, but I don’t know how to get the ASCII integer value for every key, how do I do this?

---

## [Processing 2.0 error on New GLabel](https://discourse.processing.org/t/processing-2-0-error-on-new-glabel/724)

<div class="topic-metadata">

**Author:** [@piscvau](https://discourse.processing.org/u/piscvau)\
**Replies:** 3\
**Last updated:** [June 8, 2018, 9:44am UTC](https://discourse.processing.org/t/processing-2-0-error-on-new-glabel/724 "2018-06-08T09:44:07Z")

</div>

Hello I am trying to run a code from Github which was written in october 2015. I do not knwo which version of processing was used. The code is using the G4P and Sdrop librairies. I installed processing 3 but ran into an…

---

## [Fix code to make spaceship blaster shoot](https://discourse.processing.org/t/fix-code-to-make-spaceship-blaster-shoot/789)

<div class="topic-metadata">

**Author:** [@the-junk](https://discourse.processing.org/u/the-junk)\
**Replies:** 3\
**Last updated:** [June 8, 2018, 8:17am UTC](https://discourse.processing.org/t/fix-code-to-make-spaceship-blaster-shoot/789 "2018-06-08T08:17:46Z")

</div>

Why won’t my code work to make my spaceship blaster shoot? float shipX; // player spaceship float shipY; // player spaceship float enemyX; //enemy UFO float enemyY; //enemy UFO float enemySpeed = 2; float blastX; floa…

---

## [How do i tile an image on to a shape](https://discourse.processing.org/t/how-do-i-tile-an-image-on-to-a-shape/665)

<div class="topic-metadata">

**Author:** [@Grimtin10](https://discourse.processing.org/u/Grimtin10)\
**Replies:** 5\
**Last updated:** [June 8, 2018, 2:53am UTC](https://discourse.processing.org/t/how-do-i-tile-an-image-on-to-a-shape/665 "2018-06-08T02:53:43Z")

</div>

So, i’m making a 3d renderer (because i can) and I want to be able to tile a texture on to a shape in the renderer. I am using the PShape (or whatever it’s called). How to I tile an image on to one shape? -Grim

---

## [Upcoming changes for OpenGL on Mac](https://discourse.processing.org/t/upcoming-changes-for-opengl-on-mac/756)

<div class="topic-metadata">

**Author:** [@justin\_lincoln](https://discourse.processing.org/u/justin_lincoln)\
**Replies:** 3\
**Last updated:** [June 8, 2018, 2:30am UTC](https://discourse.processing.org/t/upcoming-changes-for-opengl-on-mac/756 "2018-06-08T02:30:25Z")

</div>

http://cdm.link/2018/06/apple-to-open-source-cross-platform-gpu-tech-drop-dead/ . Curious if anyone knows what this will mean for Processing? I’m aware that it uses OpenGL. Eventually will it only be available for PC?

---

## [Need to know how to make a draggable Tower of Hanoi game for a school project](https://discourse.processing.org/t/need-to-know-how-to-make-a-draggable-tower-of-hanoi-game-for-a-school-project/617)

<div class="topic-metadata">

**Author:** [@Dankid\_123](https://discourse.processing.org/u/Dankid_123)\
**Replies:** 3\
**Last updated:** [June 8, 2018, 2:25am UTC](https://discourse.processing.org/t/need-to-know-how-to-make-a-draggable-tower-of-hanoi-game-for-a-school-project/617 "2018-06-08T02:25:24Z")

</div>

Hi, I have a school project about to make a Tower of Hanoi game, I’ve made all the rings and stuff, but I have very little knowledge about dragging and other interaction options in Processing. I haven’t finished, but her…

---

## [Multiple parallel animations](https://discourse.processing.org/t/multiple-parallel-animations/780)

<div class="topic-metadata">

**Author:** [@Aravindh](https://discourse.processing.org/u/Aravindh)\
**Replies:** 2\
**Last updated:** [June 7, 2018, 11:14pm UTC](https://discourse.processing.org/t/multiple-parallel-animations/780 "2018-06-07T23:14:00Z")

</div>

Hello, I wanted to ask if it is possible to have multiple parallel animations at the same time in processing. Something likehttps://youtu.be/spUNpyF58BY?t=271. Basically I want two sections displayed at the same time, ea…

---

## [For Loop with Text Array](https://discourse.processing.org/t/for-loop-with-text-array/787)

<div class="topic-metadata">

**Author:** [@deanomite](https://discourse.processing.org/u/deanomite)\
**Replies:** 3\
**Last updated:** [June 7, 2018, 10:28pm UTC](https://discourse.processing.org/t/for-loop-with-text-array/787 "2018-06-07T22:28:15Z")

</div>

Hi there, Am having some trouble figuring this exercise out. It’s a basic grid of text but I want the letters spread out across the rows and columns. Right now all text from the array appears one on top of each other a…

---

## [Keyboard buttons](https://discourse.processing.org/t/keyboard-buttons/717)

<div class="topic-metadata">

**Author:** [@nethaniel](https://discourse.processing.org/u/nethaniel)\
**Replies:** 4\
**Last updated:** [June 7, 2018, 7:34pm UTC](https://discourse.processing.org/t/keyboard-buttons/717 "2018-06-07T19:34:43Z")

</div>

i am trying to make a program that has a two shapes that move around with keyboard buttons i am somewhat new to coding and do not know how to make the keyboard recognize two different keys at the same time this is what i…

---

## [Can't Find NullPointerException](https://discourse.processing.org/t/cant-find-nullpointerexception/778)

<div class="topic-metadata">

**Author:** [@PeachAlmond9077](https://discourse.processing.org/u/PeachAlmond9077)\
**Replies:** 3\
**Last updated:** [June 7, 2018, 7:17pm UTC](https://discourse.processing.org/t/cant-find-nullpointerexception/778 "2018-06-07T19:17:47Z")

</div>

I am trying to code a Snake Game in which the snake eats square orbs When I was running the program a couple of days ago, the program throws a NullPointerException, which is saying that Line 14 in my Snake class is caus…

---

## [Collision and Boundaries help(Mario)?](https://discourse.processing.org/t/collision-and-boundaries-help-mario/716)

<div class="topic-metadata">

**Author:** [@tokyo](https://discourse.processing.org/u/tokyo)\
**Replies:** 14\
**Last updated:** [June 7, 2018, 5:10pm UTC](https://discourse.processing.org/t/collision-and-boundaries-help-mario/716 "2018-06-07T17:10:30Z")

</div>

Hi, I was working on a game and I had a couple questions. First, can you make a boundary by color? For example, I have a Mario and some pipes for him to jump over. The pipes are green so is there any code that prevents M…

[Previous page](https://discourse.processing.org/latest.md?no_subcategories=false&page=615)

[Next page](https://discourse.processing.org/latest.md?no_subcategories=false&page=617)
