[Csnd] editing audio to zero crossings from the command line.
Date | 2009-02-25 23:57 |
From | Greg Schroeder |
Subject | [Csnd] editing audio to zero crossings from the command line. |
Hey all,
Does anyone here edit audio for looping oscillators from the command line? I'm currently trying to cobble together a workflow that doesn't need x11, and I don't know how to find zero crossings without "looking" at the sound.
As always, gpl'ed and currently-maintained is best . . .
Greg
|
Date | 2009-02-26 00:03 |
From | peiman khosravi |
Subject | [Csnd] Re: editing audio to zero crossings from the command line. |
Most wave editors have a snap to zero crossing function. I am not sure about audacity but peak and soundtrack pro do. You probably knew this anyway! Best Peiman 2009/2/26 Greg Schroeder |
Date | 2009-02-26 00:12 |
From | Greg Schroeder |
Subject | [Csnd] Re: Re: editing audio to zero crossings from the command line. |
I am not sure about audacity . . . "from the command line" . . .
. . . "doesn't need x11" . . .
peak and soundtrack
" . . .gpl'ed . . . "
" . . . command line . . ."
I know there are myriad ways to find zero crossings in software, Peiman. I want to find and edit to them without a graphical interface to accomodate a relatively sluggish computer.
Greg
2009/2/26 Greg Schroeder <gmschroeder@gmail.com>: |
Date | 2009-02-26 00:17 |
From | Jonathan vanAtom |
Subject | [Csnd] Re: editing audio to zero crossings from the command line. |
It would be an interesting idea to create a command line utility to analyze, find and crop single-cycle loops from an audio file (is this what you mean?) but I don't think any such tool currently exists "from the command line." However, if you do have to "look" at the sound, peak is the way to go. It's all about the "Loop Tuner" and it does, of course, snap to zero crossings. It shouldn't take very much system resources and you could probably still get an earlier version that would work on an older computer. I know the process takes a bit of time and attention, and it would certainly be a daunting task if you have a lot files that need this processing, but it will be a good job in the end. I really like the idea of a command line utility though. Something like that shouldn't difficult to create because the pop that we hear from a poorly tuned loop is so easily detectable. JvA --------- http://music.jonathanvanatom.com http://www.myspace.com/vanatom cyberiam@yahoo.com On Feb 25, 2009, at 6:57 PM, Greg Schroeder wrote: > Hey all, > Does anyone here edit audio for looping oscillators from the command > line? I'm currently trying to cobble together a workflow that > doesn't need x11, and I don't know how to find zero crossings > without "looking" at the sound. > As always, gpl'ed and currently-maintained is best . . . > Greg |
Date | 2009-02-26 00:18 |
From | David Akbari |
Subject | [Csnd] Re: Re: Re: editing audio to zero crossings from the command line. |
With a little intuition this should be perfectly possible in Csound. Have you considered thinking about an orc that analyzes each sample of an audio file and call it a "zero crossing" when the scalar pressure values to represent amplitude change signs? (ie. from positive to negative and vice-versa) Perhaps the source code to the waveset opcode may be a good place to start. In the abstract, to answer your question I think Csound is probably the best tool for this. -David On Wed, Feb 25, 2009 at 6:12 PM, Greg Schroeder |
Date | 2009-02-26 00:27 |
From | DavidW |
Subject | [Csnd] Re: Re: Re: editing audio to zero crossings from the command line. |
Do you write python? It's not a problem to pull the file into a numpy array and search / edit to your heart's content. D. On 26/02/2009, at 11:12 AM, Greg Schroeder wrote: > > I am not sure about audacity > . . . "from the command line" . . . > . . . "doesn't need x11" . . . > peak and soundtrack > " . . .gpl'ed . . . " > " . . . command line . . ." > > I know there are myriad ways to find zero crossings in software, > Peiman. I want to find and edit to them without a graphical > interface to accomodate a relatively sluggish computer. > Greg > > > > 2009/2/26 Greg Schroeder |
Date | 2009-02-26 02:20 |
From | Greg Schroeder |
Subject | [Csnd] Re: Re: Re: Re: editing audio to zero crossings from the command line. |
>Have you considered thinking about an orc that analyzes each sample of
>an audio file and call it a "zero crossing" when the scalar pressure >values to represent amplitude change signs? (ie. from positive to >negative and vice-versa) Sure haven't.
>Perhaps the source code to the waveset opcode may be a good place to
>start. In the abstract, to answer your question I think Csound is >probably the best tool for this. I'll be darned. I thought this sounded like a relatively obvious thing someone would have put together by now, and this whole "looking at code' thing after one month of recreationally working at Csound and having taught myself some very entry-level C (that's it.) is a bit intimidating. I'll give it a shot, though.
>Do you write python?
>It's not a problem to pull the file into a numpy array and search /edit to your heart's content. >D. Sure don't. I had a vague sense that python was a little cpu-heavy, but again, I'll have a look. It just seemed with all the SoX, ecasound, etc., there would be something (perhaps even a simple ladspa plugin?) written to do this. Did people just not make looping oscillators back in the day?
Greg On Thu, Feb 26, 2009 at 9:27 AM, DavidW <vip@avatar.com.au> wrote: Do you write python? |