Applet demos not working

classic Classic list List threaded Threaded
10 messages Options
Reply | Threaded
Open this post in threaded view
|

Applet demos not working

Kyle
Hello!

I've been considering deploy my JOGL application as an applet but I'm having second thoughts. I started looking into how to do the whole thing and checked out the demos. None of them would load. Nothing I did could fix it either, I've tried running under Ubuntu 12.04, Windows XP, Windows 7, Firefox, Google Chrome, Internet Explorer, Java 6, and Java 7.

Is deploying a JOGL applet currently impossible?

Running the gears demo in applet viewer gives me this:

java.security.AccessControlException: access denied (java.util.PropertyPermission java.io.tmpdir read)
        at java.security.AccessControlContext.checkPermission(AccessControlContext.java:393)
        at java.security.AccessController.checkPermission(AccessController.java:553)
        at java.lang.SecurityManager.checkPermission(SecurityManager.java:549)
        at java.lang.SecurityManager.checkPropertyAccess(SecurityManager.java:1302)
        at java.lang.System.getProperty(System.java:669)
        at org.jdesktop.applet.util.JNLPAppletLauncher.initTmpRoot(JNLPAppletLauncher.java:1056)
        at org.jdesktop.applet.util.JNLPAppletLauncher.<clinit>(JNLPAppletLauncher.java:2190)
        at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
        at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57)
        at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
        at java.lang.reflect.Constructor.newInstance(Constructor.java:532)
        at java.lang.Class.newInstance0(Class.java:372)
        at java.lang.Class.newInstance(Class.java:325)
        at sun.applet.AppletPanel.createApplet(AppletPanel.java:798)
        at sun.applet.AppletPanel.runLoader(AppletPanel.java:727)
        at sun.applet.AppletPanel.run(AppletPanel.java:380)
        at java.lang.Thread.run(Thread.java:679)

Are the certificates expired or something? I'm not sure what else could cause that.
Reply | Threaded
Open this post in threaded view
|

Re: Applet demos not working

Xerxes Rånby
2012-07-06 15:37, Kyle [via jogamp] skrev:
Hello!

I've been considering deploy my JOGL application as an applet but I'm having second thoughts. I started looking into how to do the whole thing and checked out the demos. None of them would load. Nothing I did could fix it either, I've tried running under Ubuntu 12.04, Windows XP, Windows 7, Firefox, Google Chrome, Internet Explorer, Java 6, and Java 7.

Interesting that you hit this issue using all of the above platforms.
Most likely you are using JOGL 1 from the oracle/sun servers, Oracle have stopped signing their jars since they do not support JOGL anymore.
Is deploying a JOGL applet currently impossible?
You need to use the JogAmp JOGL 2 jars from http://jogamp.org/deployment/jogamp-current/ they are signed.

Cheers
Xerxes



If you reply to this email, your message will be added to the discussion below:
http://forum.jogamp.org/Applet-demos-not-working-tp4025445.html
To start a new topic under jogamp, email [hidden email]
To unsubscribe from jogamp, click here.
NAML

Reply | Threaded
Open this post in threaded view
|

Re: Applet demos not working

gouessej
Administrator
In reply to this post by Kyle
Hi

As you are under Ubuntu, OpenJDK (with Icedtea and Icedtea-web) is installed by default. "legacy" applets work but applets using JNLP are not yet supported by Icedtea-web. I advise you to use Java Web Start until this feature is implemented.

Anyway, I think that the JOGL applet is not allowed to decompress the JARs containing the native libraries in your temporary directory on your machine, that's why you get this exception trace, you should report this bug.
Julien Gouesse | Personal blog | Website
Reply | Threaded
Open this post in threaded view
|

Re: Applet demos not working

gouessej
Administrator
In reply to this post by Xerxes Rånby
Xerxes, you're right. I didn't imagine he was still using JOGL 1. I already said some years ago that Oracle stopped signing its JARs for JOGL.
Julien Gouesse | Personal blog | Website
Reply | Threaded
Open this post in threaded view
|

