Creating a BufferedImage causes GLFW in the LWJGL to lock up (Java)

旧时模样 提交于 2019-12-03 22:59:22

问题


There is a link to download the project below. The project already contains the LWJGL. Just open it with eclipse and tell me I'm not going crazy

I'm experimenting with the LWJGL for the first time and have managed to get the sample code on the LWJGL website to work. The odd thing is, if I create an instance of a BufferedImage anywhere in the program, it causes the whole thing to lock up. I've managed to narrow it down to the ColorModel class (which is used by BufferedImage) but can't figure out why it is happening. I'll attach a zip file with my eclipse project to this post which demonstrates the issue.

You'll notice that I even access the ColorModel class in a separate thread from the one that is running LWJGL and GLFW.


Project: https://www.dropbox.com/s/cxf4hsz8o91zemw/LWJGLTest.zip?dl=0

NOTE: I am running this on a macOS machine. It's possible that this behavior is limited to macOS.

For those that just want the code without the project: http://pastebin.com/Z1xDAZQ5

If I'm missing any information please let me know and I'll be happy to provide it. Thank you for your help.


Version info:

LWJGL Version - 3.0.0 build 90

Java Version - JDK 1.8.0u101

OpenGL Version - 2.1

macOS Version - 10.12.1 Beta (16B2333a)

来源:https://stackoverflow.com/questions/39809275/creating-a-bufferedimage-causes-glfw-in-the-lwjgl-to-lock-up-java

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!