Android IntBuffer Create newIntBuffer(int numInts)

Here you can find the source of newIntBuffer(int numInts)

Description

new Int Buffer

Declaration

public static IntBuffer newIntBuffer(int numInts) 

Method Source Code

//package com.java2s;

import java.nio.ByteBuffer;
import java.nio.ByteOrder;

import java.nio.IntBuffer;

public class Main {
    public static IntBuffer newIntBuffer(int numInts) {
        ByteBuffer buffer = ByteBuffer.allocateDirect(numInts * 4);
        buffer.order(ByteOrder.nativeOrder());
        return buffer.asIntBuffer();
    }/*from   www . jav  a2s.  co m*/
}

Related

  1. createIntBuffer(int[] data)
  2. getIntegerBuffer(int[] list)
  3. makeIntBuffer(int size)
  4. makeIntBuffer(int[] arr)
  5. newIntBuffer(int numInts)
  6. newIntBuffer(int paramInt)
  7. setupIntBuffer(IntBuffer preBuffer, int[] array)
  8. toIntBuffer(int[] array)
  9. createDirectIntBuffer(final int capacity)