[vorbis] ao_arts

rik at kde.org rik at kde.org
Wed Dec 27 19:50:11 PST 2000



#if Kenneth C. Arnold
> > +SUBDIRS = oss esd alsa arts # solaris irix
> 
> To everybody else also:
> 
> I DON'T LIKE THAT. Evil. SUBDIRS should be only what you can build on
> your system, as autodetected [...]

I agree. It seems the current approach is to create makefiles in the
subdirs but do the disabling within those makefiles. I presume you're
thinking of having SUBDIRS = $(OSS_SUBDIR) $(ESD_SUBDIR) etc. Much
more sensible IMO.

> >   if (NULL == state)
> 
> You have weird coding conventions. On the other hand, I know why you
> do this. gcc gives a warning in either case.

Yes. For anyone who doesn't know why I write comparisons backwards,
it's to avoid doing 'if (state = NULL)' instead of 'if (state == NULL)'.
It only looks odd for the first 3 months that you do it ;)

> >   errorcode = arts_init();
> > 
> >   if (0 != errorcode)
> 
> ditto. My personal preference is to put that all on one line, e.g.
> if (0 != (errorcode = arts_init()))

I would... but my eyes are poor and putting many operations together
on a line confuses them. Unless I'm going for ultra-efficiency, I space
everything out as much as possible.

> >   state->stream = arts_play_stream(rate, bits, channels, "ao stream");
> 
> So aRts has a stream name capability? Perhaps libao could use a stream
> name parameter; could be useful.

I didn't know quite what to do with this, as many apps using libao could
have a stream called "ao stream". I suppose the idea is you can generate
an unique key, but we have the returned void * anyway. It's useful for
easier IPC or something, I guess.

Cheers,
Rik

--- >8 ----
List archives:  http://www.xiph.org/archives/
Ogg project homepage: http://www.xiph.org/ogg/
To unsubscribe from this list, send a message to 'vorbis-request at xiph.org'
containing only the word 'unsubscribe' in the body.  No subject is needed.
Unsubscribe messages sent to the list will be ignored/filtered.



More information about the Vorbis mailing list