Java-Gaming.org    
Featured games (91)
games approved by the League of Dukes
Games in Showcase (580)
games submitted by our members
Games in WIP (500)
games currently in development
News: Read the Java Gaming Resources, or peek at the official Java tutorials
 
    Home     Help   Search   Login   Register   
Pages: [1]
  ignore  |  Print  
  [solved]Problems deploying applet  (Read 5236 times)
0 Members and 1 Guest are viewing this topic.
Offline cupcakey

Senior Newbie


Medals: 1



« Posted 2012-10-25 03:47:04 »

Using JOGL 2.0, applet has no warnings in eclipse IDE.
Succesfully, Signed the jar file.

Should I not include the classpath when I make the JAR(from eclipse)?

Is the error in my actual JAVA programming(applet runs fine in eclipse) or am I doing something wrong here?

edit - I am using awt, and running Linux Mint 13 OS.

here's my test link.
http://realchemist.zxq.net/pages/Applets/test.html
And here's the code for the link/deploy.

1  
2  
3  
4  
5  
6  
7  
8  
9  
10  
11  
12  
13  
14  
15  
16  
17  
<applet code="OrbitalExplorer.orbitalExplorerApp"
      width=258
      height=322
      archive="http://jogamp.org/deployment/util/applet-launcher.jar,
               http://jogamp.org/deployment/webstart/nativewindow.all.jar,
               http://jogamp.org/deployment/webstart/jogl.all.jar,
               http://jogamp.org/deployment/webstart/gluegen-rt.jar,
               http://www.angelfire.com/indie/kcsoft/OrbitalExplorer.jar"
>
   <param name="codebase_lookup" value="false">
   <param name="subapplet.classname" value="orbitalExplorerApp">
   <param name="subapplet.displayname" value="Orbital Explorer Test">
   <param name="noddraw.check" value="true">
   <param name="progressbar" value="true">
   <param name="jnlpNumExtensions" value="1">
   <param name="jnlpExtension1"
          value="http://download.java.net/media/jogl/jsr-231-2.x-webstart/jogl-core.jnlp">
</applet>



Offline cupcakey

Senior Newbie


Medals: 1



« Reply #1 - Posted 2012-10-25 23:50:43 »

My manifest file is solid, my program runs fine, my jar is sealed and signed.

Trying a new approach. I figure the applet is impossible to make work. Kept getting an error about not being able to find "org.jdesktop.applet.util.JNLPAppletLauncher" even after downloading signing and uploading each required .jar ...

So now I'm trying with the .jnlp

Here's what I have going on:
http://realchemist.zxq.net/pages/Applets/test.html
1  
2  
3  
4  
5  
6  
7  
8  
9  
10  
11  
12  
13  
14  
15  
16  
17  
18  
19  
<applet code="org.jdesktop.applet.util.JNLPAppletLauncher"
      width=256
      height=322
      archive="http://jogamp.org/deployment/util/applet-launcher.jar,
               http://jogamp.org/deployment/webstart/nativewindow.all.jar,
               http://jogamp.org/deployment/webstart/jogl.all.jar,
               http://jogamp.org/deployment/webstart/gluegen-rt.jar,
               http://www.angelfire.com/indie/kcsoft/orbexplor.jar"
>
   <param name="codebase_lookup" value="false">
   <param name="subapplet.classname" value="OrbitalExplorer.orbitalExplorerApp">
   <param name="subapplet.displayname" value="OrbitalExplorer">
   <param name="noddraw.check" value="true">
   <param name="progressbar" value="true">
   <param name="jnlpNumExtensions" value="1">
   <param name="jnlpExtension1"
          value="http://jogamp.org/deployment/webstart/jogl-core.jnlp">
   <param name="java_arguments" value="-Dsun.java2d.noddraw=true">
   <param name="jnlp_href" value="http://www.angelfire.com/indie/kcsoft/oe.jnlp">
</applet>


then the oe.jnlp code is
1  
2  
3  
4  
5  
6  
7  
8  
9  
10  
11  
12  
13  
14  
15  
16  
17  
18  
19  
20  
21  
22  
23  
24  
25  
<?xml version="1.0" encoding="utf-8"?>
<jnlp href="http://www.angelfire.com/indie/kcsoft/oe.jnlp">
  <information>
    <title>Orbital Explorer</title>
    <vendor>None</vendor>
    <homepage href="http://www.realchemist.zxq.net"/>
    <description>Atomic orbital demonstrations</description>
    <description kind="short">Atomic orbital demonstrations</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="http://www.angelfire.com/indie/kcsoft/orbexplor.jar" main="true"/>
      <extension name="jogl-all-awt" href="http://jogamp.org/deployment/webstart/jogl-all-awt.jnlp" />
    </resources>

  <applet-desc
      name="OrbitalExplorer"
      main-class="OrbitalExplorer.orbitalExplorerApp"
      width="256"
      height="320">
  </applet-desc>