Re: Applet demos not working

Kyle
In reply to this post by gouessej
Oh! Well, the Gears applet DOES use JOGL 1 I think, you guys would probably know more about that than me. However I DID try to use the JOGL 2 jars for the Gears applet and still had no success. BUT! That was under Ubuntu, I didn't try that one windows.

I haven't tried to do anything yet with my own program, at the moment I'm happy with my Web Start application, but an applet would be nice, that's why I looked into it.

Also, why would JOGL have problems decompressing the jars if it's signed? Shouldn't I just get a "THIS SOFTWARE MAY TAKE AWAY YOUR COMPUTER'S INNOCENCE" message?

ALSO! Thanks for your replies :)
Reply | Threaded
Open this post in threaded view
|

Re: Applet demos not working

gouessej
Administrator
I don't succeed in running the applets too :(
Julien Gouesse | Personal blog | Website
Reply | Threaded
Open this post in threaded view
|

Re: Applet demos not working

Kyle
OK so I was able to get the http://jogamp.org/deployment/jogamp-next/jogl-test-applets.html applets running under Windows. I'm noticing on these applets that they use com.jogamp.newt.awt.applet.JOGLNewtApplet1Run which I haven't heard of until now. The demos don't work under linux still, but if I can get my applet running under Windows I'll be satisfied, even if it hurts a little on the inside. There's more Windows users than Linux users. From the looks of it looking around the problem seems to be icedtea like you mentioned.
Reply | Threaded
Open this post in threaded view
|

Re: Applet demos not working

Sven Gothel
Administrator
On 07/07/2012 01:59 AM, Kyle [via jogamp] wrote:
> OK so I was able to get the
> http://jogamp.org/deployment/jogamp-next/jogl-test-applets.html applets
> running under Windows. I'm noticing on these applets that they use
> com.jogamp.newt.awt.applet.JOGLNewtApplet1Run which I haven't heard of until
> now.

This utility class is just a tool allow loading any GLEventListener
into a NEWT GLWindow, which itself is hooked to an AWT component (the Applet).
It's documented in the source (API doc) and on the launch page.

The jogl-demo page has a test for Gears (GL2) as well, using plain AWT.

> The demos don't work under linux still, but if I can get my applet
> running under Windows I'll be satisfied, even if it hurts a little on the
> inside. There's more Windows users than Linux users. From the looks of it
> looking around the problem seems to be icedtea like you mentioned.

Yes. It's not Windows vs Linux.

~Sven


