looping sound with a gap?

I'm trying to make a page which has a continuous sound (just for fun), but when I loop a file using embed it seems to have about a .2-.5 second gap between playing the sound again.  This causes a problem for what I am trying to do.  I tried using javascript to play the sound as well, but same problem (although the gap seemed to get shorter?).  Anyway, is there maybe a different way to loop the sound without this gap (like bgsound or an object, or a midi instead of wav)?

This needs to work for Netscape 4.x, but IE does not matter since other scripts on the page are not IE compatible (yet).

To see exactly what I am talking about goto:
http://aegis.mcs.kent.edu/~jbirk/Web/JavaScript/bees.html
Note that you need to be using Netscape 4.x to view this currently.

Thanks!
-Josh
LVL 8
jbirkAsked:
Who is Participating?
 
Michel PlungjanIT ExpertCommented:
Oh, Thanks Josh!

Michel
0
 
Michel PlungjanIT ExpertCommented:
Very cute until one discovers that there is no OFF button ;-)

Have you made sure there is no silence space at the end???

To make a seemless loop, perhaps you want to copy and reverse is since it starts high and then go low so there will always be a difference.

I think the time to rewind is what you hear <g>

Michel

Michel
0
 
jbirkAuthor Commented:
Yes, I know there is no off button :)
That's kind of the point.  It's supposed to be annoying, like the bees follow you around buzzing away, and the only way to get relief is to leave:)  Of course this is just a pgae for fun and will have nothing on it but these bees, I would never put something like this on a page with content!

I wanted to try exactly what you said about reversing it and copying it, so it matches up, and I know how to do it, except I no longer have my sound editor that will do that.  I tried to find one on the net, but all I found was some crappy editor with a ton of errors.  Any idea where I can get a free/shareware/demo of a sound editor which can do this?

Yes, I checked the sound for a gap, and it has sound throughout the entire wav file.  Have you even tried anything with continuous sound before Michel?

Thanks,
Josh
0
Ultimate Tool Kit for Technology Solution Provider

Broken down into practical pointers and step-by-step instructions, the IT Service Excellence Tool Kit delivers expert advice for technology solution providers. Get your free copy now.

 
Michel PlungjanIT ExpertCommented:
Sorry, I have not... I went to www.shareware.com, searched for wav and found several nice utilities that did not want to edit the bees.wav
Perhaps you can use the wavemix 2.0 on a resampled file...

Michel
0
 
jbirkAuthor Commented:
OK, I found an editor to do the trick.  I searched on www.danworld.com.  There were quite a few sound editors there.  Anyway now the sound contains a reverse image of itself appended on the end (I also cut out half of the original sound to ensure that there IS no gap in the wav fiel...).  Go check it out.  It still has that annoying gap.  You can see why in this situation a gap is not desirable!

If no solution is available, I may end up just using a large file that's like 25 seconds of swarming bees, so that the gap doesn't occur very often, it just takes forever to download the stupid sound file (probably preload it in previous page).
-Josh
0
 
SirCalebCommented:
You might also want to consider using a free program called GoldWave...it is nice for editing wav files and you can even loop the wav file in the editor to see how it sounds when it is looped....here is the URL for it....

http://www.goldwave.com/


0
 
jbirkAuthor Commented:
Actually SirCaleb, that is one of the sound editors I downloaded from danworld!
-Josh
0
 
Michel PlungjanIT ExpertCommented:
Have you tried to set
LOOP=true in your embed?

Michel
0
 
jbirkAuthor Commented:
Yeah... to same effect.
How do you loop in bgsound so I can try that?
Also, is there a way to use an <OBJECT> tag to play sounds in netscape?  I know that's supported in IE, but if it could work in Netscape, then maybe that wouldn't have the gap problem.

It looks however, that I can not get rid of that.  Also I noticed that on a machine with more RAM the gap is less, so maybe it's just the reloading of it into memory that's causing the small gap, meaning that I can't do anything, so I'll probably just use a longer wav file so the gap occurs less often, and is less noticable/annoying.

thanks,
josh
0
 
Michel PlungjanIT ExpertCommented:
<OBJECT would afaik only work with the ActiveX plugin
loop=1 in bgsound

Why not try a Java sound applet instead?
Should work in both (32bit) browsers and can be scripted too

Michel
0
 
jbirkAuthor Commented:
Never done anything like that... have such an applet lying around on your hard drive you could share (and how to use it)?
I played with Java for a short while, but gave up on it...
It was also my first intro to OOP and I really had no idea what was going on.  Now that I know C++ and understand OOP better, I could probably learn it a lot easier... but I just don't have the time, and I haven't seen that many good uses for Java other than Chat rooms, so I haven't bothered.
-josh
0
 
Michel PlungjanIT ExpertCommented:
Sorry, nope - my Java is strictly serious <g>
There MUST be several java sound players at www.gamelan.com

Michel
0
 
jbirkAuthor Commented:
Well, it looks like this is a no winner...  I will try the java idea later, though I was kind of looking for a javascript technique.

Thank you for your help Michel.  Please answer the question so that I can award you the points for your help.
-Josh
0
 
jbirkAuthor Commented:
No prob, thanks for the help!
-Josh
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.