Audio out remains on device used when blender started (WASAPI only) #93312

Closed
opened 2021-11-22 22:52:28 +01:00 by Y.Levin · 17 comments

EDITED TO ADD: problem goes away with SDL in audio preferences. Problem exists with WASAPI.

System Information
Operating system: Windows 10
Graphics card: RTX 3090 EVGA

Blender Version
Broken: 3.0.0 b
Worked:

Short description of error
Using audio with Blender, when changing output device, such as plugging-in headphones after using speakers or vice-versa, audio remains on original device. Closing and restarting Blender then plays on new device. May not be a bug, but is a nuisance.

Exact steps for others to reproduce the error
add audio in video sequencer. Play. works ok. change audio device. plays on original device.

EDITED TO ADD: problem goes away with SDL in audio preferences. Problem exists with WASAPI. **System Information** Operating system: Windows 10 Graphics card: RTX 3090 EVGA **Blender Version** Broken: 3.0.0 b Worked: **Short description of error** Using audio with Blender, when changing output device, such as plugging-in headphones after using speakers or vice-versa, audio remains on original device. Closing and restarting Blender then plays on new device. May not be a bug, but is a nuisance. **Exact steps for others to reproduce the error** add audio in video sequencer. Play. works ok. change audio device. plays on original device.
Author

Added subscriber: @leviny

Added subscriber: @leviny
Y.Levin changed title from Audio out remains on device used when blender started to Audio out remains on device used when blender started (WASAPI only) 2021-11-23 23:10:43 +01:00

Added subscriber: @iss

Added subscriber: @iss

Changed status from 'Needs Triage' to: 'Needs User Info'

Changed status from 'Needs Triage' to: 'Needs User Info'

By original device do you mean, that sound will play on original channed on same sound card or are you plugging in new soundcard, but audio is playing on original one?

I don't think I have card that switches channels here to check, second case is expected I would say.

By original device do you mean, that sound will play on original channed on same sound card or are you plugging in new soundcard, but audio is playing on original one? I don't think I have card that switches channels here to check, second case is expected I would say.
Author

Not channels or cards but audio output devices, as in speakers vs headphones. Normal behavior in windows is to change audio device when a new device is plugged in or unplugged (mainly wired headphones plugged in, or bluetooth connected). Device can also be changed manually in windows volume control or audio settings. in All those cases, Blender continues to play in the "old" device rather than the "new". This works correctly (starts playing in new device) when using SDL in Blender's sound options. I was using WASAPI (by default, never looked at these settings before).
Thanks for your time.

Not channels or cards but audio output devices, as in speakers vs headphones. Normal behavior in windows is to change audio device when a new device is plugged in or unplugged (mainly wired headphones plugged in, or bluetooth connected). Device can also be changed manually in windows volume control or audio settings. in All those cases, Blender continues to play in the "old" device rather than the "new". This works correctly (starts playing in new device) when using SDL in Blender's sound options. I was using WASAPI (by default, never looked at these settings before). Thanks for your time.

Changed status from 'Needs User Info' to: 'Confirmed'

Changed status from 'Needs User Info' to: 'Confirmed'

Added subscriber: @neXyon

Added subscriber: @neXyon

Thanks for clarification. I don't know exactly how outputs are structured in this case, just that there could be distinction.
I can confirm that when I connect new sound card, in WASAPI it plays on original sound output, with SDL it does switch to new output. This is likely same configuration as reported.

@neXyon Can you check?

Thanks for clarification. I don't know exactly how outputs are structured in this case, just that there could be distinction. I can confirm that when I connect new sound card, in WASAPI it plays on original sound output, with SDL it does switch to new output. This is likely same configuration as reported. @neXyon Can you check?
Member

OpenAL has the same behavior btw, but yes, SDL always switches to the default device. I implemented this in this build, can you please try it @leviny ? https://builder.blender.org/download/patch/blender-3.1.0-alpha+master-D13823.5bcc14dc05a3-windows.amd64-release.zip

OpenAL has the same behavior btw, but yes, SDL always switches to the default device. I implemented this in this build, can you please try it @leviny ? https://builder.blender.org/download/patch/blender-3.1.0-alpha+master-[D13823](https://archive.blender.org/developer/D13823).5bcc14dc05a3-windows.amd64-release.zip
Author

So with SDL the behavior is still "correct" (meaning the audio device changes when I connect or disconnect a bluetooth speaker, for example.) With OpenAL (as well as OpenAL+soft which was also an option) and with WASAPI it correctly switches to windows speakers when I disconnect the bluetooth speaker, but does not switch back to the bluetooth speaker when I reconnect it (keeps playing on windows speakers even though all other audio in windows goes to the bluetooth.)

You can test this easily with a blend file that has audio in the video sequencer, then use windows settings to connect and disconnect a bluetooth device, or plug a wired headset in and out and see if the audio follows. Or I'm happy to do more testing. Thanks for working on this.

So with SDL the behavior is still "correct" (meaning the audio device changes when I connect or disconnect a bluetooth speaker, for example.) With OpenAL (as well as OpenAL+soft which was also an option) and with WASAPI it correctly switches to windows speakers when I disconnect the bluetooth speaker, but does not switch back to the bluetooth speaker when I reconnect it (keeps playing on windows speakers even though all other audio in windows goes to the bluetooth.) You can test this easily with a blend file that has audio in the video sequencer, then use windows settings to connect and disconnect a bluetooth device, or plug a wired headset in and out and see if the audio follows. Or I'm happy to do more testing. Thanks for working on this.
Member