signature.asc (910 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: Applet demos not working

Kyle
In reply to this post by Kyle
Let me tell you all a tale. A tale of blood, torture and murder...

    I tried to get my own applet running and it turned out to be quit an ordeal. It took me the entire day of fumbling to prevail! I'm writing this just to vent.

    I set up the JNLP file, and the web page and tried loading in appletviewer, from there only horror awaited. I kept getting "access denied" so I wrote a policy file and gave it to appletviewer. What could go wrong? Other than a couple easily fixed syntax errors, nothing. NOTHING AT ALL! But... oh my... That was locally on my computer.
    I tried uploading my jar and jnlp to my website. It worked just FINE on my computer, what could go wrong here? I got an error, uh... many errors, I can't remember entirely but fumbling around it complained of a "NoClassDefFoundError" for "com.jogbamp.common.os.Platform" and "jogamp.common.os.PlatformPropsImpl" and other times complaining about not validating the certificate for native libs.
    To this very moment I don't understand why I got the NoClassDefFoundError but I can explain the certificate issue. I was trying to use http://jogamp.org/deployment/util/applet-launcher.jar rather than the one in the other areas, I guess that certificate is outdated or incompatible for some reason with the newer jars.
    With time the NoClassDefFoundError went away strangely, but instead turned into an "Incompatible magic number 218774561." Wtf is this? I don't believe in magic, gtfo my universe. I did research and figured out what a magic number was or at least in this context. So I converted that number into ASCII. What did I get? I got this:
 
\r\n<!

Hm... Looks a lot like <!DOCTYPE... like the start of new line in a web page. Why is this? I'm just getting a jar off of my website!
    Off of my website... hmm... *scratches head* Could my host's file manager be using some kind of wrapper web page for every file? I went out and quickly made an account on another free web hosting website, uploaded my documents and scrambled to get everything using that website. I launch appletviewer.

Loading....
Starting applet...
...
...
...
...!

OMGWTFBBQMAIGAWDROFLMAO

    Oh heavens, oh my, did I do that? I did it! Success! Yes! Oh I can't wait to... Oh... I still need to test this in my browser. *scratches head* Well... I don't want to ruin the moment...

...
*makes a sandwich*
...
*takes a shower*
...
*plays Minecraft*
...
*cleans the kitchen*
...

   Well... I guess it needs to get done some time. I slowly started uploading the jnlp and new html document. I mouse over the refresh button... I hover my finger over the mouse... Carefully.... CAREFULLY... *click*

Loading....
Starting applet...
...
...
...
...!

OMGWTFBBQMAIGAWDROFLMAO!!!!!111!1!!1one

It has been done! Oh god, I need to sleep.
Reply | Threaded
Open this post in threaded view
|

Re: Applet demos not working

Xerxes Rånby
This post was updated on .
In reply to this post by Kyle
2012-07-07 01:59, Kyle [via jogamp] skrev:
> OK so I was able to get the http://jogamp.org/deployment/jogamp-next/jogl-test-applets.html applets running under Windows. I'm noticing on these applets that they use com.jogamp.newt.awt.applet.JOGLNewtApplet1Run which I haven't heard of until now. The demos don't work under linux still,

Under Linux icedtea-web (java webbrowser plugin for OpenJDK) is the mechanism responsible to launch the applets .
IcedTea-web it is a separate project compared to IcedTea (OpenJDK) and can be also be built and tested separately.
There have been a known regression in icedtea-web 1.2, compared to icedtea-web 1.1.3, that the icedtea-web jar verifier got implemented a little too strict and refused to run a signed jar in combination with a unsigned one, icedtea-web 1.2 only allow running JOGL if all the jars are signed (like the JogAmp version demo).
This strictness regression is, to my knowledge, fixed in icedtea-web 1.3 that is about to get released, I have been able to launch all the applets from http://jogamp.org/deployment/jogamp-current/jogl-test-applets.html today when using my own build of icedtea-web 1.3.

It would help a lot if someone else than me can re-verify that all the JogAmp applets are working again by using the latest icedtea-web built using these instructions: http://icedtea.classpath.org/wiki/IcedTea-Web#Getting_IcedTea-Web .
Use the bleeding edge icedtea-web hg repository:
hg clone http://icedtea.classpath.org/hg/icedtea-web

You can check which version of icedtea-web you are using by visiting about:plugins in your browser

Cheers
Xerxes

> ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
> If you reply to this email, your message will be added to the discussion below:
> http://forum.jogamp.org/Applet-demos-not-working-tp4025445p4025454.html
> To start a new topic under jogamp, email ml-node+s762907n762907h80@n3.nabble.com
> To unsubscribe from jogamp, click here <http://forum.jogamp.org/template/NamlServlet.jtp?macro=unsubscribe_by_code&node=762907&code=eGVyeGVzQGd1ZGlubmEuY29tfDc2MjkwN3wtNTE5NjUwMzEw>.
> NAML <http://forum.jogamp.org/template/NamlServlet.jtp?macro=macro_viewer&id=instant_html%21nabble%3Aemail.naml&base=nabble.naml.namespaces.BasicNamespace-nabble.view.web.template.NabbleNamespace-nabble.view.web.template.NodeNamespace&breadcrumbs=notify_subscribers%21nabble%3Aemail.naml-instant_emails%21nabble%3Aemail.naml-send_instant_email%21nabble%3Aemail.naml>