Please login or register.

Login with username, password and session length
Advanced search  

News:

For WME related articles and tutorials visit WME Resource Center.

Author Topic: Sound pause before playback  (Read 3179 times)

0 Members and 1 Guest are viewing this topic.

Turion

  • Lurker
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 4
    • View Profile
Sound pause before playback
« on: April 18, 2012, 09:02:23 PM »

Greetings!

I'm rather new to WME but I very much like it already, since it's free and does have excellent documentation.
I threw together a rather simple test scene and have been facing a pretty annoying problem:
When I start walking around and it comes to footsteps, there's a little pause before the playback of the sound. I'm using a 44K / 128 kbit / Stereo Vorbis file for the footstep, but it happens with a PCM Wav too.
I've recorded a short video of it:
MediaFire
It's noticeable in the first 10 seconds, especially the first step.

So now the question is:
What could be causing this?

Surprisingly, when I started frapsing, the problem more or less solved itself as you can see on the video - since it happens only in the beginning.

Could it be possible, that because I have C1E + Cool & Quiet enabled, the processor clock would be too low for playback? O.o
(It underclocks to ~800Mhz during idle) Since WME itslelf doesn't really do anything much to the processor, it could very well be idling, if my guess is correct.
It would be just great if someone could confirm this.

-Turion
Logged

metamorphium

  • Global Moderator
  • Addicted to WME forum
  • *
  • Karma: 12
  • Offline Offline
  • Gender: Male
  • Posts: 1511
  • Vampires!
    • View Profile
    • CBE  software s.r.o.
Re: Sound pause before playback
« Reply #1 on: April 19, 2012, 12:09:21 AM »

a few things to check:

1. is the file starting right away (no delays in the sample itself)?
2. What method are you using for playing the sound? If it's event based, are you starting on the right animation frame?
3. Sounds can be preloaded to eliminate the disk load overhead.
Logged
J.U.L.I.A. Enhanced Edition, Vampires!, J.U.L.I.A., J.U.L.I.A. Untold, Ghost in the Sheet

Turion

  • Lurker
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 4
    • View Profile
Re: Sound pause before playback
« Reply #2 on: April 19, 2012, 09:28:04 AM »

1. Check. I cut it myself in Sound Forge, no problems there.
2. Event based, the timing as is precise as it can be.
3. Sounds interesting, this might be the problem, since nothing is preloaded actually, sounds and everything else is loaded "on-the-fly". Can I get any help with preloading important files? Or if it's in the documentation, what should I search for?
Logged

metamorphium

  • Global Moderator
  • Addicted to WME forum
  • *
  • Karma: 12
  • Offline Offline
  • Gender: Male
  • Posts: 1511
  • Vampires!
    • View Profile
    • CBE  software s.r.o.
Re: Sound pause before playback
« Reply #3 on: April 19, 2012, 04:02:54 PM »

Code: WME Script
  1. actor.LoadSound("some file");
  2. ...
  3. ...
  4.  
  5. // elsewhere
  6. actor.PlaySound(false);
  7.  
Logged
J.U.L.I.A. Enhanced Edition, Vampires!, J.U.L.I.A., J.U.L.I.A. Untold, Ghost in the Sheet

Turion

  • Lurker
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 4
    • View Profile
Re: Sound pause before playback
« Reply #4 on: April 19, 2012, 09:29:08 PM »

Thank you!
Logged
 

Page created in 0.07 seconds with 22 queries.