</jnlp>


Now I'm getting a fun error:
Exit Exception
Error While Initializing Managers
dump:
1  
2  
3  
4  
5  
6  
7  
8  
ExitException[ 3]JNLParseException[ Could not parse launch file. Error at line 29.]
   at sun.plugin2.applet.JNLP2Manager.redirectLaunchDesc(Unknown Source)
   at sun.plugin2.applet.JNLP2Manager.initialize(Unknown Source)
   at sun.plugin2.main.client.PluginMain.initManager(Unknown Source)
   at sun.plugin2.main.client.PluginMain.access$200(Unknown Source)
   at sun.plugin2.main.client.PluginMain$2.run(Unknown Source)
   at java.lang.Thread.run(Thread.java:722)
Error while initializing manager: ExitException[ 3]JNLParseException[ Could not parse launch file. Error at line 29.], bail out


Is JOGL 2.0 broken or am I really this daft? Does this work on anyone elses machine?
Offline gouessej

« In padded room »



TUER


« Reply #2 - Posted 2012-10-26 01:32:49 »

JOGL 2.0 is not broken. Which version of OpenJDK and NetX / IcedTea-Web you use?

Have you looked at this example?

Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline gouessej

« In padded room »



TUER


« Reply #3 - Posted 2012-10-26 01:34:21 »

You use an obsolete version of JOGL. The JAR has been renamed jogl-all.jar

Offline gouessej

« In padded room »



TUER


« Reply #4 - Posted 2012-10-26 01:38:30 »

I get this when trying your JNLP file:
Quote
net.sourceforge.jnlp.LaunchException: Fatal: Read Error: Could not read or parse the JNLP file.
   at net.sourceforge.jnlp.Launcher.fromUrl(Launcher.java:491)
   at net.sourceforge.jnlp.Launcher.launch(Launcher.java:283)
   at net.sourceforge.jnlp.runtime.Boot.run(Boot.java:202)
   at net.sourceforge.jnlp.runtime.Boot.run(Boot.java:51)
   at java.security.AccessController.doPrivileged(Native Method)
   at net.sourceforge.jnlp.runtime.Boot.main(Boot.java:168)
Caused by: net.sourceforge.jnlp.ParseException: Invalid XML document syntax.
   at net.sourceforge.jnlp.Parser.getRootNode(Parser.java:1305)
   at net.sourceforge.jnlp.JNLPFile.<init>(JNLPFile.java:206)
   at net.sourceforge.jnlp.JNLPFile.<init>(JNLPFile.java:190)
   at net.sourceforge.jnlp.JNLPFile.<init>(JNLPFile.java:175)
   at net.sourceforge.jnlp.JNLPFile.<init>(JNLPFile.java:161)
   at net.sourceforge.jnlp.Launcher.fromUrl(Launcher.java:482)
   ... 5 more
Caused by: net.sourceforge.nanoxml.XMLParseException: XML Parse Exception during parsing of a html element at line 15: Expected: <
   at net.sourceforge.nanoxml.XMLElement.expectedInput(XMLElement.java:1126)
   at net.sourceforge.nanoxml.XMLElement.scanElement(XMLElement.java:972)
   at net.sourceforge.nanoxml.XMLElement.scanElement(XMLElement.java:967)
   at net.sourceforge.nanoxml.XMLElement.scanElement(XMLElement.java:967)
   at net.sourceforge.nanoxml.XMLElement.scanElement(XMLElement.java:967)
   at net.sourceforge.nanoxml.XMLElement.scanElement(XMLElement.java:967)
   at net.sourceforge.nanoxml.XMLElement.parseFromReader(XMLElement.java:512)
   at net.sourceforge.nanoxml.XMLElement.parseFromReader(XMLElement.java:464)
   at net.sourceforge.jnlp.Parser.getRootNode(Parser.java:1301)
   ... 10 more

Offline cupcakey

Senior Newbie


Medals: 1



« Reply #5 - Posted 2012-10-26 01:42:35 »

I'm using OpenJDK 7 and NetX / IcedTea 1.2

