In pixelPtr.put(pixel.getI(), pixel.getJ()), the overloaded method FloatPointer.put(long, float) is unintentionally called, whereas we want to call FloatPointer.put(float...).
This is because overloading resolution prioritize variable arity methods less.
To fix this, the code is fixed to call FloatPointer.put(long, float) explicitly for each index.
In
pixelPtr.put(pixel.getI(), pixel.getJ())
, the overloaded methodFloatPointer.put(long, float)
is unintentionally called, whereas we want to callFloatPointer.put(float...)
. This is because overloading resolution prioritize variable arity methods less. To fix this, the code is fixed to callFloatPointer.put(long, float)
explicitly for each index.