Re: [JPP-Devel] WorldWind plugin

2019-10-14 Thread Rahkonen Jukka (MML)
Hi Nicolas,

Works also here once I copied the jar files.

-Jukka-

Lähettäjä: Nicolas Ribot 
Lähetetty: maanantai 14. lokakuuta 2019 16.44
Vastaanottaja: OpenJump develop and use 
Aihe: Re: [JPP-Devel] WorldWind plugin

Hi Jukka,

I was able to reproduce the errors you had.
I copied glugen*.jar and jogl*.jar from worldwind-v2.1.0 to oj/lib/ and it 
worked (no need to extract dll from jar files)

I will update the installation procedure and find a way to declare classpath 
correctly in the plugin

Nicolas

On Mon, 14 Oct 2019 at 10:43, Nicolas Ribot 
mailto:nicolas.ri...@gmail.com>> wrote:
Hi Jukka,

I tested the plugin with OJ rev 6083 on MacOS 10.14.6,
java version "1.8.0_191"
Java(TM) SE Runtime Environment (build 1.8.0_191-b12)
Java HotSpot(TM) 64-Bit Server VM (build 25.191-b12, mixed mode)

and with OJ rev 6147 on windows 10,
java version "1.8.0_171"
Java(TM) SE Runtime Environment (build 1.8.0_171-b11)
Java HotSpot(TM) 64-Bit Server VM (build 25.171-b11, mixed mode)

I will have a look for a proper installation procedure.

Nicolas

On Sun, 13 Oct 2019 at 21:44, Rahkonen Jukka (MML) 
mailto:jukka.rahko...@maanmittauslaitos.fi>>
 wrote:
Hi,

I downloaded worldwind-v2_1_0_zip and unzipped it into my OpenJUMP directory 
under …OpenJUMP-20190228-r6144-PLUS\lib\ext\worldwind-2.1.0.  Then I downloaded 
https://sourceforge.net/p/jump-pilot/code/HEAD/tree/plug-ins/OjWorldWind/out/artifacts/ojworldwind/ojworldwind.jar
 and placed it into \lib\ext. However, the plugin does not start with Java 
1.8.0_201(amd64), nor with 32-bit Java. The error message says that 
gluegen-rt.jar is not in the desired directory. By copying the dll from the jar 
file that contains the native components into the root OJ directory I could 
forward to the next error which seems to be harder to work around. Perhaps I 
could edit oj_windows.bat to set the path, but how?

The initial error was:

java.lang.UnsatisfiedLinkError: Can't load library: 
C:\ohjelmat\OJ\OpenJUMP-20190228-r6144-PLUS\gluegen-rt.dll
   at java.lang.ClassLoader.loadLibrary(Unknown Source)
   at java.lang.Runtime.load0(Unknown Source)
   at java.lang.System.load(Unknown Source)
   at 
com.jogamp.common.jvm.JNILibLoaderBase.loadLibraryInternal(JNILibLoaderBase.java:551)
   at 
com.jogamp.common.jvm.JNILibLoaderBase.access$000(JNILibLoaderBase.java:64)
   at 
com.jogamp.common.jvm.JNILibLoaderBase$DefaultAction.loadLibrary(JNILibLoaderBase.java:96)
   at 
com.jogamp.common.jvm.JNILibLoaderBase.loadLibrary(JNILibLoaderBase.java:414)
   at 
com.jogamp.common.os.DynamicLibraryBundle$GlueJNILibLoader.loadLibrary(DynamicLibraryBundle.java:388)
   at 
com.jogamp.common.os.Platform$1.run(Platform.java:209)
   at 
java.security.AccessController.doPrivileged(Native Method)
   at 
com.jogamp.common.os.Platform.(Platform.java:179)
   at 
javax.media.opengl.GLProfile.(GLProfile.java:83)
   at 
gov.nasa.worldwind.Configuration.getMaxCompatibleGLProfile(Configuration.java:658)
   at 
gov.nasa.worldwind.Configuration.getRequiredGLCapabilities(Configuration.java:671)
   at 
gov.nasa.worldwind.awt.WorldWindowGLCanvas.(WorldWindowGLCanvas.java:64)
   at 
org.openjump.ojworldwind.ww.ApplicationTemplate$AppPanel.createWorldWindow(ApplicationTemplate.java:76)
   at 
org.openjump.ojworldwind.ww.ApplicationTemplate$AppPanel.(ApplicationTemplate.java:52)
   at 
org.openjump.ojworldwind.ww.ApplicationTemplate$AppFrame.createAppPanel(ApplicationTemplate.java:382)
   at 
org.openjump.ojworldwind.ww.ApplicationTemplate$AppFrame.initialize(ApplicationTemplate.java:121)
   at 
org.openjump.ojworldwind.ww.ApplicationTemplate$AppFrame.(ApplicationTemplate.java:112)
   at 
sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
   at 
sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source)
   at 
sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source)
   at java.lang.reflect.Constructor.newInstance(Unknown 
Source)
   at java.lang.Class.newInstance(Unknown Source)
   at 
org.openjump.ojworldwind.ww.ApplicationTemplate.start(ApplicationTemplate.java:488)
   at 
org.openjump.ojworldwind.OjWorldwindPlugin.execute(OjWorldwindPlugin.java:94)
   at 
com.vividsolutions.jump.workbench.plugin.AbstractPlugIn$1.actionP

Re: [JPP-Devel] WorldWind plugin

2019-10-14 Thread edgar . soldin
hey Nic,

plugins are supposed to reside under lib/ext/ exclusively. when we start 
placing their files all over we will have trouble to properly find out 
dependencies in the future.

rather let's find out why the plugin does not work with the plugin class 
loader. ..ede

On 14.10.2019 15:44, Nicolas Ribot wrote:
> Hi Jukka,
> 
> I was able to reproduce the errors you had.
> I copied glugen*.jar and jogl*.jar from worldwind-v2.1.0 to oj/lib/ and it 
> worked (no need to extract dll from jar files)
> 
> I will update the installation procedure and find a way to declare classpath 
> correctly in the plugin
> 
> Nicolas
> 
> On Mon, 14 Oct 2019 at 10:43, Nicolas Ribot  > wrote:
> 
> Hi Jukka,
> 
> I tested the plugin with OJ rev 6083 on MacOS 10.14.6,
> java version "1.8.0_191"
> Java(TM) SE Runtime Environment (build 1.8.0_191-b12)
> Java HotSpot(TM) 64-Bit Server VM (build 25.191-b12, mixed mode)
> 
> and with OJ rev 6147 on windows 10,
> java version "1.8.0_171"
> Java(TM) SE Runtime Environment (build 1.8.0_171-b11)
> Java HotSpot(TM) 64-Bit Server VM (build 25.171-b11, mixed mode)
> 
> I will have a look for a proper installation procedure.
> 
> Nicolas
> 
> On Sun, 13 Oct 2019 at 21:44, Rahkonen Jukka (MML) 
>  > wrote:
> 
> Hi,
> 
> __ __
> 
> I downloaded worldwind-v2_1_0_zip and unzipped it into my OpenJUMP 
> directory under …OpenJUMP-20190228-r6144-PLUS\lib\ext\worldwind-2.1.0.  Then 
> I downloaded 
> https://sourceforge.net/p/jump-pilot/code/HEAD/tree/plug-ins/OjWorldWind/out/artifacts/ojworldwind/ojworldwind.jar
>  and placed it into \lib\ext. However, the plugin does not start with Java 
> 1.8.0_201(amd64), nor with 32-bit Java. The error message says that 
> gluegen-rt.jar is not in the desired directory. By copying the dll from the 
> jar file that contains the native components into the root OJ directory I 
> could forward to the next error which seems to be harder to work around. 
> Perhaps I could edit oj_windows.bat to set the path, but how?
> 
> __ __
> 
> The initial error was:
> 
> __ __
> 
> java.lang.UnsatisfiedLinkError: Can't load library: 
> C:\ohjelmat\OJ\OpenJUMP-20190228-r6144-PLUS\gluegen-rt.dll
> 
>    at 
> java.lang.ClassLoader.loadLibrary(Unknown Source)
> 
>    at java.lang.Runtime.load0(Unknown 
> Source)
> 
>    at java.lang.System.load(Unknown 
> Source)
> 
>    at 
> com.jogamp.common.jvm.JNILibLoaderBase.loadLibraryInternal(JNILibLoaderBase.java:551)
> 
>    at 
> com.jogamp.common.jvm.JNILibLoaderBase.access$000(JNILibLoaderBase.java:64)
> 
>    at 
> com.jogamp.common.jvm.JNILibLoaderBase$DefaultAction.loadLibrary(JNILibLoaderBase.java:96)
> 
>    at 
> com.jogamp.common.jvm.JNILibLoaderBase.loadLibrary(JNILibLoaderBase.java:414)
> 
>    at 
> com.jogamp.common.os.DynamicLibraryBundle$GlueJNILibLoader.loadLibrary(DynamicLibraryBundle.java:388)
> 
>    at 
> com.jogamp.common.os.Platform$1.run(Platform.java:209)
> 
>    at 
> java.security.AccessController.doPrivileged(Native Method)
> 
>    at 
> com.jogamp.common.os.Platform.(Platform.java:179)
> 
>    at 
> javax.media.opengl.GLProfile.(GLProfile.java:83)
> 
>    at 
> gov.nasa.worldwind.Configuration.getMaxCompatibleGLProfile(Configuration.java:658)
> 
>    at 
> gov.nasa.worldwind.Configuration.getRequiredGLCapabilities(Configuration.java:671)
> 
>    at 
> gov.nasa.worldwind.awt.WorldWindowGLCanvas.(WorldWindowGLCanvas.java:64)
> 
>    at 
> org.openjump.ojworldwind.ww.ApplicationTemplate$AppPanel.createWorldWindow(ApplicationTemplate.java:76)
> 
>    at 
> org.openjump.ojworldwind.ww.ApplicationTemplate$AppPanel.(ApplicationTemplate.java:52)
> 
>    at 
> org.openjump.ojworldwind.ww.ApplicationTemplate$AppFrame.createAppPanel(ApplicationTemplate.java:382)
> 
>    at 
> org.openjump.ojworldwind.ww.ApplicationTemplate$AppFrame.initialize(ApplicationTemplate.java:121)
> 
>    at 
> org.openjump.ojworldwind.ww.ApplicationTemplate$AppFrame.(ApplicationTemplate.java:112)
> 
>    at 
> sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
> 
>   

