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

Resampler introduces noise #2464

Closed
SDLBugzilla opened this issue Feb 11, 2021 · 0 comments
Closed

Resampler introduces noise #2464

SDLBugzilla opened this issue Feb 11, 2021 · 0 comments

Comments

@SDLBugzilla
Copy link
Collaborator

This bug report was migrated from our old Bugzilla tracker.

Reported in version: HG 2.0
Reported for operating system, platform: Windows (All), x86

Comments on the original bug report:

On 2017-06-03 20:47:01 +0000, Trent Gamblin wrote:

When resampling to a different frequency, slight but noticable noise in introduced. I noticed this when using the WASAPI driver for the first time and requesting a 44100 stream while the hardware was set to 48000 Hz. More info can be found here including a visual: https://discourse.libsdl.org/t/slight-buzz-in-audio-in-mercurial/22553

On 2017-08-09 05:25:35 +0000, Ryan C. Gordon wrote:

(Sorry if you get a lot of copies of this email, we're touching dozens of bug reports right now.)

Tagging a bunch of bugs as target-2.0.6.

This means we're in the final stretch for an official SDL 2.0.6 release! These are the bugs we really want to fix before shipping if humanly possible.

That being said, we don't promise to fix them because of this tag, we just want to make sure we don't forget to deal with them before we bless a final 2.0.6 release, and generally be organized about what we're aiming to ship. After some debate, we might just remove this tag again and deal with it for a later release.

Hopefully you'll hear more about this bug soon. If you have more information (including "this got fixed at some point, nevermind"), we would love to have you come add more information to the bug report when you have a moment.

Thanks!
--ryan.

On 2017-09-21 07:42:20 +0000, Ryan C. Gordon wrote:

I've replaced the resampler with a better one, which should resolve this problem.

https://hg.libsdl.org/SDL/rev/a8382e3d0b54

--ryan.

On 2017-09-21 22:20:46 +0000, Trent Gamblin wrote:

I tested Mercurial with the original problem and it sounds good now. Thanks!

On 2017-09-21 22:29:48 +0000, Trent Gamblin wrote:

Sorry about this but my test was flawed. I was creating the stream with the same sampling rate as the device. When they are different I still hear a lot of high pitched noise that isn't there with SDL 2.0.5. Perhaps I can send you some code that exhibits the problem.

On 2017-09-21 22:34:42 +0000, Trent Gamblin wrote:

Looks like my checkout isn't updated... I'm not familiar with Mercurial. I did an 'hg pull' but I don't have the changes. Guess I'll just trust that it will be OK.

On 2017-09-21 22:43:49 +0000, Ryan C. Gordon wrote:

(In reply to Trent Gamblin from comment # 5)

Looks like my checkout isn't updated... I'm not familiar with Mercurial. I
did an 'hg pull' but I don't have the changes. Guess I'll just trust that it
will be OK.

Hg pull gets new data from the server. "hg update" then takes that data and merges it into your local source code with it.

--ryan.

On 2017-09-21 22:51:48 +0000, Trent Gamblin wrote:

Thanks for that. After getting the updates I tested again. The original problem is gone. There was a new problem in that there were some crackles/pops. However using a smaller buffer (not larger, as I tried first) fixes it.

On 2017-09-22 00:12:29 +0000, Trent Gamblin wrote:

I've tested the new code on two PCs. Using a small buffer helps but there is still a lot of noise on wasapi (not the same kind of noise as the original bug) compared to directsound. It's more of a crackling/popping similar to a unfilled buffer every few moments. Probably best to open a new bug though.

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

No branches or pull requests

1 participant