Just found out I didn't have the iced-tea plug-in. Wow thanks now hopefully things will come together better. That's the only example I have been able to get to run.
Offline gouessej

« In padded room »



TUER


« Reply #6 - Posted 2012-10-26 01:46:22 »

Does it work on your machine? On mine I have only a grew rectangle :s

Offline gouessej

« In padded room »



TUER


« Reply #7 - Posted 2012-10-26 01:47:32 »

and don't use that: http://download.java.net/media/jogl/jsr-231-2.x-webstart/jogl-core.jnlp

You mix the old JOGL 2.0 (Oracle version) with JogAmp version :s

Offline gouessej

« In padded room »



TUER


« Reply #8 - Posted 2012-10-26 01:49:37 »

Ok. Maybe you could use one of my JNLP files as an example and try to make it work with Java Web Start until we find a solution to make it work as an applet:
http://tuer.sourceforge.net/very_experimental/tuer.jnlp

Offline cupcakey

Senior Newbie


Medals: 1



« Reply #9 - Posted 2012-10-26 01:56:58 »

it should draw a white glcanvas with 4 awt buttons on the bottom. when you click on a button it should then display some scattered pyramids. mouse clicking and moving on the canvas rotates the shape. The shapes are representations of atomic orbitals(chemistry) derived from schroedingers equation. Thanks for the file I'm about to give it a shot.
Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline cupcakey

Senior Newbie


Medals: 1



« Reply #10 - Posted 2012-10-26 02:29:04 »

Okay I got it to be a grey blank applet? Not sure why that is just yet.

http://www.realchemist.zxq.net/pages/Applets/test.html

My main class extends Applet, is this wrong? Should I be using newt?

oe.jnlp
1  
2  
3  
4  
5  
6  
7  
8  
9  
10  
11  
12  
13  
14  
15  
16  
17  
18  
19  
20  
21  
22  
23  
<?xml version="1.0" encoding="UTF-8"?>
   <jnlp spec="1.0+" href="http://www.angelfire.com/indie/kcsoft/oe.jnlp">
      <information>
         <title>Orbital Explorer</title>
         <vendor>None</vendor>
         <homepage href="http://www.angelfire.com/indie/kcsoft/"/>
         <description>Atomic orbital demonstrations</description>
         <offline-allowed/>
      </information>
      <security>
         <all-permissions/>
      </security>

      <update check="always" policy="always"/>
      <resources>
         <j2se version="1.6+" href="http://java.sun.com/products/autodl/j2se" initial-heap-size="32m" max-heap-size="256m" java-vm-args="-XX:MaxDirectMemorySize=128M"/>
         <jar href="http://www.angelfire.com/indie/kcsoft/orbexplor.jar" main="true"/>
         <jar href="http://jogamp.org/deployment/webstart/jar/gluegen-rt.jar" main="false"/>
         <jar href="http://jogamp.org/deployment/webstart/jar/jogl.all.jar" main="false"/>
         <property name="sun.java2d.noddraw" value="true"/>
      </resources>
      <application-desc main-class="OrbitalExplorer.orbitalExplorerApp" />
   </jnlp>


test.html
1  
2  
3  
4  
5  
6  
7  
8  
9  
10  
11  
12  
13  
14  
15  
16  
17  
<applet code="org.jdesktop.applet.util.JNLPAppletLauncher"
      width=256
      height=322
      archive="http://jogamp.org/deployment/webstart/jar/gluegen-rt.jar,
               http://jogamp.org/deployment/webstart/jar/jogl.all.jar,
               http://www.angelfire.com/indie/kcsoft/orbexplor.jar"
>
   <param name="codebase_lookup" value="false">
   <param name="subapplet.classname" value="OrbitalExplorer.orbitalExplorerApp">
   <param name="subapplet.displayname" value="OrbitalExplorer">
   <param name="noddraw.check" value="true">
   <param name="progressbar" value="true">
   <param name="jnlpNumExtensions" value="1">
   <param name="jnlpExtension1"
          value="http://jogamp.org/deployment/webstart/jogl-awt.jnlp">
   <param name="java_arguments" value="-Dsun.java2d.noddraw=true">
   <param name="jnlp_href" value="http://www.angelfire.com/indie/kcsoft/oe.jnlp">
</applet>
Offline cupcakey

Senior Newbie


Medals: 1



« Reply #11 - Posted 2012-10-26 03:53:37 »

Found my old applet project that used to work but the jars cerftificates ran out, and it was on an outdated jogl, copied the code with updated libraries except the old jnlp extension no longer exists. It says loading atleast... hahaha

