Questions tagged [processing]

Processing is an open source programming language and environment for people who want to create images, animations, interactions, and games.

The processing tag is misleading and leads to misunderstandings and even closure votes, because of the seemingly missing language tag. It is strongly recommended to tag questions additionally with a language tag.

But note Processing is not the same as Java.

Processing refers to the language built on top of Java and the minimal IDE it ships with. It is free and open-source, runs on Linux, Mac OS X, and Windows, and can output for screens, print, 3D packages and CNC printing.

The language simplifies a lot of complex concepts and eases the entry of designers, artists and non-programmers to the world of programming.

Over the years it was used to produce a number of astonishing projects ranging from data visualization, to physical computing , games, 3D, sound, live performance, and more.

Due to its vibrant community, Processing not only enjoys a contribution of over 100 libraries, but it is also present on major mobile platforms, such as Android and iOS.

There are online communities for sharing Processing content, like OpenProcessing.

Some websites even allow users to learn and use Processing directly in the browser, like the Flash-driven SketchPatch and the JavaScript-driven Sketchpad and p5.js (pure JavaScript).

There are also Processing ports to the following languages:

Advanced users are not constrained to the Processing IDE; sketches can be run from the command line, and projects can be set up to build and run directly from editors:

6836 questions
1
vote
1 answer

Calling a String in Processing

I'm new to processing/java/code but was hoping for some help with my sketch. I am trying to create an ink-looking sketch, with letters/characters displayed, then faded out instead of particles themselves. Inspired by…
1
vote
1 answer

Trying to figure how to make a fan to Rotate in Processing

I'm completely new to Java Processing and I am trying to figure out a way to deign a fan which will rotate and increase the speed when press the plus(+) button and decrease when press the negative(-) button. As well as a way to display the speed…
1
vote
1 answer

what is the diference between one dimensional for loop and two dimensional for loop

could any one explain me the difference between one dimensional for loop and two dimensional for loop. and how could i change following one dimensional for loop to two dimensional for loop on the second snippet code. thank you i think following is…
march
  • 11
  • 4
1
vote
1 answer

Get selected index from 2d array grid in Processing

I want to create a peg solitaire game based on a 2d array in Processing. I've succeeded to create the board and pawns. Now i want to get the index from a pawn by clicking on it and be able to move it around the board. Here is what i have now to…
Denzel Obispo
  • 101
  • 1
  • 9
1
vote
0 answers

rotating Processing 3D object overlapped my ui object

void draw(){ //3Dmap scale = 1+scaleFactor; background(100); pushMatrix(); translate(width/2+transX, height/2.5+transY, 0); rotateX(rotX); rotateY(-rotY); scale(scale); imageMode(CENTER); image(nyc_map, 0, 0, mapSize, mapSize); …
Thian
  • 11
  • 1
1
vote
1 answer

Change variable in array coded with processing

Help! I'm drawing a sketch with randomized letters that fill the screen. The code issue is with my for (int i = 0; i < I1; i++) { targets = tX + i * ts; targets2 = tY; } else { runTowards = false; for (int i = 0; i < I1; i++) { targets =…
1
vote
1 answer

Isolate color of single character

I have a piece of code in p5.js that acts as a video filter: const density = ' .:░▒▓█' //const density = ' .tiITesgESG' //let geist; let video let asciiDiv let playing = false let button function preload() { video =…
ssarkar
  • 51
  • 7
1
vote
1 answer

Running Processing on Ubuntu : ./processing: 110: java: not found

I am trying to run processing on Ubuntu 22.04 LTS, as a basic tutorial program. When I run the program in the terminal, I get the following error message: ./processing: 110: java: not found I do not understand this error message. I obtained the…
1
vote
1 answer

Sieve of eratosthenes processing problem not drawing rectables in Processing

I am trying to create the Sieve of Eratosthenes problem where I print out a grid from 2 to 100 and then cover all non-prime numbers with a rectangle. I can only get it to check one divisor between 2 and 10. I cant get it to loop through all…
1
vote
1 answer

Is it possible to split a line as high as the whole screen (from 0 to height) in a line as high as half the screen in Processing?

I need some help with a code for an exam in my university. What I'm trying to do here is a visual representation of a speech between two people. So the code starts when you press "L" and then works a bit like walkie talkie so when the other person…
1
vote
1 answer

Processing Generative World

I'm trying to create a generative world with four randomly generated (location, size, colour) objects, each mouseClicked is supposed to regenerate those four objects in a random location, size, colour, etc. I have a method to draw the objects, now…
intEOF
  • 15
  • 3
1
vote
1 answer

Why does my printed staircase give a weird output instead of a regular staircase?

I'm kinda in a rush here so my problem here is this: You have to make a staircase with n lines and k stars, with k increasing k times each time. (Also add a period on each line to start with) The staircase should be right-situated like this: . * .…
1
vote
0 answers

Switching sprites after a set amount of time

so I have an object, and I want to make it so that whenever a projectile collides with that object, it gradually switches its sprites, and finally disappear. How can I do that? Here are my codes (sprites is a list of sprites that I need to set, and…
1
vote
1 answer

Programming falling Domino bricks with delay in Processing

I'm very new to Processing and coding in general and trying to program a row of falling Domino bricks activated by an ellipse. I have programmed a function for the bricks standing upright and one for the fallen bricks, but I can only get the bricks…
1
vote
1 answer

Collision detection between circles and rectangles knowing collision side

I have a "physics ball" that can bounce around the screen off the edges which works fine. But I wanted to be able to add boxes and have my ball be able to bounce of those, too. I have tried to create something and it feels like it is quite close,…
turke1034
  • 68
  • 1
  • 7