I am attempting to scale my entire sketch based on the width and height of the corresponding sketch's canvas and it seems like it should be straight-forward; I calculate the XY scale and return the value as a float. I can print this value with a println, but as soon as I attempt to scale using this value (or
any value, to be exact), I receive the following JavaScript error:
Uncaught TypeError: number is not a function
I'd love to know what I am doing wrong.
This is a small snippet of my
draw function:
void draw(){
scale((float)getScaleXY(1024)); // TypeError!
scale(1.2); // TypeError!
// Display current mouse over information in the status area of raster
printStatus();
// Fetches and displays data
sample(min,max);
}
// I have a jQuery method that calls procesingInstance.scaleSketch(), which has the same issue