1. RE: How to play more wav files

Kat wrote:
> On 10 Dec 2001, at 17:05, vkusnirak at usske.sk wrote:
> 
> > 
> > Hello,
> > 
> > I was made simple program, that play 50    *.wav files. But I can play 
> > only 40
> > files. When I'm playing 41 .. 50, there is only some "creak sound"... 
> > correct is
> > only first 40. can somebody help me ?
> 
> There is a limit to how many files you can have open at one time, are 
> you 
> closing the *.wav files after you load them, before you play them?
> 
> Kat

The function LoadSoundEffects() is doing close(FHandle) :(
I don't know what to do ... 
> 
> > Sorry for my poor English...
> > I'm begginer in Euphoria...
> > 
> > Also I was trying to use function LoadSound Effects() always before 
> > playing a
> > wav, but after 40th it was play again "creak sound"   :(
> > 
> > -- steps:
> > -- 1) load all sounds in buffers,  use LoadSoundEffects().
> > -- 2) Open volumes (master, voice) set speaker on with SpeakerOn()
> > -- 3) when you need a sound effect call PlaySoundEffect() (see below)
> > -- **** NOTE: it plays only 8 bits wave files.
> > 
> > -- NOTE: don't forget to set WAV_DIR to your own wave directory
> > 
> > without warning
> > include file.e
> > include delay.e
> > include doswrap.e
> > include soundfx.e
> > 
> > DmaChannel = DMA8 -- only play 8 bit sound.
> > 
> > integer counter
> > counter = 1
> > -- 1) Load sound effect in DMA buffers
> > 
> > sequence SoundEffects -- contain parameter for each sound effect.
> > -- needed parameters: {buffer,Size,TimeConstant, channels}
> > 
> > constant -- list of wave files to load in buffers.
> >  SoundFiles = {"1.wav","2.wav","3.wav","4.wav","5.wav","6.wav",
> >        "7.wav","8.wav","9.wav","10.wav","11.wav","12.wav",
> >        "13.wav","14.wav","15.wav","16.wav","17.wav","18.wav",
> >        "19.wav","20.wav","21.wav","22.wav","23.wav","24.wav",
> >        "25.wav","26.wav","27.wav","28.wav","29.wav","30.wav",
> >        "31.wav","32.wav","33.wav","34.wav","35.wav","36.wav",  
> >                       
> >                        "37.wav","38.wav","39.wav","40.wav","41.wav","42.wav",
> >        "43.wav","44.wav","45.wav","46.wav","47.wav","48.wav",
> >         "49.wav","50.wav"}
> > 
> >  SoundEffects = LoadSoundEffects(SoundFiles)
> > 
> > 
> > integer key
> >   key = 0
> > -- 2) open volume
> >   SetVolume(MASTER_VOLUME,VOL_MAX)
> >   SetVolume(VOICE_VOLUME,2)
> >   while key != 27 do
> > 
> >     key = get_key() 
> >     poke(#41A,peek({#41C,2})) -- clean keyboard buffer
> > 
> >  PlaySoundEffect(SoundEffects[counter])
> >  counter = counter + 1
> >  if counter = 50 then
> >   counter = 1
> >  end if 
> >      delay(2.0)
> > 
> >   end while
> > 
> >

new topic     » topic index » view message » categorize

2. RE: How to play more wav files

Vlado wrote:

> > > I was made simple program, that play 50    *.wav files. But I can play 
> > > only 40
> > > files.
 When I'm playing 41 .. 50, there is only some "creak sound"...

Vlado:
   Be sure that files 41 .. 50 are same type of files ( 8 bit etc. )
   Try using 1 .. 10 over again in place of 41 .. 50.
   The "creak sound" maybe caused by the bits in the files
   be play at the wrong speed.
Bernie

new topic     » goto parent     » topic index » view message » categorize

3. Re: RE: How to play more wav files

11.12.2001 21:16:26, Bernie Ryan <xotron at localnet.com> wrote:

>
>
>Vlado wrote:
>
>> > > I was made simple program, that play 50    *.wav files. But I can play 
>> > > only 40
>> > > files.
> When I'm playing 41 .. 50, there is only some "creak sound"...
>
>Vlado:
>   Be sure that files 41 .. 50 are same type of files ( 8 bit etc. )
>   Try using 1 .. 10 over again in place of 41 .. 50.
>   The "creak sound" maybe caused by the bits in the files
>   be play at the wrong speed.
>Bernie

I used for all 1.. 50 the same 1.wav file and after 44-th ? loading 
I had a "creak sound" for next 6 wav files. When I was playing again 1-st wav ..
44th, that
was ok ..but after ...:(

The wav files are 11000Hz 8bit mono ... I've tested it with goldwave.

Thanx Vlado

new topic     » goto parent     » topic index » view message » categorize

Search



Quick Links

User menu

Not signed in.

Misc Menu