http://realchemist.zxq.net/pages/Applets/test2.html
test2.html
1  
2  
3  
4  
5  
6  
7  
8  
9  
10  
11  
12  
13  
14  
15  
16  
17  
<applet code="org.jdesktop.applet.util.JNLPAppletLauncher"
      width="256"
      height="320"
      archive="http://jogamp.org/deployment/webstart/jar/applet-launcher.jar,
            http://jogamp.org/deployment/webstart/nativewindow.all.jar,
            http://jogamp.org/deployment/webstart/jar/jogl.all.jar,
            http://jogamp.org/deployment/webstart/jar/gluegen-rt.jar,
              http://www.angelfire.com/indie/kcsoft/orbexplor.jar"
>
   <param name="codebase_lookup" value="false">
   <param name="subapplet.classname" value="OrbitalExplorer.orbitalExplorerApp">
   <param name="subapplet.displayname" value="Orbital Explorer Test">
   <param name="noddraw.check" value="true">
   <param name="noddraw.check.silent" value="true">
   <param name="progressbar" value="true">
   <param name="jnlpNumExtensions" value="1">
   <param name="jnlpExtension1" value="http://jogamp.org/deployment/webstart/jogl-awt.jnlp">
</applet>
Offline cupcakey

Senior Newbie


Medals: 1



« Reply #12 - Posted 2012-10-26 21:51:02 »

This code gives an error:
1  
2  
3  
4  
5  
6  
7  
8  
9  
10  
11  
12  
13  
14  
15  
16  
17  
18  
19  
20  
21  
22  
23  
24  
25  
26  
ExitException[ 3]JNLPException[category: Launch File Error : Exception: java.lang.Exception: JNLP not an applet, nor a JavaFX application : LaunchDesc: 
<jnlp spec="1.0+" codebase="" href="http://www.angelfire.com/indie/kcsoft/oe.jnlp">
  <information>
    <title>Orbital Explorer</title>
    <vendor>None</vendor>
    <homepage href="http://www.realchemist.zxq.net/"/>
    <description>Atomic orbital demonstrations</description>
    <offline-allowed/>
  </information>
  <security>
    <all-permissions/>
  </security>
  <update check="always" policy="always"/>
  <resources>
    <j2se version="1.6+" href="http://java.sun.com/products/autodl/j2se" initial-heap-size="32m" max-heap-size="256m" java-vm-args="-XX:MaxDirectMemorySize=128M"/>
    <property name="sun.java2d.noddraw" value="true"/>
    <jar href="http://www.angelfire.com/indie/kcsoft/orbexplor.jar" download="eager" main="true"/>
    <jar href="http://jogamp.org/deployment/webstart/jar/gluegen-rt.jar" download="eager" main="false"/>
    <jar href="http://jogamp.org/deployment/webstart/jar/jogl.all.jar" download="eager" main="false"/>
    <jar href="http://jogamp.org/deployment/webstart/jar/applet-launcher.jar" download="eager" main="false"/>
  </resources>
  <application-desc main-class="OrbitalExplorer.orbitalExplorerApp"/>
</jnlp> ]
   at sun.plugin2.applet.JNLP2Manager.loadJarFiles(Unknown Source)
   at sun.plugin2.applet.Plugin2Manager$AppletExecutionRunnable.run(Unknown Source)
   at java.lang.Thread.run(Thread.java:722)


1  
2  
3  
4  
5  
6  
7  
8  
9  
10  
11  
12  
13  
14  
15  
16  
17  
18  
19  
20  
21  
22  
23  
24  
25  
26  
27  
28  
29  
30  
31  
32  
33  
34  
35  
<object classid="clsid:8AD9C840-044E-11D1-B3E9-00805F499D93" width="256" height="320">
   <param name="code" value="org.jdesktop.applet.util.JNLPAppletLauncher">
   <param name="archive" value="http://jogamp.org/deployment/webstart/jar/gluegen-rt.jar,
               http://jogamp.org/deployment/webstart/jar/jogl.all.jar,
               http://www.angelfire.com/indie/kcsoft/orbexplor.jar"
