# Latest

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

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

**Page:** 337

---

## [Help color movement](https://discourse.processing.org/t/help-color-movement/21764)

<div class="topic-metadata">

**Author:** [@marika20](https://discourse.processing.org/u/marika20)\
**Replies:** 9\
**Last updated:** [June 12, 2020, 12:21pm UTC](https://discourse.processing.org/t/help-color-movement/21764 "2020-06-12T12:21:01Z")

</div>

Ciao a tutti! Ho bisogno di un suggerimento per il mio lavoro: devo far in modo che le mie linee insieme ai miei rect() si muovano nel seguente modo: il mio codice è il seguente: color red = #FF0004; color yellow = …

---

## [Linee e Background](https://discourse.processing.org/t/linee-e-background/21802)

<div class="topic-metadata">

**Author:** [@marika20](https://discourse.processing.org/u/marika20)\
**Replies:** 3\
**Last updated:** [June 12, 2020, 12:20pm UTC](https://discourse.processing.org/t/linee-e-background/21802 "2020-06-12T12:20:23Z")

</div>

Ciao a tutti, ho un problema con il movimento di una linea: non capisco perchè se io voglio una linea che si muova a dx e a sin nel mio sketch questa si muove creando dello spazio bianco? color red = #FF0004; color yell…

---

## [Shared PGraphics instances - drawing](https://discourse.processing.org/t/shared-pgraphics-instances-drawing/21801)

<div class="topic-metadata">

**Author:** [@mgood7123](https://discourse.processing.org/u/mgood7123)\
**Replies:** 2\
**Last updated:** [June 12, 2020, 10:56am UTC](https://discourse.processing.org/t/shared-pgraphics-instances-drawing/21801 "2020-06-12T10:56:12Z")

</div>

NOTE: https://discourse.processing.org/t/pgraphics-begindraw-pgraphics-enddraw-alternatives/21769 how would i go about drawing to a shared PGraphics instance in the context each window that obtains the PGraphics instanc…

---

## [beginDraw endDraw optimizing (trying to reduce the amount of beginDraw endDraw calls required) fails to render](https://discourse.processing.org/t/begindraw-enddraw-optimizing-trying-to-reduce-the-amount-of-begindraw-enddraw-calls-required-fails-to-render/21803)

<div class="topic-metadata">

**Author:** [@mgood7123](https://discourse.processing.org/u/mgood7123)\
**Replies:** 0\
**Last updated:** [June 12, 2020, 10:51am UTC](https://discourse.processing.org/t/begindraw-enddraw-optimizing-trying-to-reduce-the-amount-of-begindraw-enddraw-calls-required-fails-to-render/21803 "2020-06-12T10:51:38Z")

</div>

in the following code Compositor compositor; void settings() { //fullScreen(P3D); // 31 fps size(400, 400, P3D); // 60 fps } class Applications\_Cube extends Window { @Override void draw() { graphics.lig…

---

## [Audio Not Playing With if Statements (Minim)](https://discourse.processing.org/t/audio-not-playing-with-if-statements-minim/21794)

<div class="topic-metadata">

**Author:** [@chemicalite](https://discourse.processing.org/u/chemicalite)\
**Replies:** 3\
**Last updated:** [June 12, 2020, 6:25am UTC](https://discourse.processing.org/t/audio-not-playing-with-if-statements-minim/21794 "2020-06-12T06:25:02Z")

</div>

Hi all! I can’t seem to get sound files to play with this code here. I want different sound files to play when the user hits a certain key. I’m working on a project currently, here’s the code below! //Audio and Varia…

---

## [Can anybody help me to make this code have possibility to add multiple images?](https://discourse.processing.org/t/can-anybody-help-me-to-make-this-code-have-possibility-to-add-multiple-images/21770)

<div class="topic-metadata">

**Author:** [@Cassius](https://discourse.processing.org/u/Cassius)\
**Replies:** 10\
**Last updated:** [June 12, 2020, 10:33am UTC](https://discourse.processing.org/t/can-anybody-help-me-to-make-this-code-have-possibility-to-add-multiple-images/21770 "2020-06-12T10:33:54Z")

</div>

Hello everybody I am still new in processing so go easy on me,I have found this code and have been trying how to make so that I can add multiple images to this sketch and on mouswheel() it changes images.I would appreci…

---

## [Some problem in pushing blocks in p5.js sketch](https://discourse.processing.org/t/some-problem-in-pushing-blocks-in-p5-js-sketch/21780)

<div class="topic-metadata">

**Author:** [@Nisss](https://discourse.processing.org/u/Nisss)\
**Replies:** 3\
**Last updated:** [June 12, 2020, 10:32am UTC](https://discourse.processing.org/t/some-problem-in-pushing-blocks-in-p5-js-sketch/21780 "2020-06-12T10:32:12Z")

</div>

https://editor.p5js.org/Nis\_Collect/sketches/eeOTXD\_D2 :point\_up::point\_up::point\_up::point\_up::point\_up::point\_up::point\_up::point\_up::point\_up::point\_up::point\_up::point\_up::point\_up::point\_up::point\_up::point\_up::poi…

---

## [Bouncing ball with paddle](https://discourse.processing.org/t/bouncing-ball-with-paddle/21798)

<div class="topic-metadata">

**Author:** [@mrporcessing](https://discourse.processing.org/u/mrporcessing)\
**Replies:** 1\
**Last updated:** [June 12, 2020, 9:03am UTC](https://discourse.processing.org/t/bouncing-ball-with-paddle/21798 "2020-06-12T09:03:30Z")

</div>

Hi, I just need it so that the ball will bounce off the two paddles. I don’t know the proper code for it. Code: int x,y,w,h,speedX,speedY;//circle variables int paddleX, paddleY,paddlew,paddleH,paddleS,paddleX2,paddleY…

---

## [Porting GLSL from Shadertoy to Processing](https://discourse.processing.org/t/porting-glsl-from-shadertoy-to-processing/2762)

<div class="topic-metadata">

**Author:** [@sableraph](https://discourse.processing.org/u/sableraph)\
**Replies:** 9\
**Last updated:** [June 12, 2020, 8:33am UTC](https://discourse.processing.org/t/porting-glsl-from-shadertoy-to-processing/2762 "2020-06-12T08:33:00Z")

</div>

A few years ago, I wrote an example on how to port GLSL shader code from Shadertoy.com to Processing. Since then, Shadertoy has changed quite a lot (adding a lot of new uniforms and input methods) so an update was long o…

---

## [Need help with some GLSL shader code](https://discourse.processing.org/t/need-help-with-some-glsl-shader-code/21655)

<div class="topic-metadata">

**Author:** [@zenglenn](https://discourse.processing.org/u/zenglenn)\
**Replies:** 4\
**Last updated:** [June 12, 2020, 6:41am UTC](https://discourse.processing.org/t/need-help-with-some-glsl-shader-code/21655 "2020-06-12T06:41:13Z")

</div>

Hi I want to use Processing shaders to do some code art algorithms - but I want to do it all through a shader to take advantage of the high GPU power. I know the basics of shader programming, but what I’m stuck on at t…

---

## [How to delete elements while traversing the list in processing.py?](https://discourse.processing.org/t/how-to-delete-elements-while-traversing-the-list-in-processing-py/21041)

<div class="topic-metadata">

**Author:** [@huahua](https://discourse.processing.org/u/huahua)\
**Replies:** 4\
**Last updated:** [June 12, 2020, 4:54am UTC](https://discourse.processing.org/t/how-to-delete-elements-while-traversing-the-list-in-processing-py/21041 "2020-06-12T04:54:05Z")

</div>

the code as follows is about particles system, and it could run successfully. i understant the code. the elements in the list particles represent particles, and particles will continue to be generated and die gradually, …

---

## [Randomly Appearing Objects When Something Is Clicked](https://discourse.processing.org/t/randomly-appearing-objects-when-something-is-clicked/21792)

<div class="topic-metadata">

**Author:** [@chemicalite](https://discourse.processing.org/u/chemicalite)\
**Replies:** 8\
**Last updated:** [June 12, 2020, 2:12am UTC](https://discourse.processing.org/t/randomly-appearing-objects-when-something-is-clicked/21792 "2020-06-12T02:12:07Z")

</div>

Hey everyone! I’m currently working on a coding project and needed a bit of help on how to do something. I want to be able to have a different “text box” appear every time the user clicks the corner of the canvas. The t…

---

## [How to save a transparent gif （without background）？](https://discourse.processing.org/t/how-to-save-a-transparent-gif-without-background/21730)

<div class="topic-metadata">

**Author:** [@ffewaghdfh](https://discourse.processing.org/u/ffewaghdfh)\
**Replies:** 13\
**Last updated:** [June 12, 2020, 1:34am UTC](https://discourse.processing.org/t/how-to-save-a-transparent-gif-without-background/21730 "2020-06-12T01:34:17Z")

</div>

When the png is ok（without background，transparent）.，I use canvas to save the gif，but I always get a gif with a black background . I used a method to replace black with transparency, but there will still be black resid…

---

## [Issue when using Box2D and video libraries together](https://discourse.processing.org/t/issue-when-using-box2d-and-video-libraries-together/21754)

<div class="topic-metadata">

**Author:** [@EmmaB](https://discourse.processing.org/u/EmmaB)\
**Replies:** 1\
**Last updated:** [June 12, 2020, 12:44am UTC](https://discourse.processing.org/t/issue-when-using-box2d-and-video-libraries-together/21754 "2020-06-12T00:44:59Z")

</div>

Hello, I trying to create a sketch with both the Box2D for Processing and Video libraries. I have some boxes moving around and colliding with each other, and I want to texture these boxes with some video. However, I g…

---

## [Mapping a point a "sub" matrix to main/default matrix?](https://discourse.processing.org/t/mapping-a-point-a-sub-matrix-to-main-default-matrix/21568)

<div class="topic-metadata">

**Author:** [@Perro](https://discourse.processing.org/u/Perro)\
**Replies:** 6\
**Last updated:** [June 11, 2020, 9:31pm UTC](https://discourse.processing.org/t/mapping-a-point-a-sub-matrix-to-main-default-matrix/21568 "2020-06-11T21:31:46Z")

</div>

Hi, Can anyone advise how to map a point, calculated within a matrix, to a point in the “main” (top-level) matrix? More specifically, I have a situation where separate points are calculated within two separate matrices…

---

## [pGraphics.beginDraw() RuntimeException: Too many pushFramebuffer calls](https://discourse.processing.org/t/pgraphics-begindraw-runtimeexception-too-many-pushframebuffer-calls/21765)

<div class="topic-metadata">

**Author:** [@mgood7123](https://discourse.processing.org/u/mgood7123)\
**Replies:** 2\
**Last updated:** [June 11, 2020, 9:18pm UTC](https://discourse.processing.org/t/pgraphics-begindraw-runtimeexception-too-many-pushframebuffer-calls/21765 "2020-06-11T21:18:44Z")

</div>

why would i get RuntimeException: Too many pushFramebuffer calls when calling window.graphics = createGraphics(window.width, window.height, type); window.graphics.beginDraw(); java.lang.RuntimeExcepti…

---

## [No toolchains for mips64el-linux-android](https://discourse.processing.org/t/no-toolchains-for-mips64el-linux-android/5282)

<div class="topic-metadata">

**Author:** [@interstar](https://discourse.processing.org/u/interstar)\
**Replies:** 8\
**Last updated:** [June 11, 2020, 9:04pm UTC](https://discourse.processing.org/t/no-toolchains-for-mips64el-linux-android/5282 "2020-06-11T21:04:21Z")

</div>

I’ve been upgrading various things recently, including Android Studio and Processing and Processing for Android. And now I can’t compile sketches for Android in the Processing IDE anymore. I’m getting this error messag…

---

## [Help reading data from a game (Diablo II) or analyzing an image from it for text recognition](https://discourse.processing.org/t/help-reading-data-from-a-game-diablo-ii-or-analyzing-an-image-from-it-for-text-recognition/21782)

<div class="topic-metadata">

**Author:** [@Randios](https://discourse.processing.org/u/Randios)\
**Replies:** 3\
**Last updated:** [June 11, 2020, 7:55pm UTC](https://discourse.processing.org/t/help-reading-data-from-a-game-diablo-ii-or-analyzing-an-image-from-it-for-text-recognition/21782 "2020-06-11T19:55:35Z")

</div>

Hello all. I’ve been using processing for a couple of years now and it’s worked well for most of my needs, but I am having some trouble with one particular project. The project is to make physical health/mana indicators…

---

## [How to position image correctly with applyMatrix](https://discourse.processing.org/t/how-to-position-image-correctly-with-applymatrix/21766)

<div class="topic-metadata">

**Author:** [@r4nd0m](https://discourse.processing.org/u/r4nd0m)\
**Replies:** 4\
**Last updated:** [June 11, 2020, 7:38pm UTC](https://discourse.processing.org/t/how-to-position-image-correctly-with-applymatrix/21766 "2020-06-11T19:38:44Z")

</div>

Hi, I’ve started my first AR project and I can’t figure out how to position image correctly in a real world. For example, I want to replace my TV screen with custom image like this: My question is: if I know the co…

---

## [Why doesn't processing recognize the key? (keyReleased)](https://discourse.processing.org/t/why-doesnt-processing-recognize-the-key-keyreleased/21777)

<div class="topic-metadata">

**Author:** [@Moritz](https://discourse.processing.org/u/Moritz)\
**Replies:** 3\
**Last updated:** [June 11, 2020, 7:13pm UTC](https://discourse.processing.org/t/why-doesnt-processing-recognize-the-key-keyreleased/21777 "2020-06-11T19:13:45Z")

</div>

Hi guys, why doesn’t Processing recognize the ‘e’ key when the ‘s’ and ‘d’ or ‘w’ and ‘d’ keys are already pressed? // Click on the image to give it focus, // and then press any key. int value = 0; void draw() { fi…

---

## [Execute OSCsend only once within draw() function](https://discourse.processing.org/t/execute-oscsend-only-once-within-draw-function/21761)

<div class="topic-metadata">

**Author:** [@SaltyBoy](https://discourse.processing.org/u/SaltyBoy)\
**Replies:** 2\
**Last updated:** [June 11, 2020, 6:29pm UTC](https://discourse.processing.org/t/execute-oscsend-only-once-within-draw-function/21761 "2020-06-11T18:29:58Z")

</div>

For my Simon Game I want to execute a sound only once by sending a message to Pure Data (Pd), as soon as the color appear. Have you any tipps, how to do that? import oscP5.\*; import netP5.\*; OscP5 oscP5; NetAddress my…

---

## [Scoped beginDraw and endDraw](https://discourse.processing.org/t/scoped-begindraw-and-enddraw/21767)

<div class="topic-metadata">

**Author:** [@mgood7123](https://discourse.processing.org/u/mgood7123)\
**Replies:** 1\
**Last updated:** [June 11, 2020, 6:24pm UTC](https://discourse.processing.org/t/scoped-begindraw-and-enddraw/21767 "2020-06-11T18:24:52Z")

</div>

is there any way to use PGraphics.beginDraw and PGraphics.endDraw outside of the scope of PGraphics.\*() calls? for example if i do this then nothing renders void drawGraphics() { //graphics.endDraw(); if (dis…

---

## [Performance - draw vs redraw](https://discourse.processing.org/t/performance-draw-vs-redraw/21763)

<div class="topic-metadata">

**Author:** [@mgood7123](https://discourse.processing.org/u/mgood7123)\
**Replies:** 5\
**Last updated:** [June 11, 2020, 6:16pm UTC](https://discourse.processing.org/t/performance-draw-vs-redraw/21763 "2020-06-11T18:16:26Z")

</div>

when would it be good to use draw() and when would it be good to use redraw() and could a program ran via a main draw() loop be made faster by only using a redraw-when-needed approach? if so, is redraw, in a while(true…

---

## [Can I generate a QR code through'processing'?](https://discourse.processing.org/t/can-i-generate-a-qr-code-throughprocessing/21756)

<div class="topic-metadata">

**Author:** [@GWAK](https://discourse.processing.org/u/GWAK)\
**Replies:** 2\
**Last updated:** [June 11, 2020, 5:36pm UTC](https://discourse.processing.org/t/can-i-generate-a-qr-code-throughprocessing/21756 "2020-06-11T17:36:27Z")

</div>

I want to generate a QR code through the program. Is there a way? Help.

---

## [Adding one textured plane slows/lags the whole environment](https://discourse.processing.org/t/adding-one-textured-plane-slows-lags-the-whole-environment/21720)

<div class="topic-metadata">

**Author:** [@awunk](https://discourse.processing.org/u/awunk)\
**Replies:** 2\
**Last updated:** [June 11, 2020, 5:46pm UTC](https://discourse.processing.org/t/adding-one-textured-plane-slows-lags-the-whole-environment/21720 "2020-06-11T17:46:54Z")

</div>

Following some popular p5.js tutorials I got a 3d environment of cubes running, I want to add a text element for a little GUI. However, when texture(hovertext) is ran in the draw function, the environment drops from 30fp…

---

## [Off-screen render performance, multiple PGraphics objects](https://discourse.processing.org/t/off-screen-render-performance-multiple-pgraphics-objects/21783)

<div class="topic-metadata">

**Author:** [@mgood7123](https://discourse.processing.org/u/mgood7123)\
**Replies:** 0\
**Last updated:** [June 11, 2020, 5:22pm UTC](https://discourse.processing.org/t/off-screen-render-performance-multiple-pgraphics-objects/21783 "2020-06-11T17:22:24Z")

</div>

how can reduce the time taken to draw all my components? as, specifically, PGraphics.beginDraw() and PGraphics.endDraw() calls are expensive if there are a lot of them in a single call as if i do 400 by 400 i get 60 f…

---

## [Help me put static complex shapes in box2d](https://discourse.processing.org/t/help-me-put-static-complex-shapes-in-box2d/21736)

<div class="topic-metadata">

**Author:** [@yhlaskerimov](https://discourse.processing.org/u/yhlaskerimov)\
**Replies:** 1\
**Last updated:** [June 11, 2020, 5:15pm UTC](https://discourse.processing.org/t/help-me-put-static-complex-shapes-in-box2d/21736 "2020-06-11T17:15:26Z")

</div>

Hello everyone, help me please… I think everyone knows box2d library written by Shiffman. In his examples he adds boundaries only rectangle shape.I want to add a half circle to the edges of that rectangle. (From left a…

---

## [Issue with map() function](https://discourse.processing.org/t/issue-with-map-function/21715)

<div class="topic-metadata">

**Author:** [@Th3cG](https://discourse.processing.org/u/Th3cG)\
**Replies:** 6\
**Last updated:** [June 11, 2020, 4:19pm UTC](https://discourse.processing.org/t/issue-with-map-function/21715 "2020-06-11T16:19:30Z")

</div>

Hello, I’m trying to write some code to animate a logo that starts from the left of the screen, then bounces on the right side and stops. My initial sketch works with a width of 640px as follows; PImage logo; float x …

---

## [Load GIFs in processing 3](https://discourse.processing.org/t/load-gifs-in-processing-3/21743)

<div class="topic-metadata">

**Author:** [@HajarHadi](https://discourse.processing.org/u/HajarHadi)\
**Replies:** 4\
**Last updated:** [June 11, 2020, 2:50pm UTC](https://discourse.processing.org/t/load-gifs-in-processing-3/21743 "2020-06-11T14:50:10Z")

</div>

Hello im using processing 3 but i cant load the GIFs can anybody tell me how to load a GIFs in processing thank you very much

---

## [How to make my sketch fit to any screen resolution of android device made from APDE](https://discourse.processing.org/t/how-to-make-my-sketch-fit-to-any-screen-resolution-of-android-device-made-from-apde/21762)

<div class="topic-metadata">

**Author:** [@Why\_I\_Use\_Processing](https://discourse.processing.org/u/Why_I_Use_Processing)\
**Replies:** 4\
**Last updated:** [June 11, 2020, 2:34pm UTC](https://discourse.processing.org/t/how-to-make-my-sketch-fit-to-any-screen-resolution-of-android-device-made-from-apde/21762 "2020-06-11T14:34:06Z")

</div>

I am making a processing sketch using APDE, the sketch runs on full screen. I made the sketch the way that it fits over to the resolution of my android phone. But when I switch to other phones to test it, sometimes the…

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

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