public static void destroyDirectBuffer(Buffer toBeDestroyed) {
        if (!isDirect(toBeDestroyed)) {
            return;
        }
        allocator.destroyDirectBuffer(toBeDestroyed);
    }
Direct buffers are garbage collected by using a phantom reference and a
reference queue. Every once a while, the JVM checks the reference queue
and cleans the direct buffers. However, as this doesn't happen
immediately after discarding all references to a direct buffer, it's easy
to OutOfMemoryError yourself using direct buffers.

@param toBeDestroyed the buffer to de-allocate (not null)
jme3-core/src/main/java/com/jme3/util/BufferUtils.java