# Processing

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

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

**Page:** 181

---

## [Why does uncommenting this line of code increase sketch performance by 20 times faster?](https://discourse.processing.org/t/why-does-uncommenting-this-line-of-code-increase-sketch-performance-by-20-times-faster/23944)

<div class="topic-metadata">

**Author:** [@adamskii\_uk](https://discourse.processing.org/u/adamskii_uk)\
**Replies:** 15\
**Last updated:** [September 30, 2020, 1:53pm UTC](https://discourse.processing.org/t/why-does-uncommenting-this-line-of-code-increase-sketch-performance-by-20-times-faster/23944 "2020-09-30T13:53:23Z")

</div>

Hi :smiley: Yesterday, I started writing a 2D game engine from scratch in JAVA, and I was benchmarking every single line of code I added to my class to keep the framerate high. Then after around 2 hours of writing my c…

---

## [Pick up object on random coordinates inside of 2D-array](https://discourse.processing.org/t/pick-up-object-on-random-coordinates-inside-of-2d-array/24219)

<div class="topic-metadata">

**Author:** [@Reynaert98](https://discourse.processing.org/u/Reynaert98)\
**Replies:** 1\
**Last updated:** [September 30, 2020, 10:36am UTC](https://discourse.processing.org/t/pick-up-object-on-random-coordinates-inside-of-2d-array/24219 "2020-09-30T10:36:10Z")

</div>

I have a game in which a moving player has to collect ellipses in order to gain points. The ellipses are randomly distributed on a grid by using the following code: int rows = 40; int cols = 60; int objectOffset = 25; f…

---

## [Collision Detection (Game Design)](https://discourse.processing.org/t/collision-detection-game-design/24142)

<div class="topic-metadata">

**Author:** [@Aoyanco](https://discourse.processing.org/u/Aoyanco)\
**Replies:** 3\
**Last updated:** [September 30, 2020, 8:53am UTC](https://discourse.processing.org/t/collision-detection-game-design/24142 "2020-09-30T08:53:51Z")

</div>

Hi! I’m trying to make a platformer style game. I already have most of the physics done, but I’m now trying to do the collision detection and I’m stumped. I can think of ways to do it, but in my game, the levels will be …

---

## [Question about the correct usage of the thread() method and it's application to my code](https://discourse.processing.org/t/question-about-the-correct-usage-of-the-thread-method-and-its-application-to-my-code/24228)

<div class="topic-metadata">

**Author:** [@Thecido](https://discourse.processing.org/u/Thecido)\
**Replies:** 1\
**Last updated:** [September 29, 2020, 7:58pm UTC](https://discourse.processing.org/t/question-about-the-correct-usage-of-the-thread-method-and-its-application-to-my-code/24228 "2020-09-29T19:58:40Z")

</div>

Hi, I am rather new to processing and I was trying out the thread() method to speed up my code and run multiple instances of different sorting algorithms I’ve been developing lately, please note that I have just a basic …

---

## [Making increments change direction?](https://discourse.processing.org/t/making-increments-change-direction/24202)

<div class="topic-metadata">

**Author:** [@AlexW](https://discourse.processing.org/u/AlexW)\
**Replies:** 4\
**Last updated:** [September 29, 2020, 12:08pm UTC](https://discourse.processing.org/t/making-increments-change-direction/24202 "2020-09-29T12:08:30Z")

</div>

Hello, I’m taking a processing class at university and I’m working on our first project which is to make a reproduction of a piece of artwork and add some interaction and animation to it. So far I’ve come up with a ne…

---

## [Processing Video library inconsistent behavior with jumping](https://discourse.processing.org/t/processing-video-library-inconsistent-behavior-with-jumping/24214)

<div class="topic-metadata">

**Author:** [@musiciantriescoding](https://discourse.processing.org/u/musiciantriescoding)\
**Replies:** 0\
**Last updated:** [September 29, 2020, 8:59am UTC](https://discourse.processing.org/t/processing-video-library-inconsistent-behavior-with-jumping/24214 "2020-09-29T08:59:03Z")

</div>

Hello everyone! I am experiencing some inconsistent behavior from the Processing video library. What I’m trying to do: I’m making a video sampler with a midi keyboard. When I play a key, the video jumps to a timestamp…

---

## [Input controlled video playback in Processing](https://discourse.processing.org/t/input-controlled-video-playback-in-processing/23084)

<div class="topic-metadata">

**Author:** [@ruta](https://discourse.processing.org/u/ruta)\
**Replies:** 1\
**Last updated:** [September 29, 2020, 8:25am UTC](https://discourse.processing.org/t/input-controlled-video-playback-in-processing/23084 "2020-09-29T08:25:54Z")

</div>

Hi! I am reading capacitive sensors with Arduino and the number of the sensor touched is communicated to Processing, at the moment it is just 1 or 2. In Processing, I am trying to play a video depending on the number of …

---

## [Tessellation Error?](https://discourse.processing.org/t/tessellation-error/1164)

<div class="topic-metadata">

**Author:** [@KAZ](https://discourse.processing.org/u/KAZ)\
**Replies:** 1\
**Last updated:** [September 29, 2020, 5:22am UTC](https://discourse.processing.org/t/tessellation-error/1164 "2020-09-29T05:22:22Z")

</div>

Am doing some Planetary System Simulation stuff . It’s doing well apart from occasionally , when I launch a planet too much near the sun the planet move through the sun very fast and the console spits out this error in …

---

## [Creating and then accessing sets of possible pixel sequences (Markov?)](https://discourse.processing.org/t/creating-and-then-accessing-sets-of-possible-pixel-sequences-markov/24209)

<div class="topic-metadata">

**Author:** [@jl33](https://discourse.processing.org/u/jl33)\
**Replies:** 1\
**Last updated:** [September 28, 2020, 11:58pm UTC](https://discourse.processing.org/t/creating-and-then-accessing-sets-of-possible-pixel-sequences-markov/24209 "2020-09-28T23:58:30Z")

</div>

Keep thinking different ways to go about this but I don’t quite have the experience to fully wrap my head around. I want to analyze an img to create (and then access/manipulate) basically a Markov model of the set of co…

---

## [Using noLoop() function with nested for loops](https://discourse.processing.org/t/using-noloop-function-with-nested-for-loops/24208)

<div class="topic-metadata">

**Author:** [@thughes](https://discourse.processing.org/u/thughes)\
**Replies:** 1\
**Last updated:** [September 28, 2020, 11:35pm UTC](https://discourse.processing.org/t/using-noloop-function-with-nested-for-loops/24208 "2020-09-28T23:35:55Z")

</div>

Can you use noLoop with nested for loops? I have an assignment that states to create a grid shown in my lesson and observe what it does. Then it says to add the noLoop() function and observe what it does. I have done …

---

## [For Processing, is there some GUI box I can show or something?](https://discourse.processing.org/t/for-processing-is-there-some-gui-box-i-can-show-or-something/24069)

<div class="topic-metadata">

**Author:** [@anon76195010](https://discourse.processing.org/u/anon76195010)\
**Replies:** 5\
**Last updated:** [September 28, 2020, 8:07pm UTC](https://discourse.processing.org/t/for-processing-is-there-some-gui-box-i-can-show-or-something/24069 "2020-09-28T20:07:14Z")

</div>

Is there a library or something that I can import for Processing which can show a GUI box which prompts the user to fill out information, for example age, gender etc?

---

## [Music visualizer processing (minim library)](https://discourse.processing.org/t/music-visualizer-processing-minim-library/24067)

<div class="topic-metadata">

**Author:** [@sabrufran](https://discourse.processing.org/u/sabrufran)\
**Replies:** 2\
**Last updated:** [September 28, 2020, 12:33pm UTC](https://discourse.processing.org/t/music-visualizer-processing-minim-library/24067 "2020-09-28T12:33:08Z")

</div>

hi, i’m new to Processing and i’m interested in being able to synchronize the sketch with the audio specifically that the height of the “mountains” grows in sync with the audio. I made this sketch following the video: ht…

---

## [Redrawing Pimage with point() after rotate() creates weird pixel patterns](https://discourse.processing.org/t/redrawing-pimage-with-point-after-rotate-creates-weird-pixel-patterns/24034)

<div class="topic-metadata">

**Author:** [@erk](https://discourse.processing.org/u/erk)\
**Replies:** 6\
**Last updated:** [September 28, 2020, 11:55am UTC](https://discourse.processing.org/t/redrawing-pimage-with-point-after-rotate-creates-weird-pixel-patterns/24034 "2020-09-28T11:55:12Z")

</div>

I try to mirror a PImage, using parts of the code found here: https://thecodingtrain.com/CodingChallenges/155-kaleidoscope-snowflake.html The difference is, that i use point() to draw the single pixels of the picture. I…

---

## [Question for "try()"](https://discourse.processing.org/t/question-for-try/24151)

<div class="topic-metadata">

**Author:** [@JoLi](https://discourse.processing.org/u/JoLi)\
**Replies:** 4\
**Last updated:** [September 28, 2020, 11:10am UTC](https://discourse.processing.org/t/question-for-try/24151 "2020-09-28T11:10:59Z")

</div>

Any Ideas, why this is not working? Processing 3.5.4, Windows 10

---

## [Rectangle not moving](https://discourse.processing.org/t/rectangle-not-moving/24161)

<div class="topic-metadata">

**Author:** [@Tobias](https://discourse.processing.org/u/Tobias)\
**Replies:** 9\
**Last updated:** [September 28, 2020, 11:10am UTC](https://discourse.processing.org/t/rectangle-not-moving/24161 "2020-09-28T11:10:02Z")

</div>

Hi. I am new to processing and I am trying to make Pong. I want both the paddles to be able to move at once. Since keyPressed only allows for one button press at a time, i tried to add a boolean for each button press in…

---

## [I need help drawing pictures](https://discourse.processing.org/t/i-need-help-drawing-pictures/24185)

<div class="topic-metadata">

**Author:** [@Poorman](https://discourse.processing.org/u/Poorman)\
**Replies:** 1\
**Last updated:** [September 28, 2020, 7:23am UTC](https://discourse.processing.org/t/i-need-help-drawing-pictures/24185 "2020-09-28T07:23:33Z")

</div>

Im a processing beginner Please tell me how ty

---

## [It looks like you're mixing "active" and "static" modes](https://discourse.processing.org/t/it-looks-like-youre-mixing-active-and-static-modes/24159)

<div class="topic-metadata">

**Author:** [@COZ](https://discourse.processing.org/u/COZ)\
**Replies:** 3\
**Last updated:** [September 28, 2020, 2:00am UTC](https://discourse.processing.org/t/it-looks-like-youre-mixing-active-and-static-modes/24159 "2020-09-28T02:00:55Z")

</div>

Hello, complete begginer here. Just making my way through some tutorials and i’ve been hit with the error (the subject title). I know it’s defining static and active states, which can’t be both at the same time. But i c…

---

## [Surface.setSize() error](https://discourse.processing.org/t/surface-setsize-error/24144)

<div class="topic-metadata">

**Author:** [@mrbbp](https://discourse.processing.org/u/mrbbp)\
**Replies:** 6\
**Last updated:** [September 28, 2020, 1:20am UTC](https://discourse.processing.org/t/surface-setsize-error/24144 "2020-09-28T01:20:26Z")

</div>

Hello, i’m trying to setSize of my window and discover a strange behaviour. try this code. On my MacOS 10.14.6 and Processing 3.5.3 It’s suppose to open a window with 10px in height… It does not! it open a window w…

---

## [Trying to create a font, getting error: IllegalArgumentException: loadFont() is for .vlw files, try createFont()](https://discourse.processing.org/t/trying-to-create-a-font-getting-error-illegalargumentexception-loadfont-is-for-vlw-files-try-createfont/24174)

<div class="topic-metadata">

**Author:** [@adl](https://discourse.processing.org/u/adl)\
**Replies:** 2\
**Last updated:** [September 27, 2020, 10:23pm UTC](https://discourse.processing.org/t/trying-to-create-a-font-getting-error-illegalargumentexception-loadfont-is-for-vlw-files-try-createfont/24174 "2020-09-27T22:23:21Z")

</div>

I used tools, create fonts option from menu to create font , the system created data folder with the font file name. the code is below. What am I missing? / PFont font1; void setup(){ size(500,500); font1=loadFon…

---

## [Nested for loops---help please!](https://discourse.processing.org/t/nested-for-loops-help-please/24129)

<div class="topic-metadata">

**Author:** [@thughes](https://discourse.processing.org/u/thughes)\
**Replies:** 17\
**Last updated:** [September 27, 2020, 8:49pm UTC](https://discourse.processing.org/t/nested-for-loops-help-please/24129 "2020-09-27T20:49:01Z")

</div>

I have an assignment that states the following–Create a program using nested for statements that will produce 5 rows, 7 in each column of diagonals as shown. You will need to size the frame 450 x 450. Determine your coo…

---

## [Juggling Game Bug](https://discourse.processing.org/t/juggling-game-bug/24172)

<div class="topic-metadata">

**Author:** [@FloorBean](https://discourse.processing.org/u/FloorBean)\
**Replies:** 3\
**Last updated:** [September 27, 2020, 8:47pm UTC](https://discourse.processing.org/t/juggling-game-bug/24172 "2020-09-27T20:47:39Z")

</div>

Hello, I am experiencing a weird bug in my game where the ball seems to get caught in a conditional that throws it out of my display screen. I am not really sure why this is happening because my logic seems to be correct…

---

## [Multiple levels](https://discourse.processing.org/t/multiple-levels/24164)

<div class="topic-metadata">

**Author:** [@koenterheegde57](https://discourse.processing.org/u/koenterheegde57)\
**Replies:** 0\
**Last updated:** [September 27, 2020, 6:20pm UTC](https://discourse.processing.org/t/multiple-levels/24164 "2020-09-27T18:20:50Z")

</div>

Hi guys, I’m making a fun game in which you have to get a rocket as high as possible. I have made the first ‘level’ and I now want to add more levels. The transition from level 1 to level 2 works fine, but backwards is…

---

## [How to create a function out of a shape](https://discourse.processing.org/t/how-to-create-a-function-out-of-a-shape/23911)

<div class="topic-metadata">

**Author:** [@eco.pm2](https://discourse.processing.org/u/eco.pm2)\
**Replies:** 14\
**Last updated:** [September 27, 2020, 3:12am UTC](https://discourse.processing.org/t/how-to-create-a-function-out-of-a-shape/23911 "2020-09-27T03:12:20Z")

</div>

Hi I would like to move the ‘shuttle’ over and under the ellipses with a mouse command at first. Where could I find a tutorial video for that please? I was wondering if the 'shuttle could become a ‘shuttleShape’, as …

---

## [Window cannot properly resize on Linux, GNOME](https://discourse.processing.org/t/window-cannot-properly-resize-on-linux-gnome/24141)

<div class="topic-metadata">

**Author:** [@sashakoshka](https://discourse.processing.org/u/sashakoshka)\
**Replies:** 1\
**Last updated:** [September 26, 2020, 8:02pm UTC](https://discourse.processing.org/t/window-cannot-properly-resize-on-linux-gnome/24141 "2020-09-26T20:02:03Z")

</div>

I am running Pop!\_OS 20.04 LTS, with GNOME version 3.36.3 When I run a resizable sketch, resizing it will often only resize the window, and fill the empty space with junk data, while keeping the sketch the same size. Of…

---

## [Adding objects to the canvas fom within the mousePressed() method](https://discourse.processing.org/t/adding-objects-to-the-canvas-fom-within-the-mousepressed-method/24121)

<div class="topic-metadata">

**Author:** [@nestor0920](https://discourse.processing.org/u/nestor0920)\
**Replies:** 8\
**Last updated:** [September 26, 2020, 6:33pm UTC](https://discourse.processing.org/t/adding-objects-to-the-canvas-fom-within-the-mousepressed-method/24121 "2020-09-26T18:33:16Z")

</div>

I’m trying to create a sketch where after setup the canvas is only changed when the user adds some geometrical objects by pressing the mouse. So it seems inappropriate to me to even implement the draw() method. To my un…

---

## [To go beyond the limit of your screen](https://discourse.processing.org/t/to-go-beyond-the-limit-of-your-screen/24136)

<div class="topic-metadata">

**Author:** [@yanze03](https://discourse.processing.org/u/yanze03)\
**Replies:** 9\
**Last updated:** [September 26, 2020, 5:21pm UTC](https://discourse.processing.org/t/to-go-beyond-the-limit-of-your-screen/24136 "2020-09-26T17:21:52Z")

</div>

Hi, I am trying to make a program where the size of my screen is a bit to small. I am trying to make it so that when I pusch a button or scroll a scrollbar the X coordinate of the canvas moves. This would mean that the…

---

## [Exporting DXF is mirrored - CMM Arm](https://discourse.processing.org/t/exporting-dxf-is-mirrored-cmm-arm/13995)

<div class="topic-metadata">

**Author:** [@Bryan1](https://discourse.processing.org/u/Bryan1)\
**Replies:** 18\
**Last updated:** [September 25, 2020, 9:32pm UTC](https://discourse.processing.org/t/exporting-dxf-is-mirrored-cmm-arm/13995 "2020-09-25T21:32:18Z")

</div>

I am working on building a CMM Arm with the end goal of exporting a 3D .DXF file of the object measured as well as a point cloud file (simple Tab Delimited Text file). I am having trouble with exporting the DXF as its sa…

---

## [Writing a small Programming Language](https://discourse.processing.org/t/writing-a-small-programming-language/24095)

<div class="topic-metadata">

**Author:** [@yairkass](https://discourse.processing.org/u/yairkass)\
**Replies:** 9\
**Last updated:** [September 25, 2020, 7:51pm UTC](https://discourse.processing.org/t/writing-a-small-programming-language/24095 "2020-09-25T19:51:54Z")

</div>

hey guys, For a couple of years now iv’e been wanting to write a small programming language in HEBREW for my young (now 7) and curious daughter. Iv’e researched some and I feel like I know what has to be learned, but…

---

## [Processing freezes when stopping a sketch](https://discourse.processing.org/t/processing-freezes-when-stopping-a-sketch/6090)

<div class="topic-metadata">

**Author:** [@TheZipCreator](https://discourse.processing.org/u/TheZipCreator)\
**Replies:** 2\
**Last updated:** [September 25, 2020, 1:30pm UTC](https://discourse.processing.org/t/processing-freezes-when-stopping-a-sketch/6090 "2020-09-25T13:30:12Z")

</div>

So, whenever I press “start” on a sketch, nothing happens. When I press “stop”, processing freezes and no longer appears on task manager. This happens with all of my sketches I use Windows 64-bit

---

## [Creating a Simple class with a circle](https://discourse.processing.org/t/creating-a-simple-class-with-a-circle/24066)

<div class="topic-metadata">

**Author:** [@FloorBean](https://discourse.processing.org/u/FloorBean)\
**Replies:** 3\
**Last updated:** [September 25, 2020, 12:34pm UTC](https://discourse.processing.org/t/creating-a-simple-class-with-a-circle/24066 "2020-09-25T12:34:40Z")

</div>

Hello, I am trying to make a class with just a simple circle. I am planning to eventually have more circles too, but I think that I am running into a syntax/logic error. Any help would be greatly appreciated. bubble b1; …

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

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