Code example for LongBuffer

Methods: get, put

0
		IntBuffer ibuffer = buffer.asIntBuffer();
		ibuffer.put(0, 0x13456789);
		System.out.println((short)ibuffer.get(0));
		 
		LongBuffer lbuffer = buffer.asLongBuffer();
		lbuffer.put(0, 0x123456789abcdef0l);
		System.out.println(lbuffer.get(0));
		 
		FloatBuffer fbuffer = buffer.asFloatBuffer();
		fbuffer.put(0, 123.789123f);
		System.out.println(fbuffer.get(0));
		System.out.println(fbuffer.get(0) == 123.789123f);
		 
		DoubleBuffer dbuffer = buffer.asDoubleBuffer();
		dbuffer.put(0, 123.789123f);
		System.out.println(dbuffer.get(0));
		System.out.println(dbuffer.get(0) == 123.789123f);
  } 
 
  public void draw(int x, int y, int width, int height) {
    drawText(peer, "Hello, World!", 10, 20, 24.0);