tir, 06 01 2009 kl. 13:06 -0500, skrev David:
> That's OK with me, if the consensus is to include my code in the same
> package, although I'm not using any of the functions in the Audio pkg
> (at first, I thought I might, but I haven't had any reason to do so).
> However, all my code is really aimed at musical applications, and I
> don't think it would be of any use to people interested in voice
> recognition, speech generation or other audio apps. I'd prefer to make
> it a separate package (called 'music', for example).

I don't have any strong opinions here. I'm trying to see this from the
users point of view. If I was working on music I would definitely
install the Audio package. And I would do this without looking too much
at the actual functions, simply because the name of the package sounds
relevant. So, if you make a 'music' package, then I would assume that
its users would also install the 'audio' package.

But, hey, it's your code, so you should decide :-) 

> I do have a couple of questions about the existing code in the Audio
> pkg. First of all, the 'aurecord()' function seems to be missing from
> the Windows binary (I'm using Octave 3.0.1). 

I'm guessing the code is GNU/Linux specific, and hasn't been ported to
Windows, but I don't know.

> Secondly, on line 41 of 'au.m' (version 1.1.1 of Audio), there's the
> following code, which seems to be meant to swap the values of two
> parameters, but it doesn't seem like it would work to me:
>  
>   if hi<lo, t=hi; hi=lo; lo=hi; endif
> 
> Shouldn't it be changed to this?
>  
>   if hi<lo, t=hi; hi=lo; lo=t; endif

Looks like you're right. Feel free to change this, once you get commit
access.

> Also, I'm doing my development on Windows XP, using Octave 3.0.1. If
> anyone is using Octave on other platforms and would like to test it
> there, I'd appreciate it.

When you have specific tests you'd like others to run, just post the
code on this list, and somebody will probably help you out.

> I'll try to post some code by the end of the week. At the moment, I've
> got all my code in a single file. Is it a standard or convention to
> have one source file per function? If so, where should global
> variables be defined? Or is the use of global variables frowned upon?

In general we tend to keep one function per file, unless the functions
are internal and not meant to be used by the end-user. You could also
consider using 'private' directories (these are, however, only supported
by the development version of Octave)

As to global variables, they are usually frowned upon. Remember that
these are cleared when the user does a 'clear all' (at least, I think
they are, I'm not sure). Anyway, in the end it is the person who writes
the code, who gets to decide.

Søren
> 


------------------------------------------------------------------------------
Check out the new SourceForge.net Marketplace.
It is the best place to buy or sell services for
just about anything Open Source.
http://p.sf.net/sfu/Xq1LFB
_______________________________________________
Octave-dev mailing list
Octave-dev@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/octave-dev

Reply via email to