And you tried this with the build that I linked in the last comment that you downloaded, unpacked and then ran the blender.exe in the unpacked folder? Because there it works for me and if it doesn't for you, I'm not sure how to reproduce your issue.

And you tried this with the build that I linked in the last comment that you downloaded, unpacked and then ran the blender.exe in the unpacked folder? Because there it works for me and if it doesn't for you, I'm not sure how to reproduce your issue.
Author

Yes, on the build you linked. If you play audio on speakers then stop the play, connect a bluetooth headset, press play and the audio should play in the headset. Disconnect the headset, the audio should play in the speakers. For me, works in SDL, not in WASAPI or openAL. If this works for you, the problem may be on my side.

Yes, on the build you linked. If you play audio on speakers then stop the play, connect a bluetooth headset, press play and the audio should play in the headset. Disconnect the headset, the audio should play in the speakers. For me, works in SDL, not in WASAPI or openAL. If this works for you, the problem may be on my side.
Member

It works for me (with the headphone jack) and another person that tested with a bluetooth headset. No idea what's wrong there, sorry.

It works for me (with the headphone jack) and another person that tested with a bluetooth headset. No idea what's wrong there, sorry.
Member

Here's another build that fixes a bug in the last one that WASAPI didn't work properly, when the audio device was switched while playback was stopped: https://builder.blender.org/download/patch/blender-3.1.0-alpha+master-D13823.45894ba931ad-windows.amd64-release.zip

Here's another build that fixes a bug in the last one that WASAPI didn't work properly, when the audio device was switched while playback was stopped: https://builder.blender.org/download/patch/blender-3.1.0-alpha+master-[D13823](https://archive.blender.org/developer/D13823).45894ba931ad-windows.amd64-release.zip
Member

Changed status from 'Confirmed' to: 'Resolved'

Changed status from 'Confirmed' to: 'Resolved'
Joerg Mueller self-assigned this 2022-01-14 22:57:55 +01:00
Member

I pushed a fix for this as part of 2a095d8bfe. It works for everyone who tested it, except you @leviny. I'll mark this as resolved for now, if the problem still persists with the next release of Blender, please reopen this report, or open a new one. If it is fixed, I'd also love to know! Cheers

I pushed a fix for this as part of 2a095d8bfe. It works for everyone who tested it, except you @leviny. I'll mark this as resolved for now, if the problem still persists with the next release of Blender, please reopen this report, or open a new one. If it is fixed, I'd also love to know! Cheers
Author

In the latest build linked above, works perfectly in SDL and WASPI. Doesn't work in OpenAL. Tested by connecting and disconnecting wired headset and bluetooth headset, while playing as well as stopping and restarting play after connecting/disconnecting.
Thanks for fixing it!

In the latest build linked above, works perfectly in SDL and WASPI. Doesn't work in OpenAL. Tested by connecting and disconnecting wired headset and bluetooth headset, while playing as well as stopping and restarting play after connecting/disconnecting. Thanks for fixing it!
Sign in to join this conversation.
No Label
Interest
Alembic
Interest
Animation & Rigging
Interest
Asset Browser
Interest
Asset Browser Project Overview
Interest
Audio
Interest
Automated Testing
Interest
Blender Asset Bundle
Interest
BlendFile
Interest
Collada
Interest
Compatibility
Interest
Compositing
Interest
Core
Interest
Cycles
Interest
Dependency Graph
Interest
Development Management
Interest
EEVEE
Interest
EEVEE & Viewport
Interest
Freestyle
Interest
Geometry Nodes
Interest
Grease Pencil
Interest
ID Management
Interest
Images & Movies
Interest
Import Export
Interest
Line Art
Interest
Masking
Interest
Metal
Interest
Modeling
Interest
Modifiers
Interest
Motion Tracking
Interest
Nodes & Physics
Interest
OpenGL
Interest
Overlay
Interest
Overrides
Interest
Performance
Interest
Physics
Interest
Pipeline, Assets & IO
Interest
Platforms, Builds & Tests
Interest
Python API
Interest
Render & Cycles
Interest
Render Pipeline
Interest
Sculpt, Paint & Texture
Interest
Text Editor
Interest
Translations
Interest
Triaging
Interest
Undo
Interest
USD
Interest
User Interface
Interest
UV Editing
Interest
VFX & Video
Interest
Video Sequencer
Interest
Virtual Reality
Interest
Vulkan
Interest
Wayland
Interest
Workbench
Interest: X11
Legacy
Blender 2.8 Project
Legacy
Milestone 1: Basic, Local Asset Browser
Legacy
OpenGL Error
Meta
Good First Issue
Meta
Papercut
Meta
Retrospective
Meta
Security
Module
Animation & Rigging
Module
Core
Module
Development Management
Module
EEVEE & Viewport
Module
Grease Pencil
Module
Modeling
Module
Nodes & Physics
Module
Pipeline, Assets & IO
Module
Platforms, Builds & Tests
Module
Python API
Module
Render & Cycles
Module
Sculpt, Paint & Texture
Module
Triaging
Module
User Interface
Module
VFX & Video
Platform
FreeBSD
Platform
Linux
Platform
macOS
Platform
Windows
Priority
High
Priority
Low
Priority
Normal
Priority
Unbreak Now!
Status
Archived
Status
Confirmed
Status
Duplicate
Status
Needs Info from Developers
Status
Needs Information from User
Status
Needs Triage
Status
Resolved
Type
Bug
Type
Design
Type
Known Issue
Type
Patch
Type
Report
Type
To Do
No Milestone
No project
No Assignees
3 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: blender/blender#93312
No description provided.