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

Fix airpods recording #783

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Conversation

dm3ch
Copy link

@dm3ch dm3ch commented Jun 4, 2022

It's a very naive attempt to fix a bug with AirPods (24kHZ sample rate) recorded voice messages.
I just added "resampling" code similar to what it's already there for 16kHZ. Now in my self-built version of Telegram client, I haven't got a speedup of recording and voice pitch.

Actually, it would be better to write universal re-sampling code, but I'm pretty bad in audio and in swift to do it myself.
During the research I also found that in iOS client (https://github.com/TelegramMessenger/Telegram-iOS/blob/702f2547830ca406ce41081ea4170f24533f9a01/submodules/TelegramUI/Sources/ManagedAudioRecorder.swift ) there's pretty similar part of code for audio recording but it doesn't have transcoding and it works great with AirPods, actually I don't know why, but it's too much differences to easily port it to this project for me.

#112 #590 #692

@CLAassistant
Copy link

CLAassistant commented Jun 4, 2022

CLA assistant check
All committers have signed the CLA.

@dm3ch
Copy link
Author

dm3ch commented Jun 21, 2022

@overtake Sorry for the mention, but maybe you can take a look at this PR. The problem with airpods is very annoying for me and some other users.

@overtake
Copy link
Owner

overtake commented Dec 30, 2022

i didn't notice this PR. Sorry. anyway. fixed. thanks.

i fixed in the same way

@DeFiYaco
Copy link

@overtake How to know when this will be released on the app store? It still does not work for me with the app store build.

@overtake
Copy link
Owner

@overtake How to know when this will be released on the app store? It still does not work for me with the app store build.

i will send to review today. i bet on weekends or next week.

you also can switch to stable version macos.telegram.org. 9.3 coming today.

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