mirror of
https://github.com/onyx-and-iris/vban-cli.git
synced 2026-03-02 21:19:11 +00:00
add more eq cell commands
This commit is contained in:
parent
f6d82c5064
commit
080e26f75f
@ -85,6 +85,10 @@ examples:
|
||||
|
||||
```console
|
||||
vban-cli strip 0 eq cell 0 on false
|
||||
|
||||
vban-cli strip 3 eq cell 2 freq 1500
|
||||
|
||||
vban-cli strip 4 eq cell 5 type 5
|
||||
```
|
||||
|
||||
see `vban-cli strip eq cell --help` for more info.
|
||||
|
||||
@ -64,7 +64,7 @@ def cell_launcher(
|
||||
Only channel 0 is supported, see https://github.com/onyx-and-iris/vban-cli?tab=readme-ov-file#implementation-notes - 3.
|
||||
"""
|
||||
additional_kwargs = {}
|
||||
command, bound, _ = app.parse_args(tokens)
|
||||
command, bound, _ = cell_app.parse_args(tokens)
|
||||
additional_kwargs['target'] = target.channel[0].cell[band]
|
||||
|
||||
return command(*bound.args, **bound.kwargs, **additional_kwargs)
|
||||
@ -88,3 +88,83 @@ def cell_on(
|
||||
# console.out.print(target.on)
|
||||
return
|
||||
target.on = new_state
|
||||
|
||||
|
||||
@cell_app.command(name='freq')
|
||||
def cell_freq(
|
||||
new_freq: Annotated[float, Argument()] = None,
|
||||
*,
|
||||
target: Annotated[object, Parameter(show=False)] = None,
|
||||
):
|
||||
"""Get or set the frequency of the specified EQ cell.
|
||||
|
||||
Parameters
|
||||
----------
|
||||
new_freq : float
|
||||
If provided, sets the frequency to this value. If not provided, the current frequency is printed.
|
||||
"""
|
||||
if new_freq is None:
|
||||
# See https://github.com/onyx-and-iris/vban-cli?tab=readme-ov-file#implementation-notes - 2.
|
||||
# console.out.print(target.f)
|
||||
return
|
||||
target.f = new_freq
|
||||
|
||||
|
||||
@cell_app.command(name='gain')
|
||||
def cell_gain(
|
||||
new_gain: Annotated[float, Argument()] = None,
|
||||
*,
|
||||
target: Annotated[object, Parameter(show=False)] = None,
|
||||
):
|
||||
"""Get or set the gain of the specified EQ cell.
|
||||
|
||||
Parameters
|
||||
----------
|
||||
new_gain : float
|
||||
If provided, sets the gain to this value. If not provided, the current gain is printed.
|
||||
"""
|
||||
if new_gain is None:
|
||||
# See https://github.com/onyx-and-iris/vban-cli?tab=readme-ov-file#implementation-notes - 2.
|
||||
# console.out.print(target.gain)
|
||||
return
|
||||
target.gain = new_gain
|
||||
|
||||
|
||||
@cell_app.command(name='quality')
|
||||
def cell_q(
|
||||
new_q: Annotated[float, Argument()] = None,
|
||||
*,
|
||||
target: Annotated[object, Parameter(show=False)] = None,
|
||||
):
|
||||
"""Get or set the Q of the specified EQ cell.
|
||||
|
||||
Parameters
|
||||
----------
|
||||
new_q : float
|
||||
If provided, sets the Q to this value. If not provided, the current Q is printed.
|
||||
"""
|
||||
if new_q is None:
|
||||
# See https://github.com/onyx-and-iris/vban-cli?tab=readme-ov-file#implementation-notes - 2.
|
||||
# console.out.print(target.q)
|
||||
return
|
||||
target.q = new_q
|
||||
|
||||
|
||||
@cell_app.command(name='type')
|
||||
def cell_type(
|
||||
new_type: Annotated[int, Argument()] = None,
|
||||
*,
|
||||
target: Annotated[object, Parameter(show=False)] = None,
|
||||
):
|
||||
"""Get or set the type of the specified EQ cell.
|
||||
|
||||
Parameters
|
||||
----------
|
||||
new_type : int
|
||||
If provided, sets the type to this value. If not provided, the current type is printed.
|
||||
"""
|
||||
if new_type is None:
|
||||
# See https://github.com/onyx-and-iris/vban-cli?tab=readme-ov-file#implementation-notes - 2.
|
||||
# console.out.print(target.type)
|
||||
return
|
||||
target.type = new_type
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user