ladybird/Userland/Applications
Nick Miller 9a2c80c791 SoundPlayer: Handle any input file sample rate
This commit addresses two issues:
1. If you play a 96 KHz Wave file, the slider position is incorrect,
   because it is assumed all files are 44.1 KHz.
2. For high-bitrate files, there are audio dropouts due to not
   buffering enough audio data.

Issue 1 is addressed by scaling the number of played samples by the
ratio between the source and destination sample rates.

Issue 2 is addressed by buffering a certain number of milliseconds
worth of audio data (instead of a fixed number of bytes).
This makes the the buffer size independent of the source sample rate.

Some of the code is redesigned to be simpler. The code that did the
book-keeping of which buffers need to be loaded and which have been
already played has been removed. Instead, we enqueue a new buffer based
on a low watermark of samples remaining in the audio server queue.

Other small fixes include:
1. Disable the stop button when playback is finished.
2. Remove hard-coded instances of 44100.
3. Update the GUI every 50 ms (was 100), which improves visualizations.
2021-06-21 03:13:59 +04:30
..
3DFileViewer Everywhere: Add component declarations 2021-06-17 11:03:51 +02:00
About Everywhere: Add component declarations 2021-06-17 11:03:51 +02:00
AnalogClock Everywhere: Add component declarations 2021-06-17 11:03:51 +02:00
Browser Browser: Enable close button on tabs 2021-06-20 15:16:26 +02:00
Calculator Everywhere: Add component declarations 2021-06-17 11:03:51 +02:00
Calendar Everywhere: Add component declarations 2021-06-17 11:03:51 +02:00
CrashReporter Everywhere: Add component declarations 2021-06-17 11:03:51 +02:00
Debugger Everywhere: Add component declarations 2021-06-17 11:03:51 +02:00
DisplaySettings WindowServer: Add API to set/get screen layouts 2021-06-20 14:57:26 +02:00
FileManager Everywhere: Add component declarations 2021-06-17 11:03:51 +02:00
FontEditor Everywhere: Add component declarations 2021-06-17 11:03:51 +02:00
Help Everywhere: Add component declarations 2021-06-17 11:03:51 +02:00
HexEditor Everywhere: Add component declarations 2021-06-17 11:03:51 +02:00
ImageViewer Everywhere: Add component declarations 2021-06-17 11:03:51 +02:00
IRCClient Everywhere: Add component declarations 2021-06-17 11:03:51 +02:00
KeyboardMapper Everywhere: Add component declarations 2021-06-17 11:03:51 +02:00
KeyboardSettings Everywhere: Add component declarations 2021-06-17 11:03:51 +02:00
Magnifier Everywhere: Add component declarations 2021-06-17 11:03:51 +02:00
MouseSettings Everywhere: Add component declarations 2021-06-17 11:03:51 +02:00
PDFViewer Everywhere: Add component declarations 2021-06-17 11:03:51 +02:00
Piano Everywhere: Add component declarations 2021-06-17 11:03:51 +02:00
PixelPaint PixelPaint: Add basic support for closing tabs 2021-06-20 15:16:26 +02:00
Run Everywhere: Add component declarations 2021-06-17 11:03:51 +02:00
SoundPlayer SoundPlayer: Handle any input file sample rate 2021-06-21 03:13:59 +04:30
SpaceAnalyzer Everywhere: Add component declarations 2021-06-17 11:03:51 +02:00
Spreadsheet LibJS: Replace boolean without_side_effects parameters with an enum 2021-06-17 16:52:15 +02:00
SystemMonitor Everywhere: Add component declarations 2021-06-17 11:03:51 +02:00
Terminal Everywhere: Add component declarations 2021-06-17 11:03:51 +02:00
TextEditor Everywhere: Add component declarations 2021-06-17 11:03:51 +02:00
ThemeEditor Everywhere: Add component declarations 2021-06-17 11:03:51 +02:00
VideoPlayer Everywhere: Add component declarations 2021-06-17 11:03:51 +02:00
Welcome Everywhere: Add component declarations 2021-06-17 11:03:51 +02:00
CMakeLists.txt VideoPlayer: Create application to parse (and eventually play) videos 2021-06-12 22:48:28 +04:30