2 SVG in same processing problem
in
Programming Questions
•
1 year ago
Hey everyone!
I have a bit of a problem,
I have 2 sag's that i wish to put in the same processing file.
And when I try it doesn't work.
Any help?
I will provide both codes
1-----
PShape logo;
float angle;
float jitter;
void setup() {
size(800,250);
logo = loadShape("logo.svg");
smooth();
frameRate(50);
shapeMode(CENTER);
}
void draw() {
background(255,255,255);
// during even-numbered seconds (0, 2, 4, 6...)
if (millis() >= 7000){
jitter = 2.5;
}
angle = angle + jitter;
pushMatrix();
float c = cos(angle);
translate(width/6, height/2);
rotate(angle*TWO_PI/360);
shape(logo, 0, 0, 200, 200);
popMatrix();
}
2-----
PShape ID;
void setup() {
size(800,250);
ID = loadShape("ID.svg");
smooth();
frameRate(50);
shapeMode(RIGHT);
}
void draw() {
background(255,255,255);
translate(width/3.5, height/6);
shape(ID, 0, 0, 0, 0);
}
Thanks for any help!
1