Getting JGearApplet to work

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

Getting JGearApplet to work

byhisdeeds
I am trying to get the gears demo applet working within a gwt HTML panel. I get the applet part working with a small java2d applet, and now I want to replace that applet with a jogl applet, gears to start with. I have the applet-gears.jnlp setup from http://localhost:8084/test/jogl/applet-gears.jnlp and if I try and run it via java webstart it works and finds all the various jars which are located in the same directory as it. the applet-gears.jnlp looks like:

<?xml version="1.0" encoding="utf-8"?>
<jnlp codebase="http://localhost:8084/test/jogl" href="applet-gears.jnlp">
  <information>
    <title>JOGL JNLP Applet Gears Demo</title>
    <vendor>JogAmp Community</vendor>
    <homepage href="http://jogamp.org/jogl-demos/"/>
    <description>Gears Demo</description>
    <description kind="short">Brian Paul's Gears demo ported to Java and JOGL.</description>
    <offline-allowed/>
  </information>

    <resources>
      <j2se href="http://java.sun.com/products/autodl/j2se" version="1.4+"/>
      <property name="sun.java2d.noddraw" value="true"/>
      <jar href="jogl-demos.jar" main="true"/>
      <jar href="jogl-demos-util.jar"/>
      <extension name="newt-all-awt" href="newt-all-awt.jnlp" />
    </resources>

  <applet-desc
      name="Gears-Applet"
      main-class="demos.applets.GearsApplet"
      width="640"
      height="400">
  </applet-desc>
</jnlp>

My applet code within the html element is:
new HTML(
        "<applet" +
        " code=\"org.jdesktop.applet.util.JNLPAppletLauncher\"" +
        " archive=\"jogl/applet-launcher.jar,jogl/nativewindow.all.jar,jogl/jogl.all.jar,jogl/gluegen-rt.jar,jogl/jogl-demos.jar\"" +
        " width=\"640\"" +
        " height=\"400\">" +
        "  " +
        "  " +
        "  " +
        "  " +
        "  " +
        "  " +
        "  " +
        "  " +
        "  " +
        "</applet>"
);

Can anyone see what I'm missing as the page loads with no errors, a 640x480 grey section where the applet should go but that's all.

John
Reply | Threaded
Open this post in threaded view
|

Re: Getting JGearApplet to work

byhisdeeds
Ok, it seems that the problem was that Chrome on my fedora box was running IceTea java applet plugin, and that could not display the applet. Adding the Sun java plugin /usr/local/java/jre/lib/i386/libnpjp2.so in /opt/google/chrome/plugins/ activated the Sun java jvm and now everything works.

Now my question is does anyone know what the issue is with the default Icetea jvm and whether it will ever be able to run jogl applets.

john