Moving Selection

Using Nyquist scripts in Audacity.
Post and download new plug-ins.
Forum rules
If you require help using Audacity, please post on the forum board relevant to your operating system:
Windows
Mac OS X
GNU/Linux and Unix-like
Post Reply
vpd
Posts: 103
Joined: Tue Feb 26, 2013 4:28 pm
Operating System: Linux Debian

Moving Selection

Post by vpd » Wed Jan 15, 2014 7:24 pm

Hi people,
I'm a very very new in Nyquist. I was wondering Is it possible to move (or set a new selection) with Nyquist. I'd like to halve/double selection and to shift it to left/right. I solved my problem using labels, using this code:

Code: Select all

(list
(list (* -1 (get-duration 1)) "A1")
(list (get-duration 0) "B1")
(list (get-duration 0.25) "B2")
(list (get-duration 0.5) "B3")
(list (get-duration 0.75) "B4")
(list (get-duration 1) "C1")
(list (get-duration 2) "D1")
)
Don't laugh at me, please! :D

steve
Site Admin
Posts: 80677
Joined: Sat Dec 01, 2007 11:43 am
Operating System: Linux *buntu

Re: Moving Selection

Post by steve » Wed Jan 15, 2014 7:58 pm

vpd wrote:I was wondering Is it possible to move (or set a new selection) with Nyquist.
Unfortunately no, though I'd very much like this to be possible in a future version.

The way that Nyquist in Audacity currently works is that, for "process" and "analyze" type plug-ins, Audacity passes the selected audio from one audio track to Nyquist. This is then repeated for each selected track. The audio is passed as the value of the symbol "S". Nyquist sees the start of that sound as time=0 and the end of that sound as time=1. Nyquist is totally unaware of "track time" in Audacity.

If Nyquist returns audio as the "result", then Audacity replaces the selected audio with that returned by Nyquist.
9/10 questions are answered in the FREQUENTLY ASKED QUESTIONS (FAQ)

vpd
Posts: 103
Joined: Tue Feb 26, 2013 4:28 pm
Operating System: Linux Debian

Re: Moving Selection

Post by vpd » Wed Jan 15, 2014 8:51 pm

Oh, thanks a bunch for the quick response, Steve! :) Maybe you remember I suggested that "Acid Looping" feature in this topic a few months ago. I guess at some point it could be added "halve selection", "double selection", "shift selection left" and "shift selection right" options to the "Edit > Select" menu. But for now, I'm goin' to use my funny code to split selection with labels. Thanks again! Much love!

steve
Site Admin
Posts: 80677
Joined: Sat Dec 01, 2007 11:43 am
Operating System: Linux *buntu

Re: Moving Selection

Post by steve » Wed Jan 15, 2014 9:33 pm

Actually you can move the selection from the Selection Toolbar http://manual.audacityteam.org/o/man/se ... olbar.html
Select the "Length" radio button, then type the required start time into the "Selection Start" box.
9/10 questions are answered in the FREQUENTLY ASKED QUESTIONS (FAQ)

vpd
Posts: 103
Joined: Tue Feb 26, 2013 4:28 pm
Operating System: Linux Debian

Re: Moving Selection

Post by vpd » Wed Jan 15, 2014 10:33 pm

steve wrote:Actually you can move the selection from the Selection Toolbar
Ah, this is amazing!!! :geek: It works like magic in samples format!! 8-) Thank you again, Steve!!!! :D

steve
Site Admin
Posts: 80677
Joined: Sat Dec 01, 2007 11:43 am
Operating System: Linux *buntu

Re: Moving Selection

Post by steve » Wed Jan 15, 2014 10:52 pm

You just have to remember to select "Length" rather than "End", otherwise you loose the selection as soon as you start typing, which is really annoying.
9/10 questions are answered in the FREQUENTLY ASKED QUESTIONS (FAQ)

Post Reply