Update #52 - Fixed various issues with the client

This commit is contained in:
lax1dude
2025-06-15 21:43:43 -07:00
parent 325a6826bf
commit f3281c037f
94 changed files with 882 additions and 506 deletions

View File

@ -125,7 +125,7 @@ public class EaglerLWJGLFloatBuffer extends FloatBuffer {
@Override
public FloatBuffer get(float[] dst, int offset, int length) {
if(position + length > limit) throw Buffer.makeIOOBE(position + length - 1);
UnsafeMemcpy.memcpyAlignDst(dst, offset << SHIFT, address + (position << SHIFT), length);
UnsafeMemcpy.memcpyAlignDst(dst, offset, address + (position << SHIFT), length);
position += length;
return this;
}
@ -161,7 +161,7 @@ public class EaglerLWJGLFloatBuffer extends FloatBuffer {
@Override
public FloatBuffer put(float[] src, int offset, int length) {
if(position + length > limit) throw Buffer.makeIOOBE(position + length - 1);
UnsafeMemcpy.memcpyAlignSrc(address + (position << SHIFT), src, offset << SHIFT, length);
UnsafeMemcpy.memcpyAlignSrc(address + (position << SHIFT), src, offset, length);
position += length;
return this;
}

View File

@ -125,7 +125,7 @@ public class EaglerLWJGLIntBuffer extends IntBuffer {
@Override
public IntBuffer get(int[] dst, int offset, int length) {
if(position + length > limit) throw Buffer.makeIOOBE(position + length - 1);
UnsafeMemcpy.memcpyAlignDst(dst, offset << SHIFT, address + (position << SHIFT), length);
UnsafeMemcpy.memcpyAlignDst(dst, offset, address + (position << SHIFT), length);
position += length;
return this;
}
@ -161,7 +161,7 @@ public class EaglerLWJGLIntBuffer extends IntBuffer {
@Override
public IntBuffer put(int[] src, int offset, int length) {
if(position + length > limit) throw Buffer.makeIOOBE(position + length - 1);
UnsafeMemcpy.memcpyAlignSrc(address + (position << SHIFT), src, offset << SHIFT, length);
UnsafeMemcpy.memcpyAlignSrc(address + (position << SHIFT), src, offset, length);
position += length;
return this;
}

View File

@ -125,7 +125,7 @@ public class EaglerLWJGLShortBuffer extends ShortBuffer {
@Override
public ShortBuffer get(short[] dst, int offset, int length) {
if(position + length > limit) throw Buffer.makeIOOBE(position + length - 1);
UnsafeMemcpy.memcpyAlignDst(dst, offset << SHIFT, address + (position << SHIFT), length);
UnsafeMemcpy.memcpyAlignDst(dst, offset, address + (position << SHIFT), length);
position += length;
return this;
}
@ -161,7 +161,7 @@ public class EaglerLWJGLShortBuffer extends ShortBuffer {
@Override
public ShortBuffer put(short[] src, int offset, int length) {
if(position + length > limit) throw Buffer.makeIOOBE(position + length - 1);
UnsafeMemcpy.memcpyAlignSrc(address + (position << SHIFT), src, offset << SHIFT, length);
UnsafeMemcpy.memcpyAlignSrc(address + (position << SHIFT), src, offset, length);
position += length;
return this;
}