edit without making copy or have to return
in
Programming Questions
•
1 year ago
is it possible to pass a array to a function and not have the function to copy the thing?
I know i can return the array like
val = test(val);
the problem is that it needs to work on 3 arrays and i only can return 1.
- float[] val;
- void setup() {
- test(val);
- // nullPointer!
- println(val.length);
- }
- void test(float[] values) {
- values = new float[100];
- println(values.length);
- }
1