dual amplify

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
Bloodrock
Posts: 12
Joined: Wed Jul 15, 2020 1:33 pm
Operating System: Linux Mint

Re: dual amplify

Post by Bloodrock » Wed Jul 15, 2020 6:44 pm

i must be doing something when sending a reply with code thought you hit code then under it add code or what do i need to do

Bloodrock
Posts: 12
Joined: Wed Jul 15, 2020 1:33 pm
Operating System: Linux Mint

Re: dual amplify

Post by Bloodrock » Wed Jul 15, 2020 6:48 pm

ok guess it went thru lots of times i get the 503 error when replying or posting

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

Re: dual amplify

Post by steve » Wed Jul 15, 2020 6:48 pm

Bloodrock wrote:
Wed Jul 15, 2020 6:41 pm
i must be doing something when sending a reply with code thought you hit code then under it add code or what do i need to do
To use "code" tags:
  1. Click the "</>" button. That will add:
    [code][/code]
  2. Paste your code between the two code tags, like this:
    [code]
    Code goes here...
    [/code]
9/10 questions are answered in the FREQUENTLY ASKED QUESTIONS (FAQ)

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

Re: dual amplify

Post by steve » Wed Jul 15, 2020 6:56 pm

Bloodrock wrote:
Wed Jul 15, 2020 6:07 pm
this is what i tryed
Pretty close for a first attempt :)

The ";action" and ";info" headers are no longer used, so they can be left out.

I'd suggest replacing these two lines:

Code: Select all

(setf left-gain 0.5)
(setf right-gain 0.8)
with controls:

Code: Select all

;control left-gain "Left gain" float "" 1 0 2
;control right-gain "Right gain" float "" 1 0 2
Then you just need the processing part:

Code: Select all

(vector
  (mult (aref *track* 0) left-gain)
  (mult (aref *track* 1) right-gain))

amplify.png
amplify.png (20.01 KiB) Viewed 1018 times
9/10 questions are answered in the FREQUENTLY ASKED QUESTIONS (FAQ)

Bloodrock
Posts: 12
Joined: Wed Jul 15, 2020 1:33 pm
Operating System: Linux Mint

Re: dual amplify

Post by Bloodrock » Wed Jul 15, 2020 9:01 pm

ok getting farther still is not adjusting volume just does a nyquist returned the value 0.8000000

Code: Select all

;nyquist plug-in
;version 1
;type process
;name "Amplify both channels..."

(setf left-gain 0.5)
(setf right-gain 0.5)

;control left-gain "Left gain" float "" 1 0 2
;control right-gain "Right gain" float "" 1 0 2
;;control left-gain "Left gain" int "" 1 0 2
;;control right-gain "Right gain" int "" 1 0 2

(vector
  (mult (aref *TRACK* 0) left-gain)
  (mult (aref *TRACK* 1) right-gain))


after running get this

error: unbound variable - *TRACK*
if continued: try evaluating symbol again
1>

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

Re: dual amplify

Post by steve » Wed Jul 15, 2020 9:12 pm

;version 1 is for ancient versions of Audacity.
For current versions of Audacity, plug-ins should be set to ;version 4.

Also, you don't need the lines:

Code: Select all

(setf left-gain 0.5)
(setf right-gain 0.5)
because left-gain and right-gain are set by the controls:

Code: Select all

;control left-gain "Left gain" float "" 1 0 2
;control right-gain "Right gain" float "" 1 0 2
9/10 questions are answered in the FREQUENTLY ASKED QUESTIONS (FAQ)

Bloodrock
Posts: 12
Joined: Wed Jul 15, 2020 1:33 pm
Operating System: Linux Mint

Re: dual amplify

Post by Bloodrock » Wed Jul 15, 2020 9:59 pm

ok that did the trick thanks for all the help working like i wanted

Felipe Zanabria
Posts: 116
Joined: Fri Mar 16, 2018 1:38 am
Operating System: Windows 7

Re: dual amplify

Post by Felipe Zanabria » Fri Dec 18, 2020 5:55 am

I have tis plug-ing for you:

Code: Select all

 ;nyquist plug-in
;version 4
;type process
;name "Amplify channels by percent"
;action "Amplifying channels..."
;info "Amplify channels independently by percent


;control left-gain "Left channel amplification" int "Percent" 100 0 100
;control right-gain "right channel amplification" int "Percent" 100 0 100

(setf left-gain (/ left-gain 100.0))   ;Amplification amount for left channel
(setf right-gain (/ right-gain 100.0))  ;Amplification amount for right channel
(vector
  (mult (aref *track* 0) left-gain)
  (mult (aref *track* 1) right-gain)) 

Post Reply