mirror of
https://github.com/onyx-and-iris/vmr-http.git
synced 2026-04-16 14:43:31 +00:00
add bus mono route
patch bump
This commit is contained in:
@@ -1,6 +1,6 @@
|
|||||||
[project]
|
[project]
|
||||||
name = "vmr-http"
|
name = "vmr-http"
|
||||||
version = "0.3.1"
|
version = "0.3.2"
|
||||||
description = "HTTP API for controlling Voicemeeter"
|
description = "HTTP API for controlling Voicemeeter"
|
||||||
readme = "README.md"
|
readme = "README.md"
|
||||||
authors = [{ name = "onyx-and-iris", email = "code@onyxandiris.online" }]
|
authors = [{ name = "onyx-and-iris", email = "code@onyxandiris.online" }]
|
||||||
|
|||||||
@@ -33,3 +33,10 @@ async def get_gain(index: int, voicemeeter=Depends(get_voicemeeter_client)):
|
|||||||
async def get_mute(index: int, voicemeeter=Depends(get_voicemeeter_client)):
|
async def get_mute(index: int, voicemeeter=Depends(get_voicemeeter_client)):
|
||||||
"""Get the current mute status for the specified bus index."""
|
"""Get the current mute status for the specified bus index."""
|
||||||
return {'mute': voicemeeter.bus[index].mute}
|
return {'mute': voicemeeter.bus[index].mute}
|
||||||
|
|
||||||
|
|
||||||
|
@router.get('/{index}/mono', tags=['bus'])
|
||||||
|
async def get_mono(index: int, voicemeeter=Depends(get_voicemeeter_client)):
|
||||||
|
"""Get the current mono status for the specified bus index."""
|
||||||
|
opts = ['Off', 'On', 'Stereo Reverse']
|
||||||
|
return {'mono': opts[voicemeeter.bus[index].mono]}
|
||||||
|
|||||||
Reference in New Issue
Block a user