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

cleanup: Normalise audio to -1.0 dB. #316

Merged
merged 1 commit into from
Dec 27, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions audio/resources/format.md → audio/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@ You can use ffmpeg to create those files as follows:
ffmpeg -i notification.wav -f s16le -acodec pcm_s16le -ac 1 -ar 48000 notification.s16le.pcm
```

You can run `make` in this directory to do this for all files.

# Normalization

All sound files should have their maximum at -1.0 dB.
Expand Down
6 changes: 3 additions & 3 deletions audio/include/audio/iaudiosink.h
Original file line number Diff line number Diff line change
Expand Up @@ -72,11 +72,11 @@ class IAudioSink
case Sound::NewMessage:
return QStringLiteral(":/audio/notification.s16le.pcm");
case Sound::IncomingCall:
return QStringLiteral(":/audio/ToxIncomingCall.s16le.pcm");
return QStringLiteral(":/audio/call_incoming.s16le.pcm");
case Sound::OutgoingCall:
return QStringLiteral(":/audio/ToxOutgoingCall.s16le.pcm");
return QStringLiteral(":/audio/call_outgoing.s16le.pcm");
case Sound::CallEnd:
return QStringLiteral(":/audio/ToxEndCall.s16le.pcm");
return QStringLiteral(":/audio/call_end.s16le.pcm");
}
assert(false);
return {};
Expand Down
Binary file removed audio/original/ToxEndCall.wav
Binary file not shown.
Binary file removed audio/original/ToxIncomingCall.wav
Binary file not shown.
Binary file removed audio/original/ToxOutgoingCall.wav
Binary file not shown.
Binary file added audio/original/call_end.wav
Binary file not shown.
Binary file added audio/original/call_incoming.wav
Binary file not shown.
Binary file added audio/original/call_outgoing.wav
Binary file not shown.
Binary file modified audio/original/notification.wav
Binary file not shown.
Binary file removed audio/resources/ToxEndCall.s16le.pcm
Binary file not shown.
Binary file removed audio/resources/ToxIncomingCall.s16le.pcm
Binary file not shown.
Binary file removed audio/resources/ToxOutgoingCall.s16le.pcm
Binary file not shown.
6 changes: 3 additions & 3 deletions audio/resources/audio_res.qrc
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
<RCC>
<qresource prefix="/audio">
<file>call_end.s16le.pcm</file>
<file>call_incoming.s16le.pcm</file>
<file>call_outgoing.s16le.pcm</file>
<file>notification.s16le.pcm</file>
<file>ToxEndCall.s16le.pcm</file>
<file>ToxIncomingCall.s16le.pcm</file>
<file>ToxOutgoingCall.s16le.pcm</file>
</qresource>
</RCC>
Binary file added audio/resources/call_end.s16le.pcm
Binary file not shown.
Binary file added audio/resources/call_incoming.s16le.pcm
Binary file not shown.
Binary file added audio/resources/call_outgoing.s16le.pcm
Binary file not shown.
Binary file modified audio/resources/notification.s16le.pcm
Binary file not shown.
Loading