Subscribe to GameFromScratch on YouTube Support GameFromScratch on Patreon

6. June 2016


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 WGLCapabilities and GLXCapabilities classes, 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 MemoryStack class and new allocation methods in struct classes and MemoryUtil).
  • Made the implementations of PointerBuffer and Struct/StructBuffer subclasses 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 hasglfwSetWindowIcon and glfwSetWindowMonitor, it now doesn't lack anything compared to LWJGL 2's Display.
  • Refactored callbacks for Java 8. (#182)
  • Added NativeResource interface 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).
  • Added memSlice for all buffers types in MemoryUtil. (#179)
  • Refactored the Configuration class 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.
  • Optimized memSet and memCopy for small buffers.


  • Stopped using UPX compression for binaries. This eliminates various integration issues and virus scanning false-positives.
  • The SharedLibraryLoader now 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 java.util.functioninterfaces. (#177)
  • Dropped support for Linux x86. (#162)
  • Dropped libffi bindings.
  • Dropped ALDevice/ALContext wrappers from OpenAL and CLPlatform/CLDevice wrappers 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.
  • Replaced MemoryUtil.memFree(StructBuffer) with
  • Renamed __ALIGNMENT to ALIGNOF in struct classes.
  • Removed org.lwjgl.system.Retainable interface. Closure and FunctionProvider subclasses are now destroyed instead of .release().
  • Moved xxHash and SSE bindings to the org.lwjgl.util package.
  • 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.

GameDev News ,

6. June 2016


The following is a recap of major events in the world of game development for the week ending June 5th, 2016.  I do a weekly video recapping the news available here with this week’s video embedded below.  This post is a collection of links mentioned in the recap.


The Video

GameDev News

2. June 2016


Substance Painter is an extremely popular PBR (Physically Based Renderer) texturing tool, now integrated into just about every single modern game engine.  They just released Substance Painter 2.1 with a host of new features including:

  • Linux Support
  • Support for 4K displays
  • Support for 8K texture map export
  • ability to import UDIM based assets

Plus several smaller additions and changes including:


- [UDIM] Import UDIM Tiles from a mesh as Texture Sets

- [Linux] Added support for CentOS 6.6 and Ubuntu 12.4

- [Export] Add 8K resolution (experimental)

- [Export] Allow to choose the bit depth during the export

- [Baker] Allow to bake multiple texture sets at once

- Support high resolution monitors (High DPI scaling)

- [Scripting] Set custom resolution and padding per texture at export

- [Viewport] Allow to switch between texture set by clicking on the mesh (via Ctrl+Alt+Click)

- [Viewport] Go where the mouse cursor is when zooming with the mouse wheel

- [UI] Update default background color and environment map display

- [UI] Add tooltips with original names for User channels

- [UI] Change background color for channels that can't be renamed

- [Tool] Remove checkers when using the quick mask

- [Shader] Allow to define groups for shader parameters and materials/masks

- [Engine] Optimization of small size stamping

- [Stencil] Add "W" as shortcut to temporarily toggle the mask

- [Shelf] Add a cross button to clear the search field

- [Shelf] Load Alpha with a single click

- [Shelf] New export preset : Vray UDIM, Arnold UDIM, Spec/Gloss from Metal/Rough

- [Shelf] New alphas : geometric shapes, veins and signs

- Add name and version in the properties of Substance Painter executable


- [Substance] Impossible to use the normal channel and additional map at the same time

- [Iray] MDL refraction and absorption setting don't work

- [Iray] Original scene scale is not preserved

- [Shelf] Specular/Glossiness template use an incorrect shader

- [Export] Default export preset doesn't export some maps (like AO)

- [Viewport] Pivot point doesn't update when clicking outside the UVs in the 2D View

- [UI] Slider values are rounded

- [UI] Sometimes when editing sliders values there is a very small free space

- [New Project] Template dropdown list is not correctly updated (from 1.x to 2.x)

- [Scripting] Fixed "hover" behavior on custom buttons

- [Mac] Undoing on an empty project locks the camera

Known Issues:

- Crash report is not available on Ubuntu


You can see a walkthrough of new features in this video:


You can read more about the release here.

GameDev News

2. June 2016


GLFW, a library providing cross platform window and input handling functionality for OpenGL, OpenGL ES and now Vulkan applications, just released version 3.2.  The aforementioned Vulkan support is probably the biggest new feature in this release, however this release contains several new features.

From the complete change log:

  • Added glfwVulkanSupported, glfwGetRequiredInstanceExtensions, glfwGetInstanceProcAddress,glfwGetPhysicalDevicePresentationSupport and glfwCreateWindowSurface for platform independent Vulkan support
  • Added glfwSetWindowMonitor for switching between windowed and full screen modes and updating the monitor and desired video mode of full screen windows
  • Added glfwMaximizeWindow and GLFW_MAXIMIZED for window maximization
  • Added glfwFocusWindow for giving windows input focus
  • Added glfwSetWindowSizeLimits and glfwSetWindowAspectRatio for setting absolute and relative window size limits
  • Added glfwGetKeyName for querying the layout-specific name of printable keys
  • Added glfwWaitEventsTimeout for waiting for events for a set amount of time
  • Added glfwSetWindowIcon for setting the icon of a window
  • Added glfwGetTimerValue and glfwGetTimerFrequency for raw timer access
  • Added glfwSetJoystickCallback and GLFWjoystickfun for joystick connection and disconnection events
  • Added GLFW_NO_API for creating window without contexts
  • Added GLFW_INCLUDE_VULKAN for including the Vulkan header
  • Added GLFW_CONTEXT_CREATION_API, GLFW_NATIVE_CONTEXT_API and GLFW_EGL_CONTEXT_API for run-time context creation API selection
  • Added GLFW_CONTEXT_NO_ERROR context hint for GL_KHR_no_error support
  • Added GLFW_TRUE and GLFW_FALSE as client API independent boolean values
  • Added icons to examples on Windows and OS X
  • Relaxed rules for native access header macros
  • Removed dependency on external OpenGL or OpenGL ES headers
  • [Win32] Added support for Windows 8.1 per-monitor DPI
  • [Win32] Replaced winmm with XInput and DirectInput for joystick input
  • [Win32] Bugfix: Window creation would segfault if video mode setting required the system to be restarted
  • [Win32] Bugfix: MinGW import library lacked the lib prefix
  • [Win32] Bugfix: Monitor connection and disconnection events were not reported when no windows existed
  • [Win32] Bugfix: Activating or deactivating displays in software did not trigger monitor callback
  • [Win32] Bugfix: No monitors were listed on headless and VMware guest systems
  • [Win32] Bugfix: Pressing Ctrl+Pause would report GLFW_KEY_UNKNOWN
  • [Win32] Bugfix: Window size events would be reported in wrong order when restoring a full screen window
  • [Cocoa] Made joystick polling more efficient
  • [Cocoa] Removed support for OS X 10.6
  • [Cocoa] Bugfix: Full screen windows on secondary monitors were mispositioned
  • [Cocoa] Bugfix: Connecting a joystick that reports no name would segfault
  • [Cocoa] Bugfix: Modifier flags cache was not updated when window became key
  • [Cocoa] Bugfix: Dead key character composition did not work
  • [Cocoa] Bugfix: The CGL context was not released until the autorelease pool was drained by another function
  • [X11] Bugfix: Monitor connection and disconnection events were not reported
  • [X11] Bugfix: Decoding of UTF-8 text from XIM could continue past the end
  • [X11] Bugfix: An XKB structure was leaked during glfwInit
  • [X11] Bugfix: XInput2 XI_Motion events interfered with the Steam overlay
  • [POSIX] Bugfix: An unrelated TLS key could be deleted by glfwTerminate
  • [Linux] Made joystick polling more efficient
  • [WGL] Changed extension loading to only be performed once
  • [WGL] Removed dependency on external WGL headers
  • [GLX] Added glfwGetGLXWindow to query the GLXWindow of a window
  • [GLX] Replaced legacy drawable with GLXWindow
  • [GLX] Removed dependency on external GLX headers
  • [GLX] Bugfix: NetBSD does not provide
  • [EGL] Added _GLFW_USE_EGLPLATFORM_H configuration macro for controlling whether to use an existing EGL/eglplatform.hheader
  • [EGL] Added and documented test for if the context is current on the calling thread during buffer swap
  • [EGL] Removed dependency on external EGL headers

GameDev News

2. June 2016


Leadwerks just released Leadwerks 4.1 beta.  Leadwerks is a game engine that claims to be the easiest way to build 3D games.  It is loaded with tutorials and samples to help get a user started and ships with a full editor, lua programming environment and more.  The 4.1 beta is currently available on Steam.


The 4.1 beta release brings several new features:

4.1 adds environment probes, which have been covered previously, and volumetric lighting.  Point and spot lights can display a volumetric effect by adjusting the "Volume strength" setting, found under Light properties in the editor.  You can also use the new commands Light::SetVolumetricStrength() and Light::GetVolumetricStrength().  At this time, directional lights should use the godray shader instead, but I might try this effect on directional lights as well before the release.
Volumetric lighting is an expensive effect to render, but my Intel 5200 is running it at a fast speed, and high-end cards should have no problem with it.  Lights with a large range are more expensive than lights with a small range.  The performance will be exactly the same for any intensity level above zero (the default).  The effect is disabled when the low-quality light setting is in use.

Volumetric lighting looks best in dark scenes with lots of contrast.  Spotlights tend to look a little better, as point lights don't have the same well-defined shape.  Use these sparingly for dramatic lighting effects in key positions.  It looks especially nice when you have a fence or grate in front of the light to create lots of interesting light beams.

The bloom effect has also been improved, and SSAO, godrays, and iris adjustment post-processing effects have been added.  The bloom effect is using the mixing equation from Leadwerks 2, along with an improved Gaussian blur function from the RasterGrid blog.


Leadwerks is available here on Steam.

GameDev News

Month List

Popular Comments