www.jpct.net

jPCT - a 3d engine for Java => Support => Topic started by: bili on February 12, 2012, 02:55:42 pm

Title: jws deployment for jpct
Post by: bili 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.
Title: Re: jws deployment for jpct
Post by: EgonOlsen on February 12, 2012, 08:32:51 pm

Title: Re: jws deployment for jpct
Post by: bili on February 12, 2012, 09:42:28 pm
Thank you!
Title: Re: jws deployment for jpct
Post by: bili 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:
  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"); what are SOs and such? I have no DLLs as I'm running on Linux.
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.
Title: Re: jws deployment for jpct
Post by: EgonOlsen 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.
Title: Re: jws deployment for jpct
Post by: bili on February 14, 2012, 11:18:11 pm
Many thanks.