>
   <param name="codebase_lookup" value="false">
   <param name="subapplet.classname" value="OrbitalExplorer.orbitalExplorerApp">
   <param name="subapplet.displayname" value="Orbital Explorer">
   <param name="noddraw.check" value="true">
   <param name="progressbar" value="true">
   <param name="jnlpNumExtensions" value="1">
   <param name="jnlpExtension1" value="http://jogamp.org/deployment/webstart/jogl-awt.jnlp">
   <param name="java_arguments" value="-Dsun.java2d.noddraw=true">
   <param name="jnlp_href" value="http://www.angelfire.com/indie/kcsoft/oe.jnlp">
   <comment>
     <embed code="org.jdesktop.applet.util.JNLPAppletLauncher"
          width="256" height="320"
          type="application/x-java-applet;version=1.6"
          pluginspage="http://java.sun.com/javase/downloads/ea.jsp"
          archive="http://jogamp.org/deployment/webstart/jar/gluegen-rt.jar,
               http://jogamp.org/deployment/webstart/jar/jogl.all.jar,
               http://www.angelfire.com/indie/kcsoft/orbexplor.jar"

          codebase_lookup="false"
          subapplet.classname="OrbitalExplorer.orbitalExplorerApp"
          subapplet.displayname value="Orbital Explorer"
          noddraw.check value="true"
          progressbar="true"
          jnlpNumExtensions="1"
          jnlpExtension1="http://jogamp.org/deployment/webstart/jogl-awt.jnlp"
          java_arguments="-Dsun.java2d.noddraw=true"
          jnlp_href="http://www.angelfire.com/indie/kcsoft/oe.jnlp">
        <noembed>Sorry, no Java support detected.</noembed>
     </embed>
   </comment>
</object>



My main class extends Applet, is this wrong? Should I be using newt?

Really wasn't expecting this to take longer than to write the applet. Undecided
Offline gouessej

« In padded room »



TUER


« Reply #13 - Posted 2012-10-26 23:17:29 »

In my humble opinion, you should run some demos of JOGL deployed as applets, pick one and try to use the same source code to deploy yours. Keep in mind that JNLP protocol in applets is not fully supported by NetX / Icedtea-web. Mixing of signed and unsigned JARs has been broken, there was a regression in Icedtea-web 1.2, it has been fixed in Icedtea-web 1.3. Ask for help on the official JogAmp forum, you will get more replies than here. I'm almost the only contributor of JOGL who comes here, Xerxes and Sven rarely do it. In my humble opinion, the most important thing consists in finding at least one working example that could be a source of inspiration for you. If I were you, I would sign all JARs (including those of JOGL, GlueGen and yours) with the same certificate.

Offline cupcakey

Senior Newbie


Medals: 1



« Reply #14 - Posted 2012-10-26 23:19:50 »

Thanks alot for the advice, I'll try that route next. This has been a real headache.
Offline cupcakey

Senior Newbie


Medals: 1



« Reply #15 - Posted 2012-10-27 03:42:42 »

problem has been solved by none other then sven. I was using the wrong libraries...  persecutioncomplex

Thanks again.
http://forum.jogamp.org/Applet-deploy-serious-problems-td4026628.html
Pages: [1]
  ignore  |  Print  
 
 
You cannot reply to this message, because it is very, very old.

 

Add your game by posting it in the WIP section,
or publish it in Showcase.

The first screenshot will be displayed as a thumbnail.

xsi3rr4x (50 views)
2014-04-15 18:08:23

BurntPizza (46 views)
2014-04-15 03:46:01

UprightPath (62 views)
2014-04-14 17:39:50

UprightPath (44 views)
2014-04-14 17:35:47

Porlus (61 views)
2014-04-14 15:48:38

tom_mai78101 (84 views)
2014-04-10 04:04:31

BurntPizza (142 views)
2014-04-08 23:06:04

tom_mai78101 (242 views)
2014-04-05 13:34:39

trollwarrior1 (201 views)
2014-04-04 12:06:45

CJLetsGame (208 views)
2014-04-01 02:16:10
List of Learning Resources
by SHC
2014-04-18 03:17:39

List of Learning Resources
by Longarmx
2014-04-08 03:14:44

Good Examples
by matheus23
2014-04-05 13:51:37

Good Examples
by Grunnt
2014-04-03 15:48:46

Good Examples
by Grunnt
2014-04-03 15:48:37

Good Examples
by matheus23
2014-04-01 18:40:51

Good Examples
by matheus23
2014-04-01 18:40:34

Anonymous/Local/Inner class gotchas
by Roquen
2014-03-11 15:22:30
java-gaming.org is not responsible for the content posted by its members, including references to external websites, and other references that may or may not have a relation with our primarily gaming and game production oriented community. inquiries and complaints can be sent via email to the info‑account of the company managing the website of java‑gaming.org
Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines | Managed by Enhanced Four Valid XHTML 1.0! Valid CSS!