Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: routing assumption basis of microphone loopback detection #2209

Merged
merged 5 commits into from
Jun 27, 2024

Conversation

xuan25
Copy link
Contributor

@xuan25 xuan25 commented Jun 24, 2024

The streamer refused me to set game audio and microphone to the same device when I was using a custom device.

I can see in the VB cable it may create a loopback problem, where device A's output will be loopback to A's input. But for custom devices, it shouldn't be an issue, as people can route the steam manually within the audio interface.

For example, in my case, Speaker CH 1-2 is my main output that routes to my physical speaker, and Microphone CH 1-2 is my main input, which aggregates streams from both my physical microphone and Virtual Speaker CH 5-6. In this case, I don't see any issue if I set Microphone CH 1-2 as SteamVR's mic which obtains microphone stream via Virtual Speaker CH 5-6.

Screenshot 2024-06-23 213030

@xuan25
Copy link
Contributor Author

xuan25 commented Jun 24, 2024

resolve #1070

Copy link
Collaborator

@Vixea Vixea left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

jeez thats a old issue

@xuan25
Copy link
Contributor Author

xuan25 commented Jun 26, 2024

jeez thats a old issue

Yeah, it's been around for a while. It kept popping up and bothering me from time to time when I require a mic steam.

@zmerp
Copy link
Member

zmerp commented Jun 26, 2024

Beside the code style, I wonder why are you getting input/ouput as same device if you use "MAYA22 CH 1-2" and "MAYA22 Virtual CH 5-6"? if you see them as separate devices on windows then it means they should not be detected as same device.

@xuan25
Copy link
Contributor Author

xuan25 commented Jun 27, 2024

Beside the code style, I wonder why are you getting input/ouput as same device if you use "MAYA22 CH 1-2" and "MAYA22 Virtual CH 5-6"? if you see them as separate devices on windows then it means they should not be detected as same device.

Because my game audio is output to MAYA22 CH 1-2 (Speaker device) (not in the screenshot), thus alvr_audio::is_same_device(&game_audio_device, &source) is evaluated to true. But the game audio will never loop back to MAYA22 CH 1-2 (Microphone device) in my case, which will not lead to game audio being captured in the in-game communication.

MAYA22 Virtual CH 5-6 (Speaker device) is where I expect mic audio from the headset will be "played back" so I can route and process it with my audio interface, which then finally feeds it into in-game communication stream via MAYA22 CH 1-2 (Microphone device).

@xuan25 xuan25 requested a review from zmerp June 27, 2024 02:24
@zmerp
Copy link
Member

zmerp commented Jun 27, 2024

Interesting, so this MAYA22 system handles playback and loopback separately? Sounds non conforming maybe but that's alright

@zmerp zmerp merged commit 14a34b2 into alvr-org:master Jun 27, 2024
8 checks passed
@xuan25
Copy link
Contributor Author

xuan25 commented Jun 27, 2024

Interesting, so this MAYA22 system handles playback and loopback separately? Sounds non conforming maybe but that's alright

Thank you for your attention and assistance to the problem I encountered.

Yeah, it is actually quite similar to a Voicemeeter Banana (with physical ports) where you can select the audio stream taken from which device and being sent to which device for each bus. Technically, it is like a built-in virtual jumper cable or an Audio Video Bridging (VAB).

ShootingKing-AM pushed a commit to PhoneVR-Developers/ALVR-phonevr that referenced this pull request Jul 5, 2024
* Increase maximum resolution from 4096 to 8192

* decimal instead of hex

* chore: add formatting style for c++

* chore: reformat c++ to new style

* chore: add c++ autoformatter

* chore: Add missed/bugfixed format changes

* fix: routing assumption basis of microphone loopback detection (alvr-org#2209)

* fix(server) HEVC black screen on some linux config (alvr-org#2203)

* refactor(xtask): ♻️ Fix clippy and refactor (alvr-org#2213)

* fix(client_core): 🐛 Fix USB mode (alvr-org#2214)

* refactor(client): ♻️ Remove separate Pico Neo 3 Link platform

* client gfx refactor (7): partially port lobby

* feat(client): ✨ Show hands in lobby

* feat(client_openxr): ✨ Make lobby use max swapchain res (alvr-org#2220)

* feat(client_core): ✨ Thicken lobby grid lines

* fix(client): 🐛 Fix performance regressions on Quest 1

---------

Co-authored-by: shinyquagsire23 <[email protected]>
Co-authored-by: Leonhard Saam <[email protected]>
Co-authored-by: 瑄 <[email protected]>
Co-authored-by: Nibor62 <[email protected]>
Co-authored-by: zarik5 <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants