Commit graph

11 commits

Author SHA1 Message Date
Christopher Snowhill
146dae216a Visualization: Optimize Swift code handling arrays
This looks a lot better than some ruddy for-loops.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2025-02-13 19:58:34 -08:00
Christopher Snowhill
d9a08914df Visualization: Clean up Swift code a bit
Some of this is handled in simpler ways now.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2025-02-13 02:09:17 -08:00
Christopher Snowhill
9701bd5421 Visualization: Do not increment latency on write
The latency should not be incremented when writing sample data to the
buffer, but rather be posted by the output.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2025-02-13 01:13:10 -08:00
Christopher Snowhill
5392a5fa91 Revert "Visualization: Tweak systems a bit"
This reverts commit 6c24ad8244.
2025-02-10 14:31:22 -08:00
Christopher Snowhill
6c24ad8244 Visualization: Tweak systems a bit
This should improve performance slightly. It's
still recommended to switch off SceneKit to
save CPU usage, or switch of vis entirely.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2025-02-01 15:08:56 -08:00
Christopher Snowhill
2e5140a321 Visualization: Make latency animation smoother
Compensate for latency by incrementing an offset
according to animation frame rate.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2024-09-20 22:25:02 -07:00
Christopher Snowhill
b07a6fd098
Visualization: Improve latency and buffering appearance
Adjust the buffering so if latency is too low, we fill the rest of
the output with silence instead of peeking at the oldest part
of the buffer. Also increase latency by half a buffer size so
that the requested sample is in the center of the buffer, which
improves the 4096 sample situation with the current low
latency output.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2023-10-03 19:35:20 -07:00
Christopher Snowhill
2102fc1c44
Visualization: Reset buffer on playback stop
Reset the visualization system when stopping playback.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2023-10-03 19:35:16 -07:00
Christopher Snowhill
919661c9e8
Attempt to stabilize visualization flutter
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2023-10-02 10:57:06 -07:00
Christopher Snowhill
be87e5433c [Cog Audio] Make the Swift Vis Controller work
And this is the actual meat of getting it to work properly, the changes
the Swift code needed to actually be fully functional.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-08-05 21:38:58 -07:00
Christopher Snowhill
cbeba3fa0e First module converted to swift, but broken 2022-08-05 21:38:44 -07:00