Fix #108613: Mute Audio for Playback also mutes for rendering #108871

Closed
Richard Antalik wants to merge 1 commits from iss/blender:108613 into main

When changing the target branch, be careful to rebase the branch in your fork to match. See documentation.

AUDIO_MUTE flag of scene->audio.flag works as intended and tooltip
for this property is not correct. However muting scene audio for
playback and rendering is not be very useful, since users can render
with no audio explicitly or adjust scene volume.

Add no_muting argument to BKE_scene_update_sound() so muting can be
bypassed for rendering.

`AUDIO_MUTE` flag of `scene->audio.flag` works as intended and tooltip for this property is not correct. However muting scene audio for playback and rendering is not be very useful, since users can render with no audio explicitly or adjust scene volume. Add `no_muting` argument to `BKE_scene_update_sound()` so muting can be bypassed for rendering.
Richard Antalik added 1 commit 2023-06-12 02:28:56 +02:00
Richard Antalik requested review from Sergey Sharybin 2023-06-12 02:29:04 +02:00

If the muting only supposed to be affecting viewport (non-rendering) then isn't it easier to do

const bool is_mute = (DEG_get_mode(depsgraph) == DAG_EVAL_VIREWPORT) && (scene->audio.flag & AUDIO_MUTE);

?

If the muting only supposed to be affecting viewport (non-rendering) then isn't it easier to do ``` const bool is_mute = (DEG_get_mode(depsgraph) == DAG_EVAL_VIREWPORT) && (scene->audio.flag & AUDIO_MUTE); ``` ?
Author
Member

Thanks, I wanted to do that, just expected the function in DEG_depshraph.h. Will commit that instead.

Thanks, I wanted to do that, just expected the function in `DEG_depshraph.h`. Will commit that instead.
Richard Antalik closed this pull request 2023-06-13 01:58:06 +02:00

Please go via the code review.

The use of DEG_graph_id_tag_update in the pipeline.cc is not really clear. Like, why is it needed and why only for render depsgraph and only for muting? The newly created dependency graph is not supposed to be tagged for updates for the proper initial evaluaiton.

Please go via the code review. The use of `DEG_graph_id_tag_update` in the `pipeline.cc` is not really clear. Like, why is it needed and why only for render depsgraph and only for muting? The newly created dependency graph is not supposed to be tagged for updates for the proper initial evaluaiton.
Author
Member

Sorry for that, will update patch next time. The reason for tagging was, because recalc & ID_RECALC_AUDIO_MUTE evaluates to false in BKE_scene_update_sound() when rendering animation.

Sorry for that, will update patch next time. The reason for tagging was, because `recalc & ID_RECALC_AUDIO_MUTE` evaluates to false in `BKE_scene_update_sound()` when rendering animation.

To me this sounds like a description of a symptom, not an actual cause.

To me this sounds like a description of a symptom, not an actual cause.

Pull request closed

Sign in to join this conversation.
No reviewers
No Label
Interest
Alembic
Interest
Animation & Rigging
Interest
Asset System
Interest
Audio
Interest
Automated Testing
Interest
Blender Asset Bundle
Interest
BlendFile
Interest
Code Documentation
Interest
Collada
Interest
Compatibility
Interest
Compositing
Interest
Core
Interest
Cycles
Interest
Dependency Graph
Interest
Development Management
Interest
EEVEE
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 & 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
Viewport & EEVEE
Interest
Virtual Reality
Interest
Vulkan
Interest
Wayland
Interest
Workbench
Interest: X11
Legacy
Asset Browser Project
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
Asset System
Module
Core
Module
Development Management
Module
Grease Pencil
Module
Modeling
Module
Nodes & Physics
Module
Pipeline & IO
Module
Platforms, Builds & Tests
Module
Python API
Module
Render & Cycles
Module
Sculpt, Paint & Texture
Module
Triaging
Module
User Interface
Module
VFX & Video
Module
Viewport & EEVEE
Platform
FreeBSD
Platform
Linux
Platform
macOS
Platform
Windows
Severity
High
Severity
Low
Severity
Normal
Severity
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
2 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#108871
No description provided.