Code example for ShortBuffer

Methods: clear, position, put

0
 
    // 
    // Blit faces data in garbage memory into direct memory heap (buffers)... 
    // 
    private void fillFaces() { 
        faces_buffer.clear();
        faces_buffer.put(faces);
        faces_buffer.position(0);
    } 
 
    // 
    // Blit colors data in garbage memory into direct memory heap (buffers)... 
    // 
    private void fillColors() { 
        colors_buffer.clear();
        colors_buffer.put(colors);
        colors_buffer.position(0);
    } 
 
    // 
    // Blit colors data in garbage memory into direct memory heap (buffers)...