Java-Gaming.org
Play Revenge of the Titans! The situation is critical. We need fancy commanders to defend Earth, the moon, Mars!
Featured games (78)
games approved by the League of Dukes
Games in Showcase (406)
games submitted by our members
Games in WIP (293)
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  
  Midi Lag  (Read 1199 times)
0 Members and 1 Guest are viewing this topic.
Offline MBrenaman

Junior Member




Javanaut


« Posted 2004-06-20 22:15:01 »

Hey yall, I'm very new to Java sound and anyways... I'm working on a fullscreen app game for webstart and the drum tracks in my midi files are lagging alittle to much.

Right now, I'm using the MidiPlayer class I found on that Brakeen guy's site.

I'm not really sure what to do (if there's even a solution) so any input would be appreciated  Huh

-Mathew Brenaman
Offline oNyx

JGO Coder


Medals: 1


pixels! :x


« Reply #1 - Posted 2004-06-20 22:26:19 »

Bad timing and bad sound are a sure sign for not having a soundbank installed.

http://java.sun.com/products/java-media/sound/soundbanks.html

弾幕 ☆ @mahonnaiseblog
Offline MBrenaman

Junior Member




Javanaut


« Reply #2 - Posted 2004-06-21 07:35:43 »

Yawn, I took a look at the page, maybe its beacuse its 3am but does this mean that user of the game will need to download the soundbank too? I'm not really sure how this works.

-Mathew Brenaman
Games published by our own members! Check 'em out!
Try the Free Demo of Titan Attacks
Offline MBrenaman

Junior Member




Javanaut


« Reply #3 - Posted 2004-06-21 08:32:11 »

Sorry to double post but I looked around I guess I'll have to include the .gm with the game and (attempt) to load it from the games jar. This really really sucks! Why does Java always have these short comings!  Angry

EDIT: ok I got the medium soundbank file and Im running and as expected the instruments sound different. Right now I'm using Anvil Studio to edit/play midi files and it doesnt seem to have a function to load the soundbank.gm so I can edit and hear what it will sound like in my game. Is there a way or any software that will let me load the soundbank?

-Mathew Brenaman
Offline dranonymous

Junior Member




Hoping to become a Java Titan someday!


« Reply #4 - Posted 2004-06-21 14:51:24 »

You can load the sound banks and then tell the synthesizer which one to use.

[CODE]
Soundbank soundbank = MidiSystem.getSoundbank()

synth.loadAllInstruments(soundbank);
[/CODE]

synth is a synthesizer declared elsewhere in the app.  You can write a quick app to play a midi using any of the three soundbanks available from Sun.

HTH,
Aaron R>
Pages: [1]
  ignore  |  Print  
 
 
You cannot reply to this message, because it is very, very old.

Play Revenge of the Titans! The situation is critical. We need fancy commanders to defend Earth, the moon, Mars!
 
Get high quality music tracks for your game!

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

The first screenshot will be displayed as a thumbnail.

The invasion has landed! On Mars! And you're there to beat 'em!
cubemaster21 (84 views)
2013-05-17 21:29:12

alaslipknot (92 views)
2013-05-16 21:24:48

gouessej (123 views)
2013-05-16 00:53:38

gouessej (117 views)
2013-05-16 00:17:58

theagentd (127 views)
2013-05-15 15:01:13

theagentd (114 views)
2013-05-15 15:00:54

StreetDoggy (158 views)
2013-05-14 15:56:26

kutucuk (180 views)
2013-05-12 17:10:36

kutucuk (180 views)
2013-05-12 15:36:09

UnluckyDevil (187 views)
2013-05-12 05:09:57
Complex number cookbook
by Roquen
2013-04-24 12:47:31

2D Dynamic Lighting
by Oskuro
2013-04-17 16:46:12

2D Dynamic Lighting
by Oskuro
2013-04-17 16:45:57

2D Dynamic Lighting
by Oskuro
2013-04-17 16:23:20

Noise (bandpassed white)
by Roquen
2013-04-05 17:36:01

Noise (bandpassed white)
by Roquen
2013-04-03 16:17:38

Java Data structures
by Roquen
2013-03-29 13:21:12

Topic Request
by kutucuk
2013-03-22 21:42:01
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!
Page created in 0.082 seconds with 20 queries.