mirror of
https://github.com/onyx-and-iris/voicemeeter-api-powershell.git
synced 2025-01-17 21:10:46 +00:00
using example from README.
This commit is contained in:
parent
fdb7e39ac1
commit
7c60f564b2
37
example.ps1
37
example.ps1
@ -1,36 +1,17 @@
|
||||
Import-Module .\lib\Voicemeeter.psm1
|
||||
|
||||
try {
|
||||
# Run the factory function for required Voicemeeter type
|
||||
$vmr = Get-RemoteBanana
|
||||
|
||||
$hash = @{
|
||||
strip_0 = @{mute = $true; mono = $true; A1 = $true; B2 = $true; gain = 2.3};
|
||||
strip_1 = @{mute = $true; mono = $true; A1 = $true; B2 = $true; gain = -3.0};
|
||||
strip_2 = @{mute = $true; mono = $true; A1 = $true; B2 = $true; gain = 0.3};
|
||||
bus_0 = @{mute = $true; mono = $true; solo = $true; gain = -0.3};
|
||||
bus_1 = @{mute = $true; mono = $true; solo = $true; gain = -3.3};
|
||||
bus_2 = @{mute = $true; mono = $true; solo = $true; gain = 2.3};
|
||||
# Set strip and bus params
|
||||
$vmr.strip[0].mono = $true
|
||||
$vmr.strip[0].mono
|
||||
$vmr.bus[1].mute = $false
|
||||
$vmr.bus[1].mute
|
||||
|
||||
mb_0 = @{state = $true};
|
||||
mb_1 = @{stateonly = $true};
|
||||
mb_2 = @{trigger = $true}
|
||||
}
|
||||
|
||||
$vmr.Set_Multi($hash)
|
||||
|
||||
$hash = @{
|
||||
strip_0 = @{mute = $false; mono = $false; A1 = $false; B2 = $false; gain = 0};
|
||||
strip_1 = @{mute = $false; mono = $false; A1 = $false; B2 = $false; gain = 0};
|
||||
strip_2 = @{mute = $false; mono = $false; A1 = $false; B2 = $false; gain = 0};
|
||||
bus_0 = @{mute = $false; mono = $false; solo = $false; gain = 0};
|
||||
bus_1 = @{mute = $false; mono = $false; solo = $false; gain = 0};
|
||||
bus_2 = @{mute = $false; mono = $false; solo = $false; gain = 0};
|
||||
|
||||
mb_0 = @{state = $false};
|
||||
mb_1 = @{stateonly = $false};
|
||||
mb_2 = @{trigger = $false}
|
||||
}
|
||||
|
||||
$vmr.Set_Multi($hash)
|
||||
# Set macrobutton with id 4, mode state to 1
|
||||
$vmr.button[4].state = $true
|
||||
$vmr.button[4].state
|
||||
}
|
||||
finally { $vmr.Logout() }
|
||||
|
Loading…
Reference in New Issue
Block a user