# Latest

**URL:** https://discourse.processing.org/latest.md?page=411

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

**Page:** 412

---

## [Use p5 on existing canvas](https://discourse.processing.org/t/use-p5-on-existing-canvas/16307)

<div class="topic-metadata">

**Author:** [@tanzor](https://discourse.processing.org/u/tanzor)\
**Replies:** 4\
**Last updated:** [December 17, 2019, 8:49pm UTC](https://discourse.processing.org/t/use-p5-on-existing-canvas/16307 "2019-12-17T20:49:31Z")

</div>

Hey community! Is there a way to sketch with p5 within an existing javascript canvas? (i.e., one that was not opened using p5)? Thanks, Tan

---

## [Interactividad y escenas](https://discourse.processing.org/t/interactividad-y-escenas/16355)

<div class="topic-metadata">

**Author:** [@humano](https://discourse.processing.org/u/humano)\
**Replies:** 3\
**Last updated:** [December 16, 2019, 8:29pm UTC](https://discourse.processing.org/t/interactividad-y-escenas/16355 "2019-12-16T20:29:43Z")

</div>

Hi everybody, I’m on the last step to finish my sketch, but losing my head with somoething I don’t get. Sketch has scene1, that lasts 5 seconds. Then, scene 2 has a button that activates animation called scene 3. Final…

---

## [Reading the hue of a color variable gives strange results](https://discourse.processing.org/t/reading-the-hue-of-a-color-variable-gives-strange-results/5509)

<div class="topic-metadata">

**Author:** [@M4th31st](https://discourse.processing.org/u/M4th31st)\
**Replies:** 13\
**Last updated:** [December 17, 2019, 5:38pm UTC](https://discourse.processing.org/t/reading-the-hue-of-a-color-variable-gives-strange-results/5509 "2019-12-17T17:38:56Z")

</div>

I found out that when you set a hue value to a color object, you don’t get the same result back when you use the hue() function on that color. For example: the following code outputs the value 67.166664 instead of 67 co…

---

## [Query regarding Processing Foundation Fellowship Application](https://discourse.processing.org/t/query-regarding-processing-foundation-fellowship-application/16393)

<div class="topic-metadata">

**Author:** [@alishapapun](https://discourse.processing.org/u/alishapapun)\
**Replies:** 1\
**Last updated:** [December 17, 2019, 3:22pm UTC](https://discourse.processing.org/t/query-regarding-processing-foundation-fellowship-application/16393 "2019-12-17T15:22:43Z")

</div>

Hello, I am Alisha Mohanty and my teammate is Anisha Priyadarshini Mohanty. We are from Odisha, India. We got to know about the Processing Foundation Community from previous fellowship candidates 2019. We are applying f…

---

## [RuntimeException: Could not load movie file Move1.mov](https://discourse.processing.org/t/runtimeexception-could-not-load-movie-file-move1-mov/16473)

<div class="topic-metadata">

**Author:** [@Louis](https://discourse.processing.org/u/Louis)\
**Replies:** 1\
**Last updated:** [December 17, 2019, 2:51pm UTC](https://discourse.processing.org/t/runtimeexception-could-not-load-movie-file-move1-mov/16473 "2019-12-17T14:51:37Z")

</div>

Having some trouble getting the Frame Differencing filter to read a .mov file Any ideas where I am going wrong? import processing.video.\*; int numPixels; int\[\] previousFrame; Movie video; void setup() { size(1920…

---

## [Problem with using Firebase in online P5 Editor](https://discourse.processing.org/t/problem-with-using-firebase-in-online-p5-editor/11642)

<div class="topic-metadata">

**Author:** [@rsklarew](https://discourse.processing.org/u/rsklarew)\
**Replies:** 3\
**Last updated:** [December 17, 2019, 11:44am UTC](https://discourse.processing.org/t/problem-with-using-firebase-in-online-p5-editor/11642 "2019-12-17T11:44:52Z")

</div>

Firebase realtime database works fine in the old offline P5 editor. But when I use the same code in the new online editor, the variable firebase is not recognized: \*"Uncaught ReferenceError: firebase is not defi…

---

## [How to make the snake not move constantly](https://discourse.processing.org/t/how-to-make-the-snake-not-move-constantly/16453)

<div class="topic-metadata">

**Author:** [@crazybob5](https://discourse.processing.org/u/crazybob5)\
**Replies:** 2\
**Last updated:** [December 17, 2019, 8:23am UTC](https://discourse.processing.org/t/how-to-make-the-snake-not-move-constantly/16453 "2019-12-17T08:23:47Z")

</div>

Hi, How to make the snake not move constantly? int angle=0; int snakesize=10; int time=0; int\[\] headx= new int\[2500\]; int\[\] heady= new int\[2500\]; int applex=(round(random(47))+1)\*8; int appley=(round(random(47))+1)\*8; b…

---

## [Having trouble with if/else statement](https://discourse.processing.org/t/having-trouble-with-if-else-statement/16460)

<div class="topic-metadata">

**Author:** [@lilturkey7](https://discourse.processing.org/u/lilturkey7)\
**Replies:** 5\
**Last updated:** [December 17, 2019, 6:28am UTC](https://discourse.processing.org/t/having-trouble-with-if-else-statement/16460 "2019-12-17T06:28:24Z")

</div>

Hi, I’m new to Processing. I’m using the program as an introduction to coding in my high school class. I’m currently making a face but I’m having trouble with switching the display of two shapes. PShape face1, head, ey…

---

## [Framerate going down unexpectedly](https://discourse.processing.org/t/framerate-going-down-unexpectedly/16400)

<div class="topic-metadata">

**Author:** [@pieter123](https://discourse.processing.org/u/pieter123)\
**Replies:** 3\
**Last updated:** [December 17, 2019, 6:13am UTC](https://discourse.processing.org/t/framerate-going-down-unexpectedly/16400 "2019-12-17T06:13:53Z")

</div>

I’m working with particles in a flowfield, based on Shiffman’s tutorial in which a lot of lines, circles and text are drawn to the screen on every draw. Normally this runs very smooth with an fps of 60 or more. However, …

---

## [Error with package export](https://discourse.processing.org/t/error-with-package-export/16452)

<div class="topic-metadata">

**Author:** [@humano](https://discourse.processing.org/u/humano)\
**Replies:** 4\
**Last updated:** [December 17, 2019, 2:36am UTC](https://discourse.processing.org/t/error-with-package-export/16452 "2019-12-17T02:36:05Z")

</div>

Hi! I’m trying to export a Signed Package of my Sketch, in order to publish in Google Play Store, but I get error and the process fails. I have done all the things that can be done, the icons, etc. I writed the password…

---

## [Class Constructor Block not working](https://discourse.processing.org/t/class-constructor-block-not-working/16282)

<div class="topic-metadata">

**Author:** [@hamp](https://discourse.processing.org/u/hamp)\
**Replies:** 12\
**Last updated:** [December 16, 2019, 11:55pm UTC](https://discourse.processing.org/t/class-constructor-block-not-working/16282 "2019-12-16T23:55:34Z")

</div>

So I’m just starting out on processing and I run into this error: Unexpected token: { Here is my code: Person joe; void setup(){ size(500,500); background(0); Person joe = new Person(); } void draw(){ joe.di…

---

## [Arduino to Processing](https://discourse.processing.org/t/arduino-to-processing/16451)

<div class="topic-metadata">

**Author:** [@Cbeni](https://discourse.processing.org/u/Cbeni)\
**Replies:** 1\
**Last updated:** [December 16, 2019, 10:51pm UTC](https://discourse.processing.org/t/arduino-to-processing/16451 "2019-12-16T22:51:01Z")

</div>

Hello! I am trying to send info from arduino to processing but my code is not working, it worked before! =\[ Does the board need to be plugged in to work? Can someone please explain whats wrong? Processing Code impor…

---

## ['img cannot be resolved to a variable'](https://discourse.processing.org/t/img-cannot-be-resolved-to-a-variable/16431)

<div class="topic-metadata">

**Author:** [@Louis](https://discourse.processing.org/u/Louis)\
**Replies:** 7\
**Last updated:** [December 16, 2019, 10:17pm UTC](https://discourse.processing.org/t/img-cannot-be-resolved-to-a-variable/16431 "2019-12-16T22:17:06Z")

</div>

I’m trying to create a script that will print image frames by interval, current code: int xpos = 0; int ypos = 0; int VWIDTH = 8; // width of capture int VHEIGHT = 6; // height of capture int MOVIEWIDTH = VWIDTH \* 60; …

---

## [Paint application](https://discourse.processing.org/t/paint-application/16356)

<div class="topic-metadata">

**Author:** [@Swagific](https://discourse.processing.org/u/Swagific)\
**Replies:** 14\
**Last updated:** [December 16, 2019, 8:37pm UTC](https://discourse.processing.org/t/paint-application/16356 "2019-12-16T20:37:07Z")

</div>

Im trying to make a paint application. when i click on the shape icons the shape of the brush dosent change. when i click on the save icons they dont work either. im not sure what im missing in my code to get them to wor…

---

## [Recreating that Joy Division album cover](https://discourse.processing.org/t/recreating-that-joy-division-album-cover/16444)

<div class="topic-metadata">

**Author:** [@dalphabet](https://discourse.processing.org/u/dalphabet)\
**Replies:** 8\
**Last updated:** [December 16, 2019, 7:16pm UTC](https://discourse.processing.org/t/recreating-that-joy-division-album-cover/16444 "2019-12-16T19:16:24Z")

</div>

I found an Openprocessing code of an album cover of Joy Division’s ‘Unknown Pleasures’. The code was originally written by Craig S. Kaplan. So overwhelmed by the beauty of it, I attempted to translate this to pde. Howeve…

---

## [Processing Sketch Ideas?](https://discourse.processing.org/t/processing-sketch-ideas/874)

<div class="topic-metadata">

**Author:** [@Trilobyte](https://discourse.processing.org/u/Trilobyte)\
**Replies:** 5\
**Last updated:** [December 16, 2019, 7:08pm UTC](https://discourse.processing.org/t/processing-sketch-ideas/874 "2019-12-16T19:08:50Z")

</div>

Hello! My name is Trilobyte, and right now, I am at a loss for ideas. I’ve got some projects kicking around, but a lot of the time, I like starting some long projects that I can come back to every now and then. I also h…

---

## [Problem with "splitscreen" in one window](https://discourse.processing.org/t/problem-with-splitscreen-in-one-window/16418)

<div class="topic-metadata">

**Author:** [@Zerichy](https://discourse.processing.org/u/Zerichy)\
**Replies:** 4\
**Last updated:** [December 16, 2019, 2:09pm UTC](https://discourse.processing.org/t/problem-with-splitscreen-in-one-window/16418 "2019-12-16T14:09:38Z")

</div>

Hello, i wanted to do the mandelbrot/julia set challenge from codingtrain that these two fractals are in one window and you can hover over the mandelbrot set and see the corresponding julia set next to it change (like he…

---

## [Giving wrong value while reading data from serial port](https://discourse.processing.org/t/giving-wrong-value-while-reading-data-from-serial-port/16447)

<div class="topic-metadata">

**Author:** [@iamgsshetty](https://discourse.processing.org/u/iamgsshetty)\
**Replies:** 3\
**Last updated:** [December 16, 2019, 1:14pm UTC](https://discourse.processing.org/t/giving-wrong-value-while-reading-data-from-serial-port/16447 "2019-12-16T13:14:48Z")

</div>

processing code:- import processing.serial.\*; Serial myport; float v1,v2,a,cda=0.0,how=0.0,water=0.0; void setup() { myport = new Serial(this, Serial.list()\[0\], 9600); } void draw() { if(0\<myport.available()) …

---

## [Making the game Crossy Road](https://discourse.processing.org/t/making-the-game-crossy-road/16438)

<div class="topic-metadata">

**Author:** [@TigerClaw](https://discourse.processing.org/u/TigerClaw)\
**Replies:** 4\
**Last updated:** [December 16, 2019, 12:55pm UTC](https://discourse.processing.org/t/making-the-game-crossy-road/16438 "2019-12-16T12:55:32Z")

</div>

Hi my name is Kai and i have a final assignment in my computer science class and i need help making the game crossy road. I have a 57 in the class right now and I need to get a 60 to pass can some please help me. Require…

---

## [Complex variables](https://discourse.processing.org/t/complex-variables/16349)

<div class="topic-metadata">

**Author:** [@humano](https://discourse.processing.org/u/humano)\
**Replies:** 11\
**Last updated:** [December 16, 2019, 11:46am UTC](https://discourse.processing.org/t/complex-variables/16349 "2019-12-16T11:46:05Z")

</div>

Hi guys, I’m trying to put all this code in a variable, but I don’t know how to do it. I mean, I only know how to do simple variables, but not variables that have many lines. Can you help my? I need to create a variabl…

---

## [New to processing (centipede) stuck on tail](https://discourse.processing.org/t/new-to-processing-centipede-stuck-on-tail/16324)

<div class="topic-metadata">

**Author:** [@crazybob5](https://discourse.processing.org/u/crazybob5)\
**Replies:** 7\
**Last updated:** [December 16, 2019, 10:09am UTC](https://discourse.processing.org/t/new-to-processing-centipede-stuck-on-tail/16324 "2019-12-16T10:09:48Z")

</div>

Im fairly new to processing and im working on doing a basic game but im stuck on adding a tail to the centipede. float x = 0; float y = 0; float spacing = 50; float positiex = 200; float positiey = 200; void setup() …

---

## [Trying to understand the "Substrate" algorithm](https://discourse.processing.org/t/trying-to-understand-the-substrate-algorithm/3031)

<div class="topic-metadata">

**Author:** [@solub](https://discourse.processing.org/u/solub)\
**Replies:** 16\
**Last updated:** [December 16, 2019, 9:41am UTC](https://discourse.processing.org/t/trying-to-understand-the-substrate-algorithm/3031 "2019-12-16T09:41:34Z")

</div>

Dear all, I would really appreciate if someone could help me decipher some parts of Jared Tarbell’s “substrate” algorithm. For those who are not familiar with this famous sketch, here is a recap in Tarbell’s own words: …

---

## [Getting nothing when trying to show image with the help of HTML tag](https://discourse.processing.org/t/getting-nothing-when-trying-to-show-image-with-the-help-of-html-tag/16378)

<div class="topic-metadata">

**Author:** [@RadheTians](https://discourse.processing.org/u/RadheTians)\
**Replies:** 6\
**Last updated:** [December 16, 2019, 6:47am UTC](https://discourse.processing.org/t/getting-nothing-when-trying-to-show-image-with-the-help-of-html-tag/16378 "2019-12-16T06:47:37Z")

</div>

I noticed that when I was trying to show an image on canvas with the help of HTML tags(i.e input tag and type is file) the codebase wasn’t showing an image and when I was trying to show with the help of p5.js function c…

---

## [Processing on Rosetta Code -- weekly topics?](https://discourse.processing.org/t/processing-on-rosetta-code-weekly-topics/5980)

<div class="topic-metadata">

**Author:** [@jeremydouglass](https://discourse.processing.org/u/jeremydouglass)\
**Replies:** 11\
**Last updated:** [December 16, 2019, 6:11am UTC](https://discourse.processing.org/t/processing-on-rosetta-code-weekly-topics/5980 "2019-12-16T06:11:54Z")

</div>

I recently noticed that Rosetta Code – the tasks-in-many-languages coding site – has a language for Processing, but only ~26 Processing tasks examples submitted, out of 916 tasks. https://rosettacode.org/wiki/Category:…

---

## [Change x position of an array of lines](https://discourse.processing.org/t/change-x-position-of-an-array-of-lines/16427)

<div class="topic-metadata">

**Author:** [@Tilia](https://discourse.processing.org/u/Tilia)\
**Replies:** 1\
**Last updated:** [December 16, 2019, 3:18am UTC](https://discourse.processing.org/t/change-x-position-of-an-array-of-lines/16427 "2019-12-16T03:18:51Z")

</div>

hi Leute could someone explain me why i cannot change the x position of an array of lines by pressing the arrow keyes? the lines (looking like a sun) have all the same x position (0,0) translated to the middle of the c…

---

## [Making a shadowcaster](https://discourse.processing.org/t/making-a-shadowcaster/16432)

<div class="topic-metadata">

**Author:** [@Wattscanaan10](https://discourse.processing.org/u/Wattscanaan10)\
**Replies:** 1\
**Last updated:** [December 16, 2019, 2:16am UTC](https://discourse.processing.org/t/making-a-shadowcaster/16432 "2019-12-16T02:16:55Z")

</div>

So im trying to write a 2d raycaster for the first time, and im having trouble only drawing lines to the closest walls. i cant find what to do next Code: Source source; Ray ray; Wall\[\] walls = new Wall\[2\]; void setup(…

---

## [Making a spiral shooting enemy](https://discourse.processing.org/t/making-a-spiral-shooting-enemy/16411)

<div class="topic-metadata">

**Author:** [@davidclue](https://discourse.processing.org/u/davidclue)\
**Replies:** 9\
**Last updated:** [December 16, 2019, 1:45am UTC](https://discourse.processing.org/t/making-a-spiral-shooting-enemy/16411 "2019-12-16T01:45:34Z")

</div>

Hi I was wondering on how to make an enemy shoot in a spiral way around the screen. BasicEnemy(float tempX, float tempY, int tempXdir, int tempYdir, int tempSize, float tempSpeed, float tempDamage) Thats the constructo…

---

## [Editor starts, programs (sketches) won't run](https://discourse.processing.org/t/editor-starts-programs-sketches-wont-run/16237)

<div class="topic-metadata">

**Author:** [@OldNick](https://discourse.processing.org/u/OldNick)\
**Replies:** 11\
**Last updated:** [December 16, 2019, 1:00am UTC](https://discourse.processing.org/t/editor-starts-programs-sketches-wont-run/16237 "2019-12-16T01:00:57Z")

</div>

Hello all, I’m new to this forum. Processing 3.3.7 & 3.5.3 on Windows 10 home x64. I had used Processing quite some time ago, and everything worked fine, but now → see title. The editor works, I can load, save and edi…

---

## [Help with Processing projects (Post 2 of 2)](https://discourse.processing.org/t/help-with-processing-projects-post-2-of-2/16436)

<div class="topic-metadata">

**Author:** [@ImConfused](https://discourse.processing.org/u/ImConfused)\
**Replies:** 2\
**Last updated:** [December 15, 2019, 11:41pm UTC](https://discourse.processing.org/t/help-with-processing-projects-post-2-of-2/16436 "2019-12-15T23:41:51Z")

</div>

I have no idea how to set it up

---

## [OutOfMemoryError when loading images at startup of sketch](https://discourse.processing.org/t/outofmemoryerror-when-loading-images-at-startup-of-sketch/16429)

<div class="topic-metadata">

**Author:** [@Tim076](https://discourse.processing.org/u/Tim076)\
**Replies:** 2\
**Last updated:** [December 15, 2019, 11:01pm UTC](https://discourse.processing.org/t/outofmemoryerror-when-loading-images-at-startup-of-sketch/16429 "2019-12-15T23:01:39Z")

</div>

Hi all, My sketch throws an OutOfMemoryError when I try to run it. However I only try to load in a total of 9 images with a combined size of 5 MB. I also only call loadImage in setup so I’m not constantly loading images…

[Previous page](https://discourse.processing.org/latest.md?page=410)

[Next page](https://discourse.processing.org/latest.md?page=412)
