# Latest

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

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

**Page:** 347

---

## [Gallery for Processing.py sketches?](https://discourse.processing.org/t/gallery-for-processing-py-sketches/21150)

<div class="topic-metadata">

**Author:** [@PawnMongo](https://discourse.processing.org/u/PawnMongo)\
**Replies:** 2\
**Last updated:** [May 22, 2020, 4:01am UTC](https://discourse.processing.org/t/gallery-for-processing-py-sketches/21150 "2020-05-22T04:01:57Z")

</div>

I enjoy browsing the great sketches that are posted at openprocessing.org/browse. I’ll often look at the code for their sketches to figure out how they achieved their results. My native tongue is python, however, so fi…

---

## [Creating a class with multiple constructors and static variables in JavaScript](https://discourse.processing.org/t/creating-a-class-with-multiple-constructors-and-static-variables-in-javascript/21156)

<div class="topic-metadata">

**Author:** [@AndJ](https://discourse.processing.org/u/AndJ)\
**Replies:** 1\
**Last updated:** [May 22, 2020, 2:40am UTC](https://discourse.processing.org/t/creating-a-class-with-multiple-constructors-and-static-variables-in-javascript/21156 "2020-05-22T02:40:14Z")

</div>

I am familiar with Processing/Java but am trying to learn more p5.js/JavaScript. I am creating a class that, in Java, has multiple constructors with the same number of arguments with different data types. Example: clas…

---

## [3D Coding on the Z-axis](https://discourse.processing.org/t/3d-coding-on-the-z-axis/20359)

<div class="topic-metadata">

**Author:** [@PhilRandom](https://discourse.processing.org/u/PhilRandom)\
**Replies:** 7\
**Last updated:** [May 21, 2020, 9:45pm UTC](https://discourse.processing.org/t/3d-coding-on-the-z-axis/20359 "2020-05-21T21:45:06Z")

</div>

Hi all! Phil here again, as you know this has been a very stressful year, so I thought coding would be a fantastic way to get back my mojo in self-isolation! For those of you who are unaware, I began to learn coding las…

---

## [Morph from one position to another - animation](https://discourse.processing.org/t/morph-from-one-position-to-another-animation/21112)

<div class="topic-metadata">

**Author:** [@rkk16](https://discourse.processing.org/u/rkk16)\
**Replies:** 8\
**Last updated:** [May 21, 2020, 8:31pm UTC](https://discourse.processing.org/t/morph-from-one-position-to-another-animation/21112 "2020-05-21T20:31:51Z")

</div>

I’m aware of how to make certain features move using integers and increments but is there a tool to animate/morph from one position to the other ie if I draw an object at 30 degrees at position 200,300 - then the same ob…

---

## [Can you help me with optimizing code](https://discourse.processing.org/t/can-you-help-me-with-optimizing-code/21141)

<div class="topic-metadata">

**Author:** [@Arsenii](https://discourse.processing.org/u/Arsenii)\
**Replies:** 4\
**Last updated:** [May 21, 2020, 8:24pm UTC](https://discourse.processing.org/t/can-you-help-me-with-optimizing-code/21141 "2020-05-21T20:24:49Z")

</div>

I have a problem with understanding who to optimize my code. Main idea of program of creating a words with dots. ArrayList\<PVector\> edgeVertices = new ArrayList\<PVector\>(); ArrayList\<PVector\> Adding = new ArrayList\<PVe…

---

## [Storing input for 3d shapes](https://discourse.processing.org/t/storing-input-for-3d-shapes/21024)

<div class="topic-metadata">

**Author:** [@mrbro](https://discourse.processing.org/u/mrbro)\
**Replies:** 3\
**Last updated:** [May 21, 2020, 8:24pm UTC](https://discourse.processing.org/t/storing-input-for-3d-shapes/21024 "2020-05-21T20:24:42Z")

</div>

Hi everyone! I am new to processing. I am trying to draw a shape and store 5 shapes before the current one, so the fade consequently (like in this example: https://processing.org/examples/storinginput.html). (or maybe I…

---

## [Filling complex shape - followup](https://discourse.processing.org/t/filling-complex-shape-followup/21140)

<div class="topic-metadata">

**Author:** [@rkk16](https://discourse.processing.org/u/rkk16)\
**Replies:** 3\
**Last updated:** [May 21, 2020, 7:56pm UTC](https://discourse.processing.org/t/filling-complex-shape-followup/21140 "2020-05-21T19:56:27Z")

</div>

Please find my code below. Trying to create a lip but it cuts halfway for some reason, can someone please explain why? int x = 100; fill(255,0,0); beginShape(); curveVertex(-20+x,80); curveVertex(30+x,90); curveVer…

---

## [Filling complex shapes](https://discourse.processing.org/t/filling-complex-shapes/21139)

<div class="topic-metadata">

**Author:** [@rkk16](https://discourse.processing.org/u/rkk16)\
**Replies:** 3\
**Last updated:** [May 21, 2020, 5:02pm UTC](https://discourse.processing.org/t/filling-complex-shapes/21139 "2020-05-21T17:02:14Z")

</div>

How do we fill in a complex circular shape like a lip? ie I know how to draw the Bezier/curve lines but how do we fill in 2 Bezier curves that join at 2 vertices?

---

## [Play video in background](https://discourse.processing.org/t/play-video-in-background/21092)

<div class="topic-metadata">

**Author:** [@Mesalcode](https://discourse.processing.org/u/Mesalcode)\
**Replies:** 2\
**Last updated:** [May 21, 2020, 4:58pm UTC](https://discourse.processing.org/t/play-video-in-background/21092 "2020-05-21T16:58:57Z")

</div>

Hi! I am building an android game using processing and need to play videos in the background. Looking at two very long threads on the new and old forum, I found this code that is able to display video, but it is in the…

---

## [Question about processing steady video to summarize pixel data](https://discourse.processing.org/t/question-about-processing-steady-video-to-summarize-pixel-data/21063)

<div class="topic-metadata">

**Author:** [@lucgallant](https://discourse.processing.org/u/lucgallant)\
**Replies:** 7\
**Last updated:** [May 21, 2020, 12:48pm UTC](https://discourse.processing.org/t/question-about-processing-steady-video-to-summarize-pixel-data/21063 "2020-05-21T12:48:18Z")

</div>

Hi all, I’ve got a question about processing video in Windows. I’ve got an application that is connected to my motorcycle and shows real-time the throttle position and engine speed. This picture below is a typical view…

---

## [Interpolation - lerp multiple cases](https://discourse.processing.org/t/interpolation-lerp-multiple-cases/21126)

<div class="topic-metadata">

**Author:** [@rkk16](https://discourse.processing.org/u/rkk16)\
**Replies:** 0\
**Last updated:** [May 21, 2020, 10:36am UTC](https://discourse.processing.org/t/interpolation-lerp-multiple-cases/21126 "2020-05-21T10:36:07Z")

</div>

Hey guys, I’m using lerp to interpolate between facial expressions (ie happy to sad would be lerp between an arc (for the lips) with a certain length, width and fill radian to another). I also managed to connect a slider…

---

## [Need help with dist()](https://discourse.processing.org/t/need-help-with-dist/21020)

<div class="topic-metadata">

**Author:** [@SeveriuS96](https://discourse.processing.org/u/SeveriuS96)\
**Replies:** 4\
**Last updated:** [May 21, 2020, 10:04am UTC](https://discourse.processing.org/t/need-help-with-dist/21020 "2020-05-21T10:04:35Z")

</div>

Hello Processing user, in my program I want that the moveable character be stopped by a wall(a rect) if it collide with it. int speed = 5; int xPosChell = width/2; //Chell(movable Character) int yPosChell = heigh…

---

## [Processing + Eclipse + glsl glass effect](https://discourse.processing.org/t/processing-eclipse-glsl-glass-effect/21021)

<div class="topic-metadata">

**Author:** [@subsubsub](https://discourse.processing.org/u/subsubsub)\
**Replies:** 0\
**Last updated:** [May 18, 2020, 3:34pm UTC](https://discourse.processing.org/t/processing-eclipse-glsl-glass-effect/21021 "2020-05-18T15:34:25Z")

</div>

Hi everyone, I’m currently using succesfully java in eclipse, and using glsl shaders. I’m trying to replicate a glass effect, and this post seems interesting. I just don’t understand if (and how) I have to pass a pict…

---

## [Please plese please help me with my problem, appearing in a simple p5.js code](https://discourse.processing.org/t/please-plese-please-help-me-with-my-problem-appearing-in-a-simple-p5-js-code/21123)

<div class="topic-metadata">

**Author:** [@Nis](https://discourse.processing.org/u/Nis)\
**Replies:** 2\
**Last updated:** [May 21, 2020, 7:59am UTC](https://discourse.processing.org/t/please-plese-please-help-me-with-my-problem-appearing-in-a-simple-p5-js-code/21123 "2020-05-21T07:59:06Z")

</div>

https://editor.p5js.org/Nis\_Collect/sketches/U0p3GjOK1 The above provided link is of my project in which I want to make only one rectangle appear after particular frame-counts.But there appears a problem while doing thi…

---

## [Why transformations and shapes can't be used within beginShape()](https://discourse.processing.org/t/why-transformations-and-shapes-cant-be-used-within-beginshape/20997)

<div class="topic-metadata">

**Author:** [@alikaikai](https://discourse.processing.org/u/alikaikai)\
**Replies:** 4\
**Last updated:** [May 21, 2020, 5:49am UTC](https://discourse.processing.org/t/why-transformations-and-shapes-cant-be-used-within-beginshape/20997 "2020-05-21T05:49:07Z")

</div>

Hello everyone! I recently started using Processing and I learned from the reference page that transformations such as translate() rotate() as well as other shapes do not work within beginShape(). So why is that happen…

---

## [Generate random colors from math3 distributions](https://discourse.processing.org/t/generate-random-colors-from-math3-distributions/21027)

<div class="topic-metadata">

**Author:** [@dfamil](https://discourse.processing.org/u/dfamil)\
**Replies:** 3\
**Last updated:** [May 21, 2020, 3:50am UTC](https://discourse.processing.org/t/generate-random-colors-from-math3-distributions/21027 "2020-05-21T03:50:11Z")

</div>

If I use the random function everything works fine. if I try to map a generate a random distribution it only records the last number of the array. but the println is correct. vMin = min(valueYArray); vMax = max(valueY…

---

## [Dropbox API to link files shared between 2 files](https://discourse.processing.org/t/dropbox-api-to-link-files-shared-between-2-files/20994)

<div class="topic-metadata">

**Author:** [@Student2020](https://discourse.processing.org/u/Student2020)\
**Replies:** 2\
**Last updated:** [May 21, 2020, 12:48am UTC](https://discourse.processing.org/t/dropbox-api-to-link-files-shared-between-2-files/20994 "2020-05-21T00:48:16Z")

</div>

Hello, I am trying to access a folder in dropbox for a data file (.csv) and also a folder where an image generated in the code will be saved. I then have a second code which needs to read this csv file and load the cre…

---

## [Large image loading and display consider slow](https://discourse.processing.org/t/large-image-loading-and-display-consider-slow/21016)

<div class="topic-metadata">

**Author:** [@IvanOi](https://discourse.processing.org/u/IvanOi)\
**Replies:** 2\
**Last updated:** [May 20, 2020, 11:57pm UTC](https://discourse.processing.org/t/large-image-loading-and-display-consider-slow/21016 "2020-05-20T23:57:38Z")

</div>

Hi, Currently, I’m using VLCJ for image loading and display process. I found out Processing way slow in this area. Hopefully, Processing can take a lot into VLC how they load the image and display. I would say quite f…

---

## [Using camera in processing for moving in specific area](https://discourse.processing.org/t/using-camera-in-processing-for-moving-in-specific-area/21080)

<div class="topic-metadata">

**Author:** [@alkyonemis](https://discourse.processing.org/u/alkyonemis)\
**Replies:** 5\
**Last updated:** [May 20, 2020, 11:26pm UTC](https://discourse.processing.org/t/using-camera-in-processing-for-moving-in-specific-area/21080 "2020-05-20T23:26:14Z")

</div>

Hi I’m a new coder on processing. I have long and complex code but I prepared a simple code to you for my question. float camX = 0; float camY = 0; float camZ = (height/2)/tan(PI/6) - 260; float x, y, z = 0; float rot…

---

## [Adding an image to shape?](https://discourse.processing.org/t/adding-an-image-to-shape/21105)

<div class="topic-metadata">

**Author:** [@rkk16](https://discourse.processing.org/u/rkk16)\
**Replies:** 2\
**Last updated:** [May 20, 2020, 9:54pm UTC](https://discourse.processing.org/t/adding-an-image-to-shape/21105 "2020-05-20T21:54:02Z")

</div>

How do you add a background for a shape? ie instead of filling a circle with a colour, fill it with an image?

---

## [Why does this Javascript sketch lag compared to the Java sketch?](https://discourse.processing.org/t/why-does-this-javascript-sketch-lag-compared-to-the-java-sketch/21019)

<div class="topic-metadata">

**Author:** [@the0ne](https://discourse.processing.org/u/the0ne)\
**Replies:** 3\
**Last updated:** [May 20, 2020, 9:15pm UTC](https://discourse.processing.org/t/why-does-this-javascript-sketch-lag-compared-to-the-java-sketch/21019 "2020-05-20T21:15:08Z")

</div>

So, I ported a Java Processing sketch to p5.js. The sketches should be simple to run - just basic image rasterization. I tried my best to optimize the JS code but have been unsuccessful at getting any decent performance …

---

## [Morph from one position to the other?](https://discourse.processing.org/t/morph-from-one-position-to-the-other/21111)

<div class="topic-metadata">

**Author:** [@rkk16](https://discourse.processing.org/u/rkk16)\
**Replies:** 1\
**Last updated:** [May 20, 2020, 8:22pm UTC](https://discourse.processing.org/t/morph-from-one-position-to-the-other/21111 "2020-05-20T20:22:14Z")

</div>

I want to create an animation of a face going from happy to sad when a button is pressed - at the moment, this happens instantaneously. I’m aware of how to make certain features move using integers and increments but is …

---

## [Jungle Adventure Game in P5js & FroobitJS](https://discourse.processing.org/t/jungle-adventure-game-in-p5js-froobitjs/21052)

<div class="topic-metadata">

**Author:** [@r4nd0m](https://discourse.processing.org/u/r4nd0m)\
**Replies:** 2\
**Last updated:** [May 20, 2020, 6:34pm UTC](https://discourse.processing.org/t/jungle-adventure-game-in-p5js-froobitjs/21052 "2020-05-20T18:34:27Z")

</div>

Hi all, Wanted to drop here a game I’m currently working on. It’s written in Javascript, I’m using p5js for rendering & sound, and FroobitJS for gamedev stuff like camera, sprite animations, events, layers etc… You …

---

## [Diffusion Limited Aggregation](https://discourse.processing.org/t/diffusion-limited-aggregation/21006)

<div class="topic-metadata">

**Author:** [@MonkeyDLuffy](https://discourse.processing.org/u/MonkeyDLuffy)\
**Replies:** 8\
**Last updated:** [May 20, 2020, 6:18pm UTC](https://discourse.processing.org/t/diffusion-limited-aggregation/21006 "2020-05-20T18:18:10Z")

</div>

Hello, I am trying to visualize Diffusion Limited Aggregation and some of my circles are overlapping. I tried repositioning them but they still overlap. How can I fix this? My code is below: import java.lang.Math; Arra…

---

## [Realistic shapes - lips for a face](https://discourse.processing.org/t/realistic-shapes-lips-for-a-face/21101)

<div class="topic-metadata">

**Author:** [@rkk16](https://discourse.processing.org/u/rkk16)\
**Replies:** 3\
**Last updated:** [May 20, 2020, 6:08pm UTC](https://discourse.processing.org/t/realistic-shapes-lips-for-a-face/21101 "2020-05-20T18:08:15Z")

</div>

Hey guys, I’m new to processing and need help designing more complex shapes. I need curves on my arcs, not quite elipses - but just to create more realistic expressions on this facial expressions project of mine. Pressin…

---

## [How to rotate a sprite toward the direction of motion](https://discourse.processing.org/t/how-to-rotate-a-sprite-toward-the-direction-of-motion/21056)

<div class="topic-metadata">

**Author:** [@shinyogre](https://discourse.processing.org/u/shinyogre)\
**Replies:** 12\
**Last updated:** [May 20, 2020, 1:44pm UTC](https://discourse.processing.org/t/how-to-rotate-a-sprite-toward-the-direction-of-motion/21056 "2020-05-20T13:44:54Z")

</div>

I am trying to figure out how to align a sprite image to the angle of the hill that it “moves” along. I am using atan2 and the result is this (gif is multiplying the angle by 360 just to show the effect): Here is my …

---

## [Unexpected token color](https://discourse.processing.org/t/unexpected-token-color/21088)

<div class="topic-metadata">

**Author:** [@sept](https://discourse.processing.org/u/sept)\
**Replies:** 3\
**Last updated:** [May 20, 2020, 1:44pm UTC](https://discourse.processing.org/t/unexpected-token-color/21088 "2020-05-20T13:44:18Z")

</div>

First of all, sorry for my bad english. Hello i’m a French student, I’ve got a homework about a class to create balls. I’ve followed the teacher’s classes but I’m stuck with an unexpected token. You should understand my …

---

## [Posenet with p5js](https://discourse.processing.org/t/posenet-with-p5js/21009)

<div class="topic-metadata">

**Author:** [@babyP5](https://discourse.processing.org/u/babyP5)\
**Replies:** 5\
**Last updated:** [May 20, 2020, 12:29pm UTC](https://discourse.processing.org/t/posenet-with-p5js/21009 "2020-05-20T12:29:25Z")

</div>

hello everyone im working on a project with posenet and p5js and i want when my hand is above my shoulder i append a number inside of an array the porblem is its keep adding the number multiple times before stoping and …

---

## [How to reduce PoseNet inputResolution to make it perform faster](https://discourse.processing.org/t/how-to-reduce-posenet-inputresolution-to-make-it-perform-faster/21060)

<div class="topic-metadata">

**Author:** [@yuinjann](https://discourse.processing.org/u/yuinjann)\
**Replies:** 0\
**Last updated:** [May 19, 2020, 3:25pm UTC](https://discourse.processing.org/t/how-to-reduce-posenet-inputresolution-to-make-it-perform-faster/21060 "2020-05-19T15:25:02Z")

</div>

Hi! I’m using posenet and hence video capture, and not drawing the video image. My project uses node and want to track wrist positions of everyone who opens the browser. However, the size of my video is the size of my c…

---

## [Disable smooth/anti-alias for textures](https://discourse.processing.org/t/disable-smooth-anti-alias-for-textures/21078)

<div class="topic-metadata">

**Author:** [@d128](https://discourse.processing.org/u/d128)\
**Replies:** 0\
**Last updated:** [May 20, 2020, 4:53am UTC](https://discourse.processing.org/t/disable-smooth-anti-alias-for-textures/21078 "2020-05-20T04:53:37Z")

</div>

Hi, everyone. I’m using a 400x200 texture on a sphere and I want to disable the smooth/anti-alias only for the texture in order to get a sharp and pixelated look. Is this possible or there’s a workaround? If it’s disabl…

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

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