[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSSound and gsnd

From: Enrico Sersale
Subject: Re: NSSound and gsnd
Date: Thu, 1 Aug 2002 17:11:08 +0300 (EEST)

On Thu, 1 Aug 2002, Yen-Ju Chen wrote:

>   I agree that NSSound should be simple.
>   I think I should emphsize my point on gsnd.
>   Right now, gsnd only accept the whole decoded data,
>   which cause the problem for big files.
>   And since gsnd is the official sound daemon of GNUstep,
>   it would be nice that it could offer some other interfaces
>   that applications can feed the data piece by piece.
>   Do you have any plan to do that ?

I've already replied to this in the last mail ;-)

I wrote:
"... Not being a part of gui but only a tool, I think that it could be
easyly modified to accept also, for example, a NSFileHandle or a NSPipe
from which read the data to play."

Now, how and when to do this... is an other thing. Probably after the next
release of GWorkspace.

Anyway, gsnd is not a *my* program ;-) What I have written is only the
first implementation. It is a part of GNUstep and, probably, also other
people will work on it.

>   By the way, maybe libsndfile
>   (http://www.zip.com.au/~erikd/libsndfile/)
>   could be another choice as external library.
>   It is highly portable, and I think the most
>   important point is that it is still under active developement.
>   That's just a little suggestion.
>   Yen-Ju

Well, the choose has been libaudiofile because I've noticed that it is
already present in many linux distributions...
Anyway, I'll take a look at libsndfile.

> >From: Enrico Sersale <address@hidden>
> >To: Yen-Ju Chen <address@hidden>
> >CC: <address@hidden>
> >Subject: Re: NSSound and gsnd
> >Date: Thu, 1 Aug 2002 13:24:17 +0300 (EEST)
> >
> >
> >On Wed, 31 Jul 2002, Yen-Ju Chen wrote:
> >
> > > Hi,
> > >
> > >   I just notice that NSSound and gsnd are in CVS.
> > >   And it seems that NSSound will decode the whole file at once.
> > >   If I want to write a NSSound subclass which can handle MP3/OGG,
> > >   it will takes a lot of time to decode the whole file
> > >   before sent them into gsnd.
> > >   Is there any way, or plan, that NSSound can send the data
> > >   piece by piece to gsnd so that it doesn't need to decode
> > >   the whole file at once.
> > >
> > >   Thanx.
> > >
> > >   Yen-Ju
> >
> >If you want to see an example of sound class that plays from a stream,
> >take a look at the MusicKit. I think that it does exactly wath you want.
> >
> >Writing this implementation of NSSound I wanted only to create a simple,
> >portable and efficient interface to play "system sounds". It is part of
> >the gui library and my concern was to not add, how is possible,
> >dependencies on external libraries, threads or other strange things. The
> >only external library used is libaudiofile, a very portable c library that
> >builds on many unix and on windows.
> >
> >I've not a Mac to test this, but I think that also the apple
> >implementation doesn't do much more. From their documentation:  "The
> >NSSound class provides a simple interface for loading and playing AIFF,
> >WAV, and NeXT ".snd" files. NSSound supports 16bit, mono and stereo,
> >44.1KHz and 22.05KHz data."  (BTW actually we support more formats and any
> >frame rate)
> >
> >Said that, I must also add that gsnd is an other think. Not being a part
> >of gui but only a tool, I think that it could be easyly modified to accept
> >also, for example, a NSFileHandle or a NSPipe from which read the data to
> >play.
> _________________________________________________________________
> Join the world’s largest e-mail service with MSN Hotmail.
> http://www.hotmail.com
> _______________________________________________
> Discuss-gnustep mailing list
> address@hidden
> http://mail.gnu.org/mailman/listinfo/discuss-gnustep

reply via email to

[Prev in Thread] Current Thread [Next in Thread]