Java-Gaming.org    
Featured games (81)
games approved by the League of Dukes
Games in Showcase (498)
Games in Android Showcase (115)
games submitted by our members
Games in WIP (562)
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  
  JWS and net.games.sound3d  (Read 3188 times)
0 Members and 1 Guest are viewing this topic.
Offline Conzar

Junior Member




There is nothing common about common sense


« Posted 2007-05-10 22:01:06 »

The current problem that I am encountering is loading files in JWS with the sound3d package.  Is there an easy way of doing this?  Or do I need to ditch the sound3d package and use the underlying packages (this is not preferable).

I found how to load files using the joal native packages and the code below shows this.
1  
SingleStaticSource.class.getClassLoader().getResourceAsStream("demos/data/FancyPants.wav")


The problem with my code is that I'm using the net.java.games.sound3d package.  The only option I have for loading a buffer is to provide a String shown below.

1  
Buffer loadBuffer(String filename)


When this method is used while deployed in JWS, the file is unable to load (even if you call getResouce and convert the URL into a String).

If there isn't a way to load sound files with sound3d and jws, then how difficult would it be for someone to add this?  Could I checkout the source and attempt this - or is the learning curve on working with this code too great to make it worth my time?

Thanks

Ubuntu
Offline Ken Russell

JGO Coder




Java games rock!


« Reply #1 - Posted 2007-05-13 05:32:37 »

It would be very good if you would try this out and contribute code. Nobody is really looking at the Sound3D implementation at this point and it was never retrofitted to work well in a Java Web Start environment. If you look at what was done with the JOAL ALut it should be pretty easy (actually, the Sound3D stuff can probably be implemented on top of ALut or the WAVLoader).
Offline Conzar

Junior Member




There is nothing common about common sense


« Reply #2 - Posted 2007-05-13 21:01:16 »

Alrighty then Smiley

So I've actually checked it out via cvs and modified the code.  You were right.  This was pretty easy.  I have yet to test this via jws; however, I have tested it using the newly joal.jar file that I created!.

I've added a method in the AudioSound3D class shown below
1  
public static Buffer loadBuffer(InputStream stream)


Anyways, using the inputStream works fine using the jar.  So my question is, how do I try this out using jws?  For my game, I'm pointing jws to the download.java.net/media/joal/webstart/joal.jnlp

Also, once this is tested out more thouroughly, am I able to check in changes?  How would these changes be applied to the jws delpoyed joal?

Thanks

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

JGO Coder




Java games rock!


« Reply #3 - Posted 2007-05-14 03:38:54 »

File a Patch with the Issue Tracker on the JOAL home page and we'll check it in for you.

You can test your changes by hosting your own copy of joal.jar, the joal native library jars, and a joal.jnlp on your own web server and pointing your extension href to that. Or we can check in the changes (assuming they look OK) and we'll update the main JNLP.
Offline Conzar

Junior Member




There is nothing common about common sense


« Reply #4 - Posted 2007-05-14 12:38:36 »

Sounds good.  I'll send a patch later tonight when I get home.

Ubuntu
Offline Conzar

Junior Member




There is nothing common about common sense


« Reply #5 - Posted 2007-05-15 02:40:19 »

Alrighty, I posted the patch --- Issue #18.

I hope I did this right, let me know otherwise.

Ubuntu
Offline Ken Russell

JGO Coder




Java games rock!


« Reply #6 - Posted 2007-05-16 07:09:04 »

Yes, thanks. It's been checked in.
Offline Conzar

Junior Member




There is nothing common about common sense


« Reply #7 - Posted 2007-05-16 23:47:01 »

How long does it take for it to get rolled into the JWS distro?

Ubuntu
Offline Ken Russell

JGO Coder




Java games rock!


« Reply #8 - Posted 2007-05-17 14:03:42 »

I have a to-do item to re-push the JWS binaries, and also to incorporate one bug fix to the EFX functions that isn't quite complete. As soon as our Linux build machine comes back on line (hopefully today) I'll try to take care of both of these items.
Offline Conzar

Junior Member




There is nothing common about common sense


« Reply #9 - Posted 2007-05-18 00:36:30 »

Awesome - sounds good man.  Thanks!

Ubuntu
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.

radar3301 (9 views)
2014-09-21 23:33:17

BurntPizza (28 views)
2014-09-21 02:42:18

BurntPizza (18 views)
2014-09-21 01:30:30

moogie (20 views)
2014-09-21 00:26:15

UprightPath (27 views)
2014-09-20 20:14:06

BurntPizza (29 views)
2014-09-19 03:14:18

Dwinin (46 views)
2014-09-12 09:08:26

Norakomi (74 views)
2014-09-10 13:57:51

TehJavaDev (102 views)
2014-09-10 06:39:09

Tekkerue (50 views)
2014-09-09 02:24:56
List of Learning Resources
by Longor1996
2014-08-16 10:40:00

List of Learning Resources
by SilverTiger
2014-08-05 19:33:27

Resources for WIP games
by CogWheelz
2014-08-01 16:20:17

Resources for WIP games
by CogWheelz
2014-08-01 16:19:50

List of Learning Resources
by SilverTiger
2014-07-31 16:29:50

List of Learning Resources
by SilverTiger
2014-07-31 16:26:06

List of Learning Resources
by SilverTiger
2014-07-31 11:54:12

HotSpot Options
by dleskov
2014-07-08 01:59:08
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!