Re: [JPP-Devel] WorldWind plugin

2019-10-14 Thread Nicolas Ribot
reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source)
>>
>>at
>> java.lang.reflect.Constructor.newInstance(Unknown Source)
>>
>>at java.lang.Class.newInstance(Unknown Source)
>>
>>at
>> org.openjump.ojworldwind.ww.ApplicationTemplate.start(ApplicationTemplate.java:488)
>>
>>at
>> org.openjump.ojworldwind.OjWorldwindPlugin.execute(OjWorldwindPlugin.java:94)
>>
>>at
>> com.vividsolutions.jump.workbench.plugin.AbstractPlugIn$1.actionPerformed(AbstractPlugIn.java:344)
>>
>>at
>> javax.swing.AbstractButton.fireActionPerformed(Unknown Source)
>>
>>at
>> javax.swing.AbstractButton$Handler.actionPerformed(Unknown Source)
>>
>>at
>> javax.swing.DefaultButtonModel.fireActionPerformed(Unknown Source)
>>
>>at
>> javax.swing.JToggleButton$ToggleButtonModel.setPressed(Unknown Source)
>>
>>at javax.swing.AbstractButton.doClick(Unknown
>> Source)
>>
>>at
>> javax.swing.plaf.basic.BasicMenuItemUI.doClick(Unknown Source)
>>
>>at
>> javax.swing.plaf.basic.BasicMenuItemUI$Handler.mouseReleased(Unknown Source)
>>
>>at
>> java.awt.Component.processMouseEvent(Unknown Source)
>>
>>at
>> javax.swing.JComponent.processMouseEvent(Unknown Source)
>>
>>at java.awt.Component.processEvent(Unknown
>> Source)
>>
>>at java.awt.Container.processEvent(Unknown
>> Source)
>>
>>at
>> java.awt.Component.dispatchEventImpl(Unknown Source)
>>
>>at
>> java.awt.Container.dispatchEventImpl(Unknown Source)
>>
>>at java.awt.Component.dispatchEvent(Unknown
>> Source)
>>
>>at
>> java.awt.LightweightDispatcher.retargetMouseEvent(Unknown Source)
>>
>>at
>> java.awt.LightweightDispatcher.processMouseEvent(Unknown Source)
>>
>>at
>> java.awt.LightweightDispatcher.dispatchEvent(Unknown Source)
>>
>>at
>> java.awt.Container.dispatchEventImpl(Unknown Source)
>>
>>at java.awt.Window.dispatchEventImpl(Unknown
>> Source)
>>
>>at java.awt.Component.dispatchEvent(Unknown
>> Source)
>>
>>at
>> java.awt.EventQueue.dispatchEventImpl(Unknown Source)
>>
>>at java.awt.EventQueue.access$500(Unknown
>> Source)
>>
>>at java.awt.EventQueue$3.run(Unknown Source)
>>
>>at java.awt.EventQueue$3.run(Unknown Source)
>>
>>at
>> java.security.AccessController.doPrivileged(Native Method)
>>
>>at
>> java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown
>> Source)
>>
>>at
>> java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown
>> Source)
>>
>>at java.awt.EventQueue$4.run(Unknown Source)
>>
>>at java.awt.EventQueue$4.run(Unknown Source)
>>
>>        at
>> java.security.AccessController.doPrivileged(Native Method)
>>
>>at
>> java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown
>> Source)
>>
>>at java.awt.EventQueue.dispatchEvent(Unknown
>> Source)
>>
>>at
>> java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
>>
>>at
>> java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
>>
>>at
>> java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
>>
>>at
>> java.awt.EventDispatchThread.pumpEvents(Unknown Source)
>>
>>at
>> java.awt.EventDispatchThread.pumpEvents(Unknown Source)
>>