javae_logo_small
void addPX(int, float);

Function:
Adds data to the current X position of the defined layer.

Send:
Layer number (int). Additional X position data (float).

Returns:
Nothing

example:

void draw(){
background(myComp.getBG());
myComp.drawLayer(2);
//change position of Layer 2 by moving the mouse
distX = mouseX-pmouseX;
distY = mouseY-pmouseY;
moreX=(moreX+distX);
moreY=(moreY+distY);
//Add mouse position data to layer 2
myComp.addPX(2, moreX);
myComp.addPY(2, moreY);
}