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

copier: fix attenuation stream frames calculation #7761

Merged
merged 1 commit into from
Jun 13, 2023

Conversation

iganakov
Copy link
Contributor

@iganakov iganakov commented Jun 7, 2023

When calculating number of frames to be attenuated in HOST copier source stream frame bytes should be used instead of sink frame bytes.

E.g. in case of 24/24 bit to 24/32 bit PCM conversion using sink container size will reduce frames number by 1/4 which will lead to multiple glitches.

Also attenuation has to be applied in HOST copier in playback scenario only, thus remove from do_conversion_copy()

src/audio/copier/copier.c Show resolved Hide resolved
src/audio/copier/copier_host.c Show resolved Hide resolved
When calculating number of frames to be attenuated in HOST copier
source stream frame bytes should be used instead of sink frame bytes.

E.g. in case of 24/24 bit to 24/32 bit PCM conversion using sink
container size will reduce frames number by 1/4 which will lead to
multiple glitches.

Also attenuation has to be applied in HOST copier in playback scenario
only, thus remove from do_conversion_copy()

Signed-off-by: Ievgen Ganakov <[email protected]>
@iganakov iganakov force-pushed the iganakov/copier/attenuation branch from 81b8d18 to 97f23a2 Compare June 13, 2023 07:35
@iganakov iganakov marked this pull request as ready for review June 13, 2023 08:58
@kv2019i
Copy link
Collaborator

kv2019i commented Jun 13, 2023

#7191 hit on MTL nocodec in https://sof-ci.01.org/sofpr/PR7761/build9362/devicetest/index.html, not related to this PR . Rest of checks good.

@kv2019i kv2019i merged commit 8fb011d into thesofproject:main Jun 13, 2023
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.

5 participants