StrokesPlus.net
Welcome Guest! To enable all features please Login or Register.

Notification

Icon
Error

Options
Go to last post Go to first unread
Final  
#1 Posted : Sunday, September 1, 2019 7:14:18 PM(UTC)
Final

Rank: Newbie

Reputation:

Groups: Approved
Joined: 8/7/2019(UTC)
Posts: 5
China

Thanks: 4 times
我想通过S+来调整系统的声音
请教下,我该如何设置,谢谢
Rob  
#2 Posted : Monday, September 2, 2019 7:14:57 AM(UTC)
Rob

Rank: Administration

Reputation:

Groups: Translators, Members, Administrators
Joined: 1/11/2018(UTC)
Posts: 340
United States

Thanks: 5 times
Was thanked: 64 time(s) in 56 post(s)
How do you want to adjust the sound?

The easiest and (usually) most compatible method is to send the volume key strokes (sent by keyboards with volume up/down/mute)

Code:
sp.SendVKey(vk.VOLUME_MUTE); //Mute
sp.SendVKey(vk.VOLUME_DOWN); //Lower volume
sp.SendVKey(vk.VOLUME_UP); //Increase volume

If you want to control the playback mixer directly, you can retrieve the object and adjust accordingly. See this repo for more details about how to use this library, as I did not create it: https://github.com/xenolightning/AudioSwitcher
Code:
var mixer = sp.GetPlaybackMixer();  //Can also call sp.GetCommunicationsMixer() to get the communications mixer
mixer.Volume = 37; //Set volume to 37%
thanks 1 user thanked Rob for this useful post.
Final on 9/3/2019(UTC)
Final  
#3 Posted : Tuesday, September 3, 2019 12:34:38 AM(UTC)
Final

Rank: Newbie

Reputation:

Groups: Approved
Joined: 8/7/2019(UTC)
Posts: 5
China

Thanks: 4 times
谢谢,暂时只需要微调就可以了。
Users browsing this topic
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.