The list of methods to do ByteBuffer Flip are organized into topic(s).
void
flip(ByteBuffer bytes, int width, int height) flip
byte[] line = new byte[width];
byte[] line2 = new byte[width];
for (int i = 0; i < height / 2; i++) {
bytes.position(i * width);
bytes.get(line);
bytes.position((height - i - 1) * width);
bytes.get(line2);
bytes.position(i * width);
...
void
flip(ByteBuffer bytes, int width, int height) flip
byte[] line = new byte[width];
byte[] line2 = new byte[width];
for (int i = 0; i < height / 2; i++) {
bytes.position(i * width);
bytes.get(line);
bytes.position((height - i - 1) * width);
bytes.get(line2);
bytes.position(i * width);
...
void
flip(ByteBuffer[] buffers) flip
if (buffers == null) {
return;
for (ByteBuffer buffer : buffers) {
if (buffer != null) {
buffer.flip();
int
flipToFill(ByteBuffer buffer) Flip the buffer to fill mode.
int position = buffer.position();
int limit = buffer.limit();
if (position == limit) {
buffer.position(0);
buffer.limit(buffer.capacity());
return 0;
int capacity = buffer.capacity();
...