What I want to do now is parse the svg/xml to look for overlapping points. That is, I want a function that knows the overlapping points and tallies them. A little guiding light would be helpful. I'm kind of wondering if I should parse the data directly as XML? and more to the point, how I would identify child elements that overlap, and where that happens.
This is my first Processing project, so please feel free to point out any additional inaccuracies in the code
.
This is the issue.
I've been able to draw a map using imported PShape SVG and grab children from it. I've been able to draw a UI element that cycles through a series of 'selected Days.' But I can't get the current selected day on the UI element to reflect a color change in the Map.
In her example she's importing a csv data sheet to control the size of her specific selected items on the map. I don't think i need to do that, because I'm only selecting the child SVG group and changing the color based on the corrosponding selected number in the UI method.
There are a few variable defined globally that aren't being used because there were part of my experiment in trying to change the sources sketch into my own....
else if (selDay < numCols-2) selDay = selDay+1; //when moving right don't go further than num years
}
else if (keyCode == LEFT){ //when moving left don't go further than first year
if (selDay == 1) selDay = numCols-2;
else if (selDay > 1) selDay = selDay -1;
}
}
void drawRef(){
//write the references information
noStroke();
textFont(font,12);
fill(100);
textAlign(LEFT);
text("Use Left and Right Arrow Keys to cycle through Days", 20, height-15);
textFont(font,10);
}
I was thinking about using an if statement in void draw, but don't really know what to include.
Thanks for any help you can give me. Very much appreciated. I'll be sure to post the sketch once I'm finished. This forum has already been a massive help.