PC Review


Reply
Thread Tools Rate Thread

Playing sounds causes unwanted pauses

 
 
Dom
Guest
Posts: n/a
 
      15th Jul 2003
I'm playing sounds from memory but they're causing my game's graphics to
pause. Does anybody know how to get around this ?
Thanks,
Dom


 
Reply With Quote
 
 
 
 
Chris Tacke, eMVP
Guest
Posts: n/a
 
      15th Jul 2003
Are you playing the sounds on a separate thread?

--
Chris Tacke, eMVP
Advisory Board Member
www.OpenNETCF.org
---
Windows CE Product Manager
Applied Data Systems
www.applieddata.net


"Dom" <(E-Mail Removed)> wrote in message
news:%23%(E-Mail Removed)...
> I'm playing sounds from memory but they're causing my game's graphics to
> pause. Does anybody know how to get around this ?
> Thanks,
> Dom
>
>



 
Reply With Quote
 
 
 
 
Steven Licciardi
Guest
Posts: n/a
 
      15th Jul 2003
Are you playing it asynchronously using something like:

PlaySound(bstr, IntPtr.Zero, SND_ASYNC Or SND_MEMORY)

Or are you still getting the delay doing it this way?
Steven

"Dom" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> As ever you are a shining light Chris ! I take it using threads will cure
> the issue ? That is fantastic.
> Thanks,
> Dom
> "Chris Tacke, eMVP" <(E-Mail Removed)> wrote in message
> news:#(E-Mail Removed)...
> > Are you playing the sounds on a separate thread?
> >
> > --
> > Chris Tacke, eMVP
> > Advisory Board Member
> > www.OpenNETCF.org
> > ---
> > Windows CE Product Manager
> > Applied Data Systems
> > www.applieddata.net
> >
> >
> > "Dom" <(E-Mail Removed)> wrote in message
> > news:%23%(E-Mail Removed)...
> > > I'm playing sounds from memory but they're causing my game's graphics

to
> > > pause. Does anybody know how to get around this ?
> > > Thanks,
> > > Dom
> > >
> > >

> >
> >

>
>



 
Reply With Quote
 
Henrik Dahl
Guest
Posts: n/a
 
      15th Jul 2003
Dom,

Try to initiate the garbage collector just before, so it will not succeed in
anything while this is going on.


Best regards,

Henrik Dahl

"Dom" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> Hello Steven,
> Yep that is identical to my Play Sound command. Also I tried threading but
> with no luck. It is only a small delay when a sound is played but it is
> noticeable and makes it look extremely amateurish. Any other ideas

welcome.
> Thanks,
> Dom
> "Steven Licciardi" <(E-Mail Removed)> wrote in
> message news:(E-Mail Removed)...
> > Are you playing it asynchronously using something like:
> >
> > PlaySound(bstr, IntPtr.Zero, SND_ASYNC Or SND_MEMORY)
> >
> > Or are you still getting the delay doing it this way?
> > Steven
> >
> > "Dom" <(E-Mail Removed)> wrote in message
> > news:(E-Mail Removed)...
> > > As ever you are a shining light Chris ! I take it using threads will

> cure
> > > the issue ? That is fantastic.
> > > Thanks,
> > > Dom
> > > "Chris Tacke, eMVP" <(E-Mail Removed)> wrote in message
> > > news:#(E-Mail Removed)...
> > > > Are you playing the sounds on a separate thread?
> > > >
> > > > --
> > > > Chris Tacke, eMVP
> > > > Advisory Board Member
> > > > www.OpenNETCF.org
> > > > ---
> > > > Windows CE Product Manager
> > > > Applied Data Systems
> > > > www.applieddata.net
> > > >
> > > >
> > > > "Dom" <(E-Mail Removed)> wrote in message
> > > > news:%23%(E-Mail Removed)...
> > > > > I'm playing sounds from memory but they're causing my game's

> graphics
> > to
> > > > > pause. Does anybody know how to get around this ?
> > > > > Thanks,
> > > > > Dom
> > > > >
> > > > >
> > > >
> > > >
> > >
> > >

> >
> >

>
>



 
Reply With Quote
 
Henrik Dahl
Guest
Posts: n/a
 
      15th Jul 2003
