Programming => Lightweight Java Gaming Library => Topic started by: spasi on November 19, 2017, 23:59:44

Title: LWJGL 3.1.5
Post by: spasi on November 19, 2017, 23:59:44
LWJGL 3.1.5 has been released!

edit: This post was originally about 3.1.4. The build published to Maven Central was incompatible with Java 8, so it had to be replaced quickly with a new version.

3.1.5 release notes (https://github.com/LWJGL/lwjgl3/blob/master/doc/notes/3.1.5.md)
3.1.4 release notes (https://github.com/LWJGL/lwjgl3/blob/master/doc/notes/3.1.4.md)
Download (https://www.lwjgl.org/download)

You can now contribute to LWJGL by becoming a backer on Open Collective (https://opencollective.com/lwjgl) with a monthly/yearly/one-time donation to the project. The plan is to use donated funds:
Finally, don't forget to check out the lovely path tracing tutorials (https://github.com/LWJGL/lwjgl3-demos/tree/master/src/org/lwjgl/demo/opengl/raytracing/tutorial) created by KaiHH (https://github.com/httpdigest)!
Title: Re: LWJGL 3.1.4
Post by: mudlee on November 20, 2017, 16:11:58

I get an error if I switch from 3.1.3:
Code: [Select]
java.lang.NoSuchMethodError: java.nio.ByteBuffer.limit(I)Ljava/nio/ByteBuffer;
at org.lwjgl.system.MemoryAccess$MemoryAccessorUnsafe.getCapacityOffset(MemoryAccess.java:159)
at org.lwjgl.system.MemoryAccess$MemoryAccessorUnsafe.<clinit>(MemoryAccess.java:132)
at org.lwjgl.system.MemoryAccess.getInstance(MemoryAccess.java:31)
at org.lwjgl.system.MemoryUtil.<clinit>(MemoryUtil.java:62)
at org.lwjgl.system.MemoryStack.<init>(MemoryStack.java:60)
at org.lwjgl.system.MemoryStack.create(MemoryStack.java:81)
at org.lwjgl.system.MemoryStack.create(MemoryStack.java:70)
at java.lang.ThreadLocal$SuppliedThreadLocal.initialValue(ThreadLocal.java:284)
at java.lang.ThreadLocal.setInitialValue(ThreadLocal.java:180)
at java.lang.ThreadLocal.get(ThreadLocal.java:170)
at org.lwjgl.system.MemoryStack.stackGet(MemoryStack.java:603)
at org.lwjgl.system.MemoryStack.stackPush(MemoryStack.java:612)
at org.lwjgl.system.Callback.<clinit>(Callback.java:38)
at com.intermetto.engine.window.Window.onStart(Window.java:89)
at java.util.ArrayList.forEach(ArrayList.java:1249)
at com.intermetto.engine.core.Engine.run(Engine.java:83)
at java.lang.Thread.run(Thread.java:748)
[LWJGL] [MemoryAccessor] Unsupported JVM detected, this will likely result in low performance. Please inform LWJGL developers.

I use CentOS7 and Java:
Code: [Select]
java version "1.8.0_144"
Java(TM) SE Runtime Environment (build 1.8.0_144-b01)
Java HotSpot(TM) 64-Bit Server VM (build 25.144-b01, mixed mode)

The error occurs, when I call:
Code: [Select]
Despite this error, everything works fine.
Title: Re: LWJGL 3.1.4
Post by: spasi on November 20, 2017, 18:21:37
The 3.1.4 build on Maven is bugged, it has been compiled with Java 9. The bytecode version is fine (JDK8), but JDK 9 introduced covariant returns (https://bugs.openjdk.java.net/browse/JDK-4774077) in certain NIO methods and that's the error you're seeing.

Workarounds: use Java 9, download 3.1.4-SNAPSHOT, download LWJGL from the website or github.

There will be a 3.1.5 release immediately (hopefully tonight or tomorrow morning).
Title: Re: LWJGL 3.1.5
Post by: spasi on November 22, 2017, 02:01:29
LWJGL 3.1.4 has been replaced by 3.1.5. It includes the AMD Tootle (https://github.com/GPUOpen-Tools/amd-tootle) bindings and some minor fixes.