LWJGL (Light Weight Java Game Library), a set of Java bindings for several low level libraries ( Open GL, ES, Vulkan, OpenCL, GLFW, etc. ) just released version 3.0.0 after 3 years in development. This is the underlying technology used by LibGDX for desktop support for example. This release brings several changes, including:
- Added support for Java array parameters and HotSpot Critical Natives. (#175)
- Added Vulkanl bindings. (#50)
- Added NanoVG bindings. (#99)
- Added NativeFileDialog bindings.
- Added par_shapes.h bindings.
- Added dyncall bindings.
- Added jawt bindings for AWT/Swing integration. (#125)
- Added simple OS-specific window creation bindings, for custom window/context creation. (#105)
- Added missing OpenCL and OpenAL extensions.
- Fully documented OpenCL and OpenAL.
- Moved WGL and GLX capabilities to the new
GLXCapabilitiesclasses, respectively. Functionality in WGL, GLX and corresponding extensions that does not require a current context can now be used without creating a dummy context first. (#171)
- Added stack allocation APIs (the
MemoryStackclass and new allocation methods in struct classes and
- Made the implementations of
Struct/StructBuffersubclasses as lightweight as possible. This makes it easier for escape analysis to eliminate allocations.
- Minor struct API improvements.
- Added nullability information to struct members, to protect against buggy code crashing the JVM.
- All bindings are updated to the latest versions of the corresponding libraries. Notably, GLFW now has
glfwSetWindowMonitor, it now doesn’t lack anything compared to LWJGL 2’s Display.
- Refactored callbacks for Java 8. (#182)
NativeResourceinterface and made freeable objects usable as resources in try-with-resources statements. (#186)
- Faster thread-local lookups for the stack and current capabilities. New options in Configuration can be used tocomplete eliminate thread-local lookup in OpenGL, OpenGL ES and OpenAL, when it is known that only a single context will be used, or that all contexts will be compatible (same capabilities and same function pointers).
memSlicefor all buffers types in
- Refactored the
Configurationclass for type safety and added more options.
- JDK 9 can now be used to build and run LWJGL.
- Javadoc is now generated with JDK 9. The API is fully indexed and search functionality is available. Also made multiple Javadoc formatting improvements.
- Improved debug diagnostics on startup and when loading the LWJGL shared library fails.
memCopyfor small buffers.
- Stopped using UPX compression for binaries. This eliminates various integration issues and virus scanning false-positives.
SharedLibraryLoadernow works with any shared library, not only libraries LWJGL knows about. (#176)
- LWJGL now requires Java 8 to build and run. Certain custom interfaces have been replaced with
- Dropped support for Linux x86. (#162)
- Dropped libffi bindings.
ALDevice/ALContextwrappers from OpenAL and
CLPlatform/CLDevicewrappers from OpenCL. (#152)
- Dropped the
getInstance()method from bindings loaded from shared libraries. Function pointers are now stored either in capabilities classes or in a nested Functions inner class.
- Dropped infrequently used method overloads in bindings. Full javadoc is now generated on (almost) all overloads.
- Dropped utility classes that were not useful.
- Added AutoSize support to struct members. Instance setters for the corresponding count/size members were removed to avoid bugs and confusion.
ALIGNOFin struct classes.
FunctionProvidersubclasses are now destroyed using
- Moved xxHash and SSE bindings to the
- Integer-boolean native types (0 or 1 are the only legal values) are now mapped to Java booleans. (#181)
- Macros without parameters are now generated as static final values, not methods.
You can read more about the release here.