Why FloatBuffer instead of float[]?
The main reason is performance: ByteBuffers and the other NIO classes enable accelerated operations when interfacing with native code (typically by avoiding the need to copy data into a temporary buffer). This is pretty important if you are doing a lot of OpenGL rendering calls for example. The reason for creating a ByteBuffer first is … Read more