controlp5 icon indicating copy to clipboard operation
controlp5 copied to clipboard

ControlP5 Slider examples not working.

Open nnuvo opened this issue 7 years ago • 2 comments

Processing 3.4, 2.2.5.

Slider2D example The function arrayValue() does not exist

Slider example "slider" can not be resolved to a variable

nnuvo avatar Dec 28 '18 21:12 nnuvo

Are you accessing the examples through the ControlP5 website (Slider2D, Slider)? I think the examples there are outdated!

Try looking at the examples on the reference page (click on the class and then click on the green "+Example" button), or on the GitHub page.

P.S. The fix to the first one is just to change arrayValue() to getArrayValue(). The slider example is working for me though.

kayserifserif avatar Aug 09 '19 17:08 kayserifserif

Hello, yes, sample still not updated:

float y0 = cos(map(i-1,0,s.getArrayValue()[0],-PI,PI)) * s.getArrayValue()[1]; float y1 = cos(map(i,0,s.getArrayValue()[0],-PI,PI)) * s.getArrayValue()[1];

LightMike avatar Sep 26 '20 09:09 LightMike