VSE - Improper audio on frame 1 when exporting to lossy-compressed audio #68945

Closed
opened 2019-08-21 00:41:27 +02:00 by hudson barkley · 11 comments

Blender Version
Broken: 2.80

Short description of error
When audio from the vse is exported to lossy-compressed formats (mp3, ac3, aac), blender is adding an odd fadein on it. (see channel 6 in the attached blender screenshot).
It actually appears somewhat like a fadein in blender, but when imported into audacity, there is a .005 second silence, then instantly full volume.
Clipboard02.png

Whats worse, this false fadein seems to override any keyframes on the first frame: if the audio has a 6 frame fade in keyframed in, it will do that weirdness for the first frame, then return to the proper volume for frame 2 and continue the fade in. This creates a kind of 'hump' where there should be a smooth transition. (See channel 3 in the attached blender screenshot)

Oddly, this bug does not happen on non-lossy formats (wav, pcm, flac) (see channels 4 and 7 on the attached blender screenshot).

Note: all these tests were done with a basic sinewave test tone for maximum visibility of the waveform.
Untitled.png

Exact steps for others to reproduce the error
Load an audio file with audio immediately at the beginning into the vse
Add a fadein
Render audio out to a lossy compressed format (either in a video, or as audio alone)

**Blender Version** Broken: 2.80 **Short description of error** When audio from the vse is exported to lossy-compressed formats (mp3, ac3, aac), blender is adding an odd fadein on it. (see channel 6 in the attached blender screenshot). It actually appears somewhat like a fadein in blender, but when imported into audacity, there is a .005 second silence, then instantly full volume. ![Clipboard02.png](https://archive.blender.org/developer/F7676188/Clipboard02.png) Whats worse, this false fadein seems to override any keyframes on the first frame: if the audio has a 6 frame fade in keyframed in, it will do that weirdness for the first frame, then return to the proper volume for frame 2 and continue the fade in. This creates a kind of 'hump' where there should be a smooth transition. (See channel 3 in the attached blender screenshot) Oddly, this bug does not happen on non-lossy formats (wav, pcm, flac) (see channels 4 and 7 on the attached blender screenshot). Note: all these tests were done with a basic sinewave test tone for maximum visibility of the waveform. ![Untitled.png](https://archive.blender.org/developer/F7676171/Untitled.png) **Exact steps for others to reproduce the error** Load an audio file with audio immediately at the beginning into the vse Add a fadein Render audio out to a lossy compressed format (either in a video, or as audio alone)
Author

Added subscriber: @snuq

Added subscriber: @snuq

Added subscriber: @PaulMcManus

Added subscriber: @PaulMcManus

Can I add that the preview playback in the viewport doesn't exhibit this problem. It only manifests in the encoded output file. I'm not sure how far back this goes but I can confirm this has been a problem in 2.8 for several weeks now.

Can I add that the preview playback in the viewport doesn't exhibit this problem. It only manifests in the encoded output file. I'm not sure how far back this goes but I can confirm this has been a problem in 2.8 for several weeks now.
Author

ok, this is weird... today im not getting the same issue with the 'bump' when exporting only audio, even compressed.... but I still see the issue every time when exporting to video/audio combined... but I now see it with ANY audio codec in video, not just lossy formats.

ok, this is weird... today im not getting the same issue with the 'bump' when exporting only audio, even compressed.... but I still see the issue every time when exporting to video/audio combined... but I now see it with ANY audio codec in video, not just lossy formats.

Added subscriber: @iss

Added subscriber: @iss

I do experience similar issues during preview, but not in rendered files, at least not "audibly"
This is quite contrary, to what's reported.

I never looked at cause of this issue, but I am pretty sure it's outside of scope of VSE code.

I do experience similar issues during preview, but not in rendered files, at least not "audibly" This is quite contrary, to what's reported. I never looked at cause of this issue, but I am pretty sure it's outside of scope of VSE code.

Added subscriber: @neXyon

Added subscriber: @neXyon

This seemed like a headscratcher, until I realized, that this has nothing to do with animating the strip.

here is reproducible sample:
aud.zip

What happens is:
If sound strip has volume greater than 0, first few ms of rendered audio looks like fade-in from volume 0 to 1, then it fades to volume of the strip itself. This happens during first frame.

This is happens even with lossless format, unlike original report.

@neXyon can you please look into this? I have looked at what values we are setting, and that all seems to be correct.

When strip is animated, changes in volume in rendered audio looks highly irregular and not quite bound to frame boundaries. As if rendering and controlling threads weren't synced or what
aud.png

This seemed like a headscratcher, until I realized, that this has nothing to do with animating the strip. here is reproducible sample: [aud.zip](https://archive.blender.org/developer/F7783912/aud.zip) What happens is: If sound strip has volume greater than 0, first few ms of rendered audio looks like fade-in from volume 0 to 1, then it fades to volume of the strip itself. This happens during first frame. This is happens even with lossless format, unlike original report. @neXyon can you please look into this? I have looked at what values we are setting, and that all seems to be correct. When strip is animated, changes in volume in rendered audio looks highly irregular and not quite bound to frame boundaries. As if rendering and controlling threads weren't synced or what ![aud.png](https://archive.blender.org/developer/F7783932/aud.png)

This issue was referenced by 514c9d14e4

This issue was referenced by 514c9d14e4ab4fb90237e63d8ec89e9bc2322810
Member

Changed status from 'Open' to: 'Resolved'

Changed status from 'Open' to: 'Resolved'
Joerg Mueller self-assigned this 2019-10-03 10:27:16 +02:00
Member

If I'm right this issue is the same as #52472 and it was my mistake that I didn't correctly backport this to upstream audaspace and this caused a reintroduction of the bug. Please check if it's fixed for you now! There is some more explanation in the other bug report.

If I'm right this issue is the same as #52472 and it was my mistake that I didn't correctly backport this to upstream audaspace and this caused a reintroduction of the bug. Please check if it's fixed for you now! There is some more explanation in the other bug report.
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
5 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#68945
No description provided.