OK,

In the full framework you may give the time to some other thread, as far as
I remember it's by Thread.Sleep(0). What if you do this just before you
play?


Best regards,

Henrik Dahl

"Dom" <(E-Mail Removed)> wrote in message
news:%23rI$(E-Mail Removed)...
> Sadly no luck Henrik. It's as smooth as anything so long as I don't use
> sounds :0(
> Dom
>
> "Henrik Dahl" <(E-Mail Removed)2.dk> wrote in message
> news:u3#(E-Mail Removed)...
> > Dom,
> >
> > Try to initiate the garbage collector just before, so it will not

succeed
> in
> > anything while this is going on.
> >
> >
> > Best regards,
> >
> > Henrik Dahl
> >
> > "Dom" <(E-Mail Removed)> wrote in message
> > news:(E-Mail Removed)...
> > > Hello Steven,
> > > Yep that is identical to my Play Sound command. Also I tried threading

> but
> > > with no luck. It is only a small delay when a sound is played but it

is
> > > noticeable and makes it look extremely amateurish. Any other ideas

> > welcome.
> > > Thanks,
> > > Dom
> > > "Steven Licciardi" <(E-Mail Removed)> wrote in
> > > message news:(E-Mail Removed)...
> > > > Are you playing it asynchronously using something like:
> > > >
> > > > PlaySound(bstr, IntPtr.Zero, SND_ASYNC Or SND_MEMORY)
> > > >
> > > > Or are you still getting the delay doing it this way?
> > > > Steven
> > > >
> > > > "Dom" <(E-Mail Removed)> wrote in message
> > > > news:(E-Mail Removed)...
> > > > > As ever you are a shining light Chris ! I take it using threads

will
> > > cure
> > > > > the issue ? That is fantastic.
> > > > > Thanks,
> > > > > Dom
> > > > > "Chris Tacke, eMVP" <(E-Mail Removed)> wrote in

message
> > > > > news:#(E-Mail Removed)...
> > > > > > Are you playing the sounds on a separate thread?
> > > > > >
> > > > > > --
> > > > > > Chris Tacke, eMVP
> > > > > > Advisory Board Member
> > > > > > www.OpenNETCF.org
> > > > > > ---
> > > > > > Windows CE Product Manager
> > > > > > Applied Data Systems
> > > > > > www.applieddata.net
> > > > > >
> > > > > >
> > > > > > "Dom" <(E-Mail Removed)> wrote in message
> > > > > > news:%23%(E-Mail Removed)...
> > > > > > > I'm playing sounds from memory but they're causing my game's
> > > graphics
> > > > to
> > > > > > > pause. Does anybody know how to get around this ?
> > > > > > > Thanks,
> > > > > > > Dom
> > > > > > >
> > > > > > >
> > > > > >
> > > > > >
> > > > >
> > > > >
> > > >
> > > >
> > >
> > >

> >
> >

>
>



 
Reply With Quote
 
SeanC
Guest
Posts: n/a
 
      15th Jul 2003
I have a freeware sound library on my site (www.intuitex.com) that I use
in my game. No noticable pauses when playing sounds. Plays/mixes waves
and mod files.

Regards

Sean
---------------------------------------
Sean Cross
(E-Mail Removed)

Pics Print - The photo printing solution for Windows.
http://www.picsprint.com

http://www.Intuitex.com -
Multimedia software for Windows
Game libraries for the dot net compact framework
 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Pauses then starts and then pauses jmo234@gmail.com Microsoft Excel Discussion 0 14th Jan 2008 08:19 AM
Unwanted music keeps on playing, and playing.... =?Utf-8?B?Rmx5aW5nUGVvcGhpbnM=?= Windows XP Music 1 8th Aug 2006 07:49 PM
Mouse pauses and plays sounds roma cox Windows XP New Users 3 3rd Jul 2006 02:50 AM
System pauses (a while) before alert sounds? =?Utf-8?B?SHVtcHR5ZGFuaw==?= Microsoft Windows 2000 1 1st May 2005 03:05 AM
CD Playing Pauses =?Utf-8?B?RGlja3Jl?= Windows XP Help 1 3rd Jan 2004 08:31 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 10:02 PM.