Author Topic: jws deployment for jpct  (Read 3044 times)

Offline bili

  • byte
  • *
  • Posts: 39
    • View Profile
jws deployment for jpct
« on: February 12, 2012, 02:55:42 pm »
Hi,

I've seen the jpct home page with demo using Java Web Start and I like to know how to do that. In particular, Im attempting to use raft's demo LoadBonesFormatSample so that player can not only view the animation but also change the texture and few other attributes of my own. I have been reading JWS on oracle doc page from last night but there is alot for me to digest and understand. Can you please outline briefly what I need to do to get JSW to work using above demo or what you did, any links would be appreciated.

Cheers.

Offline EgonOlsen

  • Administrator
  • quad
  • *****
  • Posts: 12295
    • View Profile
    • http://www.jpct.net
Re: jws deployment for jpct
« Reply #1 on: February 12, 2012, 08:32:51 pm »
  • Convert your resource loading so that resources can be loaded from a jar
  • Create jars for the native parts (i.e. the DLLs and the SOs and such) by simply zipping and renaming them to .jar
  • Create jars out of your classes and your resources
  • Sign all jars
  • Create a .jnlp-file that loads everything. You can use the ones for the demos as examples.
  • Upload the jnlp and the files to a server. Depending on the server, you might have to crate a .htaccess file make it return the proper mime-type for jnlp.


Offline bili

  • byte
  • *
  • Posts: 39
    • View Profile
Re: jws deployment for jpct
« Reply #2 on: February 12, 2012, 09:42:28 pm »
Thank you!

Offline bili

  • byte
  • *
  • Posts: 39
    • View Profile
Re: jws deployment for jpct
« Reply #3 on: February 14, 2012, 02:41:48 am »
  • Convert your resource loading so that resources can be loaded from a jar
  • Create jars for the native parts (i.e. the DLLs and the SOs and such) by simply zipping and renaming them to .jar
  • Create jars out of your classes and your resources
  • Sign all jars
  • Create a .jnlp-file that loads everything. You can use the ones for the demos as examples.
  • Upload the jnlp and the files to a server. Depending on the server, you might have to crate a .htaccess file make it return the proper mime-type for jnlp.
Sorry to trouble you again. But I need few clarification:
  • Convert your resource loading so that resources can be loaded from a jar
  I'm a little confused, java doc says to use classloader to load resources file like pictures but I have to files "*.bones* and "*.jpeg" that the game read from InputStream so does this mean I need to use the code below instead?
Code: [Select]
this.getClass().getResourceAsStream("b.bones");
  • Create jars for the native parts (i.e. the DLLs and the SOs and such) by simply zipping and renaming them to .jar
what are SOs and such? I have no DLLs as I'm running on Linux.
  • Create jars out of your classes and your resources
It doesn't matter if I use eclipse export feature or do it from termial right like jar cf <files>?
Lastly, I can test the jnlp file on local machine right just by running
Code: [Select]
javaws *.jnlp
Thanks.

Offline EgonOlsen

  • Administrator
  • quad
  • *****
  • Posts: 12295
    • View Profile
    • http://www.jpct.net
Re: jws deployment for jpct
« Reply #4 on: February 14, 2012, 06:56:31 am »
so does this mean I need to use the code below instead?
Yes.
what are SOs and such? I have no DLLs as I'm running on Linux.
But not everybody does...in lwjgl, you have folders for the different native components for each platform. I use to zip and rename them, one jar for each platform.
It doesn't matter if I use eclipse export feature or do it from termial right like jar cf <files>?
No, that doesn't matter. I just find it easier to zip them, but it's up to you.

Offline bili

  • byte
  • *
  • Posts: 39
    • View Profile
Re: jws deployment for jpct
« Reply #5 on: February 14, 2012, 11:18:11 pm »
Many thanks.