# Processing

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

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

**Page:** 292

---

## [How can I put a three second delay within an if loop?](https://discourse.processing.org/t/how-can-i-put-a-three-second-delay-within-an-if-loop/11965)

<div class="topic-metadata">

**Author:** [@Gaspaider](https://discourse.processing.org/u/Gaspaider)\
**Replies:** 4\
**Last updated:** [June 10, 2019, 8:59pm UTC](https://discourse.processing.org/t/how-can-i-put-a-three-second-delay-within-an-if-loop/11965 "2019-06-10T20:59:29Z")

</div>

Hey there! I know there have been questions very similar to this using millis() before but I can’t find a way to build those answers into my program. Timer is a variable for something else. I would like to add a three se…

---

## [On window resize, variable current value evaporates](https://discourse.processing.org/t/on-window-resize-variable-current-value-evaporates/11952)

<div class="topic-metadata">

**Author:** [@edward](https://discourse.processing.org/u/edward)\
**Replies:** 7\
**Last updated:** [June 10, 2019, 6:44pm UTC](https://discourse.processing.org/t/on-window-resize-variable-current-value-evaporates/11952 "2019-06-10T18:44:45Z")

</div>

My project will involve multiple text input boxes which must move and adjust position dynamically when I resize the window. This bare-to-basics code only includes two boxes, when the mouse is over a box, the box is high…

---

## [How to get a shape to change color when mouse is over it?](https://discourse.processing.org/t/how-to-get-a-shape-to-change-color-when-mouse-is-over-it/11974)

<div class="topic-metadata">

**Author:** [@benfitzy21](https://discourse.processing.org/u/benfitzy21)\
**Replies:** 1\
**Last updated:** [June 10, 2019, 4:39pm UTC](https://discourse.processing.org/t/how-to-get-a-shape-to-change-color-when-mouse-is-over-it/11974 "2019-06-10T16:39:33Z")

</div>

Can someone help, I have been sitting here trying to figure this out for 3 hours.

---

## [Help with user input dialogues](https://discourse.processing.org/t/help-with-user-input-dialogues/11955)

<div class="topic-metadata">

**Author:** [@rory](https://discourse.processing.org/u/rory)\
**Replies:** 1\
**Last updated:** [June 10, 2019, 3:29am UTC](https://discourse.processing.org/t/help-with-user-input-dialogues/11955 "2019-06-10T03:29:16Z")

</div>

Hello again, I’m making a “Geometry tutor” program which contains instructions, learn, and a practice section where the user can quiz themselves. I have been instructed to use a specific input file for the quiz question…

---

## [Modifing functions in classes using extends](https://discourse.processing.org/t/modifing-functions-in-classes-using-extends/11913)

<div class="topic-metadata">

**Author:** [@skyjoe66](https://discourse.processing.org/u/skyjoe66)\
**Replies:** 2\
**Last updated:** [June 9, 2019, 11:05pm UTC](https://discourse.processing.org/t/modifing-functions-in-classes-using-extends/11913 "2019-06-09T23:05:27Z")

</div>

i am making a game and am using nested classes to create block variations, but i want tree to have an addition to the drawing process (a progress bar). is there a way to use the same function call but have it run like no…

---

## [\[SOLVED\] Creating "FPS-like" mouse detection](https://discourse.processing.org/t/solved-creating-fps-like-mouse-detection/11946)

<div class="topic-metadata">

**Author:** [@koorkevani](https://discourse.processing.org/u/koorkevani)\
**Replies:** 3\
**Last updated:** [June 9, 2019, 10:57pm UTC](https://discourse.processing.org/t/solved-creating-fps-like-mouse-detection/11946 "2019-06-09T22:57:09Z")

</div>

I’m trying to recreate the controls of the game Minecraft. For those who don’t know, when you move the mouse, the direction you’re facing changes accordingly (if you’re moving the mouse upwards, it’s like looking upwards…

---

## [Did anybody make a R.U.B.E loader for processing?](https://discourse.processing.org/t/did-anybody-make-a-r-u-b-e-loader-for-processing/11944)

<div class="topic-metadata">

**Author:** [@yairkass](https://discourse.processing.org/u/yairkass)\
**Replies:** 1\
**Last updated:** [June 9, 2019, 4:39pm UTC](https://discourse.processing.org/t/did-anybody-make-a-r-u-b-e-loader-for-processing/11944 "2019-06-09T16:39:45Z")

</div>

R.U.B.E is a really cool project. It’s a graphic visual editor for Box2D scenes and worlds. It really took me by surprise and the examples on the page are amazing. This editor can export all your scenes to Java (and ot…

---

## [Line first coordinate is allways (0,0)](https://discourse.processing.org/t/line-first-coordinate-is-allways-0-0/11942)

<div class="topic-metadata">

**Author:** [@BallazX](https://discourse.processing.org/u/BallazX)\
**Replies:** 2\
**Last updated:** [June 9, 2019, 2:34pm UTC](https://discourse.processing.org/t/line-first-coordinate-is-allways-0-0/11942 "2019-06-09T14:34:37Z")

</div>

Hey All, I would like to draw some lines: void setup() { size(600, 600); noLoop(); } void draw(){ line(pmouseX, pmouseY, mouseX, mouseY); } void mouseClicked() { redraw(); } My problem is, that the first line …

---

## [Save data to "secure" or hidden file](https://discourse.processing.org/t/save-data-to-secure-or-hidden-file/11868)

<div class="topic-metadata">

**Author:** [@mala](https://discourse.processing.org/u/mala)\
**Replies:** 4\
**Last updated:** [June 9, 2019, 10:27am UTC](https://discourse.processing.org/t/save-data-to-secure-or-hidden-file/11868 "2019-06-09T10:27:30Z")

</div>

I have various auto saved & auto loaded settings in my app that I don’t want an end user messing with, what is the best way from preventing them doing this ? Is there a way to export data (a Table for example) to a form…

---

## [Add PGraphics to a custom method](https://discourse.processing.org/t/add-pgraphics-to-a-custom-method/11930)

<div class="topic-metadata">

**Author:** [@BallazX](https://discourse.processing.org/u/BallazX)\
**Replies:** 3\
**Last updated:** [June 8, 2019, 8:34pm UTC](https://discourse.processing.org/t/add-pgraphics-to-a-custom-method/11930 "2019-06-08T20:34:07Z")

</div>

Hi All, I’ve got this code: void myrect(float xa,float ya,float xb,float yb){ float x1=xa; if(xa\>xb) { while(xb\<x1){ x1--; point(x1,ya); point(x1,yb); } } else if(x1\<xb){ while(x1\<xb…

---

## [Calibrate/Map Kinect feed to Projection](https://discourse.processing.org/t/calibrate-map-kinect-feed-to-projection/11929)

<div class="topic-metadata">

**Author:** [@AlexP](https://discourse.processing.org/u/AlexP)\
**Replies:** 0\
**Last updated:** [June 8, 2019, 6:46pm UTC](https://discourse.processing.org/t/calibrate-map-kinect-feed-to-projection/11929 "2019-06-08T18:46:35Z")

</div>

Hi, I ve written a project where I m using the Kinect (v1), to detect objects in a space and track them. Now the next thing I want to do is use a projector to project onto this object. I m having a hard time to adjust …

---

## [How to use this code with mousePressed?](https://discourse.processing.org/t/how-to-use-this-code-with-mousepressed/11925)

<div class="topic-metadata">

**Author:** [@joysaha573](https://discourse.processing.org/u/joysaha573)\
**Replies:** 4\
**Last updated:** [June 8, 2019, 6:10pm UTC](https://discourse.processing.org/t/how-to-use-this-code-with-mousepressed/11925 "2019-06-08T18:10:21Z")

</div>

I want to appear this circile when mouse is pressed only. Please help with this float angle = 0.00; float offset = 60 ; float scalar = 30; float speed = 0.05; void setup () { size (120, 120);…

---

## [createGraphics() to capture camera frames](https://discourse.processing.org/t/creategraphics-to-capture-camera-frames/11698)

<div class="topic-metadata">

**Author:** [@AwreetusAwrightus](https://discourse.processing.org/u/AwreetusAwrightus)\
**Replies:** 12\
**Last updated:** [June 8, 2019, 4:13pm UTC](https://discourse.processing.org/t/creategraphics-to-capture-camera-frames/11698 "2019-06-08T16:13:17Z")

</div>

hello again everyone! I’m having some trouble figuring out how to capture video in my sketch. As far as I fiddled with saveFrame() or even capture() functions, they all rely on image being displayed in the sketch window…

---

## [Clear() not working properly](https://discourse.processing.org/t/clear-not-working-properly/11924)

<div class="topic-metadata">

**Author:** [@BallazX](https://discourse.processing.org/u/BallazX)\
**Replies:** 1\
**Last updated:** [June 8, 2019, 3:25pm UTC](https://discourse.processing.org/t/clear-not-working-properly/11924 "2019-06-08T15:25:04Z")

</div>

Hi All, I’ve got this code: PGraphics myline; PGraphics myrect; void setup(){ background(#FFFFFF); size(600,600); myline=createGraphics(width,height); myrect=createGraphics(width,height); } void draw(){ myrect.beginD…

---

## [Array of SoundFile](https://discourse.processing.org/t/array-of-soundfile/11919)

<div class="topic-metadata">

**Author:** [@chanof](https://discourse.processing.org/u/chanof)\
**Replies:** 1\
**Last updated:** [June 8, 2019, 1:55pm UTC](https://discourse.processing.org/t/array-of-soundfile/11919 "2019-06-08T13:55:16Z")

</div>

Hi there, i try to get an array of SoundFile to easy change/pass from one to another by press a button, may i ask for help to archive a simple result like. Thanks Gianmaria import processing.sound.\*; SoundFile sounds;…

---

## [blendMode in 3d space](https://discourse.processing.org/t/blendmode-in-3d-space/11857)

<div class="topic-metadata">

**Author:** [@bitCrasher](https://discourse.processing.org/u/bitCrasher)\
**Replies:** 1\
**Last updated:** [June 7, 2019, 9:31pm UTC](https://discourse.processing.org/t/blendmode-in-3d-space/11857 "2019-06-07T21:31:11Z")

</div>

hello guys! i’ve a problem…i’m try to blend with mode ADD some png images in a 3d space, the problem is that it create artifacts, and transparency of background is removed class Particle { PVector pos; PImage img; …

---

## [Map function to a radian value](https://discourse.processing.org/t/map-function-to-a-radian-value/11903)

<div class="topic-metadata">

**Author:** [@GuilhermeVolker](https://discourse.processing.org/u/GuilhermeVolker)\
**Replies:** 3\
**Last updated:** [June 7, 2019, 8:49pm UTC](https://discourse.processing.org/t/map-function-to-a-radian-value/11903 "2019-06-07T20:49:32Z")

</div>

Hello! I need to move an image, from the lateral mouse input to a specific angle on the screen (from 240º to 300º). The direct transformation (as the code) doesn’t work. Is there another way to do that? (to simplify the…

---

## [PGraphics and main window, nice code possible?](https://discourse.processing.org/t/pgraphics-and-main-window-nice-code-possible/11898)

<div class="topic-metadata">

**Author:** [@toby](https://discourse.processing.org/u/toby)\
**Replies:** 4\
**Last updated:** [June 7, 2019, 5:22pm UTC](https://discourse.processing.org/t/pgraphics-and-main-window-nice-code-possible/11898 "2019-06-07T17:22:59Z")

</div>

Hello Processing friends. I wonder if anyone could help please. I have a sketch that renders stuff in a small main window, and when ready renders it at hi-res to a PGraphics which is then saved to a file. My code is ugly…

---

## [Flow Field, trying to paint with Kinect](https://discourse.processing.org/t/flow-field-trying-to-paint-with-kinect/11816)

<div class="topic-metadata">

**Author:** [@josipaca](https://discourse.processing.org/u/josipaca)\
**Replies:** 2\
**Last updated:** [June 7, 2019, 3:55pm UTC](https://discourse.processing.org/t/flow-field-trying-to-paint-with-kinect/11816 "2019-06-07T15:55:46Z")

</div>

Hey I’m quite new to Processing and trying to make like a force to the Lerped position from the Kinect, kind of like a mouse. So if the Lerped position shows the field drags to it like a magnet. I can figure it out and …

---

## [Exporting with pgraphics and nullpointerexception](https://discourse.processing.org/t/exporting-with-pgraphics-and-nullpointerexception/11828)

<div class="topic-metadata">

**Author:** [@karinalopez87](https://discourse.processing.org/u/karinalopez87)\
**Replies:** 2\
**Last updated:** [June 7, 2019, 3:34pm UTC](https://discourse.processing.org/t/exporting-with-pgraphics-and-nullpointerexception/11828 "2019-06-07T15:34:32Z")

</div>

Hello, so I’ve run into two problems. The first being that after a few hours (which varies depending on the machine that I’m running my code on), gives me a NullPointerException error, usually targeting filter shaders or…

---

## [\[SOLVED\] Framebuffer objects are not supported by this hardware](https://discourse.processing.org/t/solved-framebuffer-objects-are-not-supported-by-this-hardware/11896)

<div class="topic-metadata">

**Author:** [@noel](https://discourse.processing.org/u/noel)\
**Replies:** 1\
**Last updated:** [June 7, 2019, 2:24pm UTC](https://discourse.processing.org/t/solved-framebuffer-objects-are-not-supported-by-this-hardware/11896 "2019-06-07T14:24:30Z")

</div>

Hi. I have two HD´s installed on my PC. One runs Linux Ubuntu, and the other windows 10 running Processing perfectly. Now I installed a third sata SDD. It has only 32G so I installed windows 7 and it runs incredibly f…

---

## [Change in color scheme](https://discourse.processing.org/t/change-in-color-scheme/11895)

<div class="topic-metadata">

**Author:** [@beatrizt](https://discourse.processing.org/u/beatrizt)\
**Replies:** 11\
**Last updated:** [June 7, 2019, 2:14pm UTC](https://discourse.processing.org/t/change-in-color-scheme/11895 "2019-06-07T14:14:02Z")

</div>

Hello, can somebody please tell me what I am doing wrong?? Basically what I want is when the mouse is over the area of the square, I want the colors of both the squares and the ellipses to shift. At first, the squares …

---

## [Hi, this is a bug? 3D Game Engine](https://discourse.processing.org/t/hi-this-is-a-bug-3d-game-engine/11800)

<div class="topic-metadata">

**Author:** [@erkosone](https://discourse.processing.org/u/erkosone)\
**Replies:** 6\
**Last updated:** [June 7, 2019, 2:09pm UTC](https://discourse.processing.org/t/hi-this-is-a-bug-3d-game-engine/11800 "2019-06-07T14:09:27Z")

</div>

Hello community, I am developing a game engine with processing, what a good idea! There is no complete one so far! The problem starts when using a buffer with createGraphics () called “blitter”. Transparencies are not …

---

## [Rollover with animation](https://discourse.processing.org/t/rollover-with-animation/11890)

<div class="topic-metadata">

**Author:** [@beatrizt](https://discourse.processing.org/u/beatrizt)\
**Replies:** 7\
**Last updated:** [June 7, 2019, 2:04pm UTC](https://discourse.processing.org/t/rollover-with-animation/11890 "2019-06-07T14:04:31Z")

</div>

Hey, can someone please tell me what I am doing wrong here: int radius=0; int length= 720; float colorscheme1; float colorscheme2; float mouseX; float mouseY; boolean rectIsShrinking = true; boolean circleIsShrin…

---

## [2D Image DIsplacement](https://discourse.processing.org/t/2d-image-displacement/11894)

<div class="topic-metadata">

**Author:** [@anon57009815](https://discourse.processing.org/u/anon57009815)\
**Replies:** 3\
**Last updated:** [June 7, 2019, 11:42am UTC](https://discourse.processing.org/t/2d-image-displacement/11894 "2019-06-07T11:42:28Z")

</div>

Hello and good day, I’d like to know if anyone has a reference on some GLSL shader to do things like this (images from amazing works of Kurokawa and Julien Bayle)

---

## [Making a 3D table](https://discourse.processing.org/t/making-a-3d-table/11724)

<div class="topic-metadata">

**Author:** [@ctrembla](https://discourse.processing.org/u/ctrembla)\
**Replies:** 41\
**Last updated:** [June 7, 2019, 1:34am UTC](https://discourse.processing.org/t/making-a-3d-table/11724 "2019-06-07T01:34:59Z")

</div>

OK, I’m trying to make a 3D game starting with a table, but when I hit play to see the 2 legs of the table I only see one. Can someone explain what I do? here what I got so far. void setup(){ size(600,600,P3D); } vo…

---

## [ControlP5 Buttons Performace issue](https://discourse.processing.org/t/controlp5-buttons-performace-issue/11888)

<div class="topic-metadata">

**Author:** [@InferNova](https://discourse.processing.org/u/InferNova)\
**Replies:** 4\
**Last updated:** [June 7, 2019, 3:24am UTC](https://discourse.processing.org/t/controlp5-buttons-performace-issue/11888 "2019-06-07T03:24:14Z")

</div>

Hey Guys! I have an issue when having a ControlP5 button showcased and when clicked it hides. This works fine but then I have a game in the background and the FPS drops drastically, note that without the button the issu…

---

## [Orthographic path traveling](https://discourse.processing.org/t/orthographic-path-traveling/11786)

<div class="topic-metadata">

**Author:** [@8BitRift](https://discourse.processing.org/u/8BitRift)\
**Replies:** 2\
**Last updated:** [June 6, 2019, 9:26pm UTC](https://discourse.processing.org/t/orthographic-path-traveling/11786 "2019-06-06T21:26:15Z")

</div>

So I am trying to use the camera function and the orthographic view to travel down a path I have managed to get it to work with perspective but I cant get it to work properly with the orthographic view. Below is the code…

---

## [More and Faster: glInterleavedArrays glDrawArrays](https://discourse.processing.org/t/more-and-faster-glinterleavedarrays-gldrawarrays/5044)

<div class="topic-metadata">

**Author:** [@TPMoyer](https://discourse.processing.org/u/TPMoyer)\
**Replies:** 5\
**Last updated:** [June 6, 2019, 1:33pm UTC](https://discourse.processing.org/t/more-and-faster-glinterleavedarrays-gldrawarrays/5044 "2019-06-06T13:33:35Z")

</div>

Anyone have pointers as to how I might move toward being able to use the array functions from openGL (glInterleavedArrays and glDrawArrays) within processing? Am ok if this involves my needing to develop a library. …

---

## [Buttons with same coordinates are clicked twice](https://discourse.processing.org/t/buttons-with-same-coordinates-are-clicked-twice/11877)

<div class="topic-metadata">

**Author:** [@rory](https://discourse.processing.org/u/rory)\
**Replies:** 4\
**Last updated:** [June 6, 2019, 11:54am UTC](https://discourse.processing.org/t/buttons-with-same-coordinates-are-clicked-twice/11877 "2019-06-06T11:54:08Z")

</div>

A beginner’s question with buttons. I’m trying to make a program which contains different pages such as splashscreen, main menu, etc. The first page splashScreen() asks the user click anywhere to continue, and then goes …

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

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