java - JOGL 没有自动释放池

标签 java opengl system jogl nsautoreleasepool

我尝试将 JOGL 添加到我的项目中,在网上搜索了很长时间后我找到了解决方案。我将 jars 添加到我的构建路径中,Eclipse 可以识别它们。
我想测试一下,所以从这里获取了代码:https://sites.google.com/site/justinscsstuff/jogl-tutorial-2并编译。
AWT 方式给了我这个结果:

2012-06-03 18:20:44.623 java[1481:903] [Java CocoaComponent compatibility mode]: Enabled
2012-06-03 18:20:44.626 java[1481:903] [Java CocoaComponent compatibility mode]: Setting timeout for SWT to 0.100000
2012-06-03 18:20:46.253 java[1481:903] *** __NSAutoreleaseNoPool(): Object 0x102034900 of class NSConcreteMapTableValueEnumerator autoreleased with no pool in place - just leaking
2012-06-03 18:20:46.259 java[1481:903] *** __NSAutoreleaseNoPool(): Object 0x10209e3f0 of class __NSCFDate autoreleased with no pool in place - just leaking
2012-06-03 18:20:46.259 java[1481:903] *** __NSAutoreleaseNoPool(): Object 0x10209cbd0 of class NSCFTimer autoreleased with no pool in place - just leaking
2012-06-03 18:20:46.301 java[1481:d703] *** __NSAutoreleaseNoPool(): Object 0x10015e990 of class NSCFNumber autoreleased with no pool in place - just leaking
2012-06-03 18:20:46.301 java[1481:d703] *** __NSAutoreleaseNoPool(): Object 0x100121720 of class NSConcreteValue autoreleased with no pool in place - just leaking
2012-06-03 18:20:46.302 java[1481:d703] *** __NSAutoreleaseNoPool(): Object 0x10011c2f0 of class NSCFNumber autoreleased with no pool in place - just leaking
2012-06-03 18:20:46.302 java[1481:d703] *** __NSAutoreleaseNoPool(): Object 0x1001ba750 of class NSConcreteValue autoreleased with no pool in place - just leaking
2012-06-03 18:20:46.302 java[1481:d703] *** __NSAutoreleaseNoPool(): Object 0x100157e70 of class NSCFDictionary autoreleased with no pool in place - just leaking

我找不到其他有同样问题的人。我确实发现其他人有同样的错误,但不是同样的原因。 NEWT 方式给了我一个白色方 block ,它“没有响应”,我必须强制停止它(Apple 键 + alt + esc)。
我的光标变成等待光标。虽然它设计得很好,但我宁愿摆脱它​​。
我应该如何解决这个问题?我在 Mac 上使用 Eclipse。操作系统 10.6.8。

编辑:

多亏了 Clint,前两行不见了,但它仍然在泄漏......

编辑 2:

解决了!

最佳答案

如果您的类路径中有 swt.jar 并且没有使用它,您应该将其删除。

关于java - JOGL 没有自动释放池,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/10871489/

相关文章:

java - 如何安全地取消订阅 Kafka 中的主题

基于java的开发环境

opengl - 第一次调用 opengl 时出现 sdl/opengl 段错误(macbook pro/macports)

c# - 使用 Thread.Sleep 在 c# 中的循环中每次等待一秒钟

java - 从 PHP exec 调用 java

java - Eclipse 中的 Ivy 调试消息级别

c++ - 无效重载与 glutDisplayFunc 不兼容

python - python 中的 Kivy 模块

python - 运行最安全的python代码

c++ - 创建具有该名称的变量后调用 native C 函数