euglena/src/protoClear.java

20 lines
841 B
Java
Raw Normal View History

2016-07-10 00:36:44 -07:00
/* ____ The area of interest is outlined is in blue and
-> / a triangle is used as border to make sure euglena
\____ are cleared out. The top coordinates of the top right
x and y and width and height can be passed as parameters
*/
void protoClear(float x, float y, float screenWidth, float screenHeight) {
noFill();
stroke(color(0, 0, 220));
strokeWeight(5);
beginShape();
vertex(convertXCoord(x + screenWidth), convertYCoord(y));
vertex(convertXCoord(x), convertYCoord(y));
vertex(convertXCoord(x - menu.width), convertYCoord((y + y + screenHeight)/2));
vertex(convertXCoord(x), convertYCoord(y + screenHeight));
vertex(convertXCoord(x + screenWidth), convertYCoord(y + screenHeight));
endShape();
arduino.digitalWrite(left, Arduino.HIGH);
}