Skip to content

Conversation

maxandersen
Copy link

fixes #14

makes this not print stacktraces of null urls ;P

// DEPS com.github.micycle1:processing-core-4:4.4.4
//DEPS org.processing:core:4.4.4

//JAVA 25+
//REPOS central,jitpack
//RUNTIME_OPTIONS --enable-native-access=ALL-UNNAMED

import processing.core.PApplet;
public class RuntimeTest extends PApplet {

	public static void main(String[] args) {
		PApplet.main(RuntimeTest.class);
	}

	/**
 * Storing Input. 
 * 
 * Move the mouse across the screen to change the position
 * of the circles. The positions of the mouse are recorded
 * into an array and played back every frame. Between each
 * frame, the newest value are added to the end of each array
 * and the oldest value is deleted. 
 */
 
int num = 60;
float mx[] = new float[num];
float my[] = new float[num];

public void settings() {
	size(640, 360);
}

public void setup() {
  noStroke();
  fill(255, 153); 
}

public void draw() {
  background(51); 
  
  // Cycle through the array, using a different entry on each frame. 
  // Using modulo (%) like this is faster than moving all the values over.
  int which = frameCount % num;
  mx[which] = mouseX;
  my[which] = mouseY;
  
  for (int i = 0; i < num; i++) {
    // which+1 is the smallest (the oldest in the array)
    int index = (which+1 + i) % num;
    ellipse(mx[index], my[index], i, i);
  }
}

}

@micycle1
Copy link
Owner

Would these be clearer?

**/processing/core/font/*
**/processing/core/icon/*

@maxandersen
Copy link
Author

I also now realizing processing core actually exists in maven central so I have less need for jitpack version - but feel free to include it as atm the jars this or create works :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

why exclude font and png?
2 participants