Class GLFWNativeOSMesa
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classContains the function pointers loaded fromGLFW.getLibrary(). -
Method Summary
Modifier and TypeMethodDescriptionstatic booleanglfwGetOSMesaColorBuffer(long window, int @Nullable [] width, int @Nullable [] height, int @Nullable [] format, @Nullable org.lwjgl.PointerBuffer buffer) Array version of:GetOSMesaColorBufferstatic booleanglfwGetOSMesaColorBuffer(long window, @Nullable IntBuffer width, @Nullable IntBuffer height, @Nullable IntBuffer format, @Nullable org.lwjgl.PointerBuffer buffer) Retrieves the color buffer associated with the specified window.static longglfwGetOSMesaContext(long window) Returns theOSMesaContextof the specified window.static intglfwGetOSMesaDepthBuffer(long window, int @Nullable [] width, int @Nullable [] height, int @Nullable [] bytesPerValue, @Nullable org.lwjgl.PointerBuffer buffer) Array version of:GetOSMesaDepthBufferstatic intglfwGetOSMesaDepthBuffer(long window, @Nullable IntBuffer width, @Nullable IntBuffer height, @Nullable IntBuffer bytesPerValue, @Nullable org.lwjgl.PointerBuffer buffer) Retrieves the depth buffer associated with the specified window.static intnglfwGetOSMesaColorBuffer(long window, long width, long height, long format, long buffer) Unsafe version of:GetOSMesaColorBufferstatic intnglfwGetOSMesaDepthBuffer(long window, long width, long height, long bytesPerValue, long buffer) Unsafe version of:GetOSMesaDepthBufferstatic voidOverrides the OSMesa shared library that GLFW loads internally.static voidsetPath(org.lwjgl.system.FunctionProvider sharedLibrary) CallssetPath(String)with the path of the specifiedSharedLibrary.
-
Method Details
-
nglfwGetOSMesaColorBuffer
public static int nglfwGetOSMesaColorBuffer(long window, long width, long height, long format, long buffer) Unsafe version of:GetOSMesaColorBuffer -
glfwGetOSMesaColorBuffer
public static boolean glfwGetOSMesaColorBuffer(long window, @Nullable IntBuffer width, @Nullable IntBuffer height, @Nullable IntBuffer format, @Nullable org.lwjgl.PointerBuffer buffer) Retrieves the color buffer associated with the specified window.This function may be called from any thread. Access is not synchronized.
- Parameters:
window- the window whose color buffer to retrievewidth- where to store the width of the color buffer, orNULLheight- where to store the height of the color buffer, orNULLformat- where to store the OSMesa pixel format of the color buffer, orNULLbuffer- where to store the address of the color buffer, orNULL- Returns:
TRUEif successful, orFALSEif an error occurred.Possible errors include
NO_WINDOW_CONTEXTandNOT_INITIALIZED.- Since:
- version 3.3
-
nglfwGetOSMesaDepthBuffer
public static int nglfwGetOSMesaDepthBuffer(long window, long width, long height, long bytesPerValue, long buffer) Unsafe version of:GetOSMesaDepthBuffer -
glfwGetOSMesaDepthBuffer
public static int glfwGetOSMesaDepthBuffer(long window, @Nullable IntBuffer width, @Nullable IntBuffer height, @Nullable IntBuffer bytesPerValue, @Nullable org.lwjgl.PointerBuffer buffer) Retrieves the depth buffer associated with the specified window.This function may be called from any thread. Access is not synchronized.
- Parameters:
window- the window whose depth buffer to retrievewidth- where to store the width of the depth buffer, orNULLheight- where to store the height of the depth buffer, orNULLbytesPerValue- where to store the number of bytes per depth buffer element, orNULLbuffer- where to store the address of the depth buffer, orNULL- Returns:
TRUEif successful, orFALSEif an error occurred.Possible errors include
NO_WINDOW_CONTEXTandNOT_INITIALIZED.- Since:
- version 3.3
-
glfwGetOSMesaContext
public static long glfwGetOSMesaContext(long window) Returns theOSMesaContextof the specified window.This function may be called from any thread. Access is not synchronized.
- Parameters:
window- the window whose context to retrieve- Returns:
- the
OSMesaContextof the specified window, orNULLif an error occurred.Possible errors include
NO_WINDOW_CONTEXTandNOT_INITIALIZED. - Since:
- version 3.3
-
glfwGetOSMesaColorBuffer
public static boolean glfwGetOSMesaColorBuffer(long window, int @Nullable [] width, int @Nullable [] height, int @Nullable [] format, @Nullable org.lwjgl.PointerBuffer buffer) Array version of:GetOSMesaColorBuffer -
glfwGetOSMesaDepthBuffer
public static int glfwGetOSMesaDepthBuffer(long window, int @Nullable [] width, int @Nullable [] height, int @Nullable [] bytesPerValue, @Nullable org.lwjgl.PointerBuffer buffer) Array version of:GetOSMesaDepthBuffer -
setPath
public static void setPath(org.lwjgl.system.FunctionProvider sharedLibrary) CallssetPath(String)with the path of the specifiedSharedLibrary.Example usage:
GLFWNativeOSMesa.setPath(GL.getFunctionProvider());- Parameters:
sharedLibrary- aFunctionProviderinstance that will be cast toSharedLibrary
-
setPath
Overrides the OSMesa shared library that GLFW loads internally.This is useful when there's a mismatch between the shared libraries loaded by LWJGL and GLFW.
This method must be called before GLFW initializes OpenGL. The override is available only in the default GLFW build bundled with LWJGL. Using the override with a custom GLFW build will produce a warning in
DEBUGmode (but not an error).- Parameters:
path- the OSMesa shared library path, ornullto remove the override.
-