aboutsummaryrefslogtreecommitdiffstats
path: root/alc
Commit message (Collapse)AuthorAgeFilesLines
* Distinguish a couple log messagesChris Robinson2023-01-301-3/+3
| | | | And downgrade an ERR to a WARN
* Transpose the ambisonic rotation matrix and helper coefficientsChris Robinson2023-01-261-39/+32
|
* Transpose the ambisonic voice mixing matrixChris Robinson2023-01-251-34/+41
| | | | | To more efficiently prepare the panning coefficients. Also avoid making a stack copy of the matrix to reuse as the target.
* Use explicit arrays for the remix table target mixesChris Robinson2023-01-241-16/+53
| | | | Seems inline initializer lists become garbage when stored in a span.
* Use the object serial ID from PipeWire when availableChris Robinson2023-01-241-21/+47
| | | | | | | | | | | Using the node ID as a target is deprecated in newer versions of PipeWire. The serial ID is a monotonic 64-bit integer ID, incremeneted for every object created, so is guaranteed to always refer to the same target (until it wraps around, which I suppose isn't expected/allowed to happen), compared to the 32-bit node ID which I guess allows reuse. We could instead use the target node's name instead of the serial ID, but an integer is nicer to manage than a string.
* Increase the pitch shifter oversample factor to 8Chris Robinson2023-01-191-38/+37
| | | | | | And use 32-bit float processing. Float precision doesn't seem to be detrimental to the overall quality, while 8x oversampling seems to help against the harmonics.
* Minor code refactor for the frequency shifter effectChris Robinson2023-01-191-47/+50
|
* Improve the output scaling of the pitch shifterChris Robinson2023-01-191-1/+1
| | | | | | For tones than land exactly on a frequency bin, which are subject to the least amount of error when not adjusted, this produces a level that more closely matches the original input.
* Don't return a large-ish array on the stackChris Robinson2023-01-191-15/+17
|
* Slightly improve phase wrapping in the pitch shifterChris Robinson2023-01-191-10/+11
|
* Limit pitch shifter pitch between 0.5 and 2.Chris Robinson2023-01-181-1/+1
| | | | | | The current algorithm isn't designed to go beyond that. The course tuning property is limited to that range as well, though the fine tuning property could potentially extend it out by half a semitone.
* Use constexpr variables instead of macrosChris Robinson2023-01-181-51/+57
|
* Use a variable to handle a long value definitionChris Robinson2023-01-181-2/+3
|
* Make a variable for a reused valueChris Robinson2023-01-172-3/+3
|
* Use a better frequency bin target for pitch shiftingChris Robinson2023-01-172-23/+47
| | | | And slightly adjust the Hann window.
* Change a couple macros to constexpr variablesChris Robinson2023-01-1610-33/+33
|
* Precalculate reused scale factorsChris Robinson2023-01-151-1/+1
|
* clang-tidy cleanups (#800)Rosen Penev2023-01-159-21/+21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * clang-tidy: use bool literals Found with modernize-use-bool-literals Signed-off-by: Rosen Penev <[email protected]> * clang-tidy: replace std::bind with lambdas Found with modernize-avoid-bind Signed-off-by: Rosen Penev <[email protected]> * clang-tidy: use data() instead of pointer stuff Found with readability-container-data-pointe Signed-off-by: Rosen Penev <[email protected]> * clang-tidy: use empty() Found with readability-container-size-empty Signed-off-by: Rosen Penev <[email protected]> * clang-tidy: remove static in anon namespace Found with readability-static-definition-in-anonymous-namespace Signed-off-by: Rosen Penev <[email protected]> * clang-tidy: remove const return Found with readability-const-return-type Signed-off-by: Rosen Penev <[email protected]> Signed-off-by: Rosen Penev <[email protected]>
* Don't explicitly try to spawn servers by defaultChris Robinson2023-01-142-2/+2
|
* Don't use doubles for upsampling B-Format transformsChris Robinson2023-01-131-3/+3
|
* Avoid using a non-0 span length over nullptrChris Robinson2023-01-131-17/+32
|
* Write proper samples when starting the PulseAudio streamChris Robinson2023-01-131-17/+3
| | | | | Instead of silence, to ensure the number of samples written to PulseAudio is the same as the number mixed/rendered.
* Avoid a dead storeChris Robinson2023-01-131-1/+0
|
* Avoid single-use static class method wrappersChris Robinson2023-01-131-81/+46
|
* Avoid unnecessary uses of make_optionalChris Robinson2023-01-133-28/+30
|
* Rename some members for clarityChris Robinson2023-01-121-22/+22
|
* Fix RingBuffer crash in OpenSL backend (#807)IamSN0WBALL2023-01-121-1/+1
| | | Co-authored-by: IamSN0WBALL <[email protected]>
* Use a span instead of a count+pointerChris Robinson2023-01-111-1/+1
|
* Rename some struct membersChris Robinson2023-01-102-5/+5
| | | | And make a related function a member function
* Don't rely on mRateMatch while waiting for PipeWire timing infoChris Robinson2023-01-091-5/+2
|
* Handle the stereo-encoding option for loopback devices tooChris Robinson2023-01-091-12/+12
|
* Fix handling the ALC_HRTF_SOFT attributeChris Robinson2023-01-091-1/+20
|
* Add an option to mix on PipeWire's non-RT threadChris Robinson2023-01-081-14/+14
|
* Better handle negative sample rate valuesChris Robinson2023-01-081-5/+5
|
* Update some config commentsChris Robinson2023-01-081-1/+1
|
* Get device config options earlier in a device updateChris Robinson2023-01-071-310/+275
|
* Avoid using a reversed all-pass for the front stablizerChris Robinson2023-01-062-7/+2
| | | | | | While a neat trick, it's been shown to be too volatile and add noise as the signal gets louder. It's better to just accept the phase shift and ensure everything stays aligned.
* Rename some lambda parameters to avoid shadowing warningsChris Robinson2023-01-055-15/+15
|
* Add and use mixers that process one input and output channelChris Robinson2023-01-054-8/+8
|
* Simplify handling effect output for spatial effectsChris Robinson2023-01-045-83/+140
| | | | | | | | | | | | Effects are given a 3D ambisonic buffer of the same order as the device, for processing surround sound. Effects that pass input channels to matching output channels as it processes them don't need to mix each input channel to all output channels. At most, an input channel may mix to a different output channel, if the target buffer uses a different channel layout, and need a gain adjustment, if it uses a different scaling. With a 2D output buffer, a number of channels can be skipped altogether.
* Handle UHJ better with convolution reverbChris Robinson2023-01-011-44/+66
| | | | | | It's now decoded to B-Format while being FFT'd, and processed as B-Format. Again, not that UHJ should really ever be used for convolution, but it's a valid format someone may want to use despite the overhead from converting it.
* Avoid some explicit casts and referencesChris Robinson2023-01-013-15/+16
|
* Use a simple spinlock to protect the current global contextChris Robinson2022-12-303-7/+26
| | | | | This will be much for efficient than a recursive mutex, given the amount of contention will be very low.
* Avoid using a macro to set a context error and returnChris Robinson2022-12-241-6/+0
|
* Avoid duplicate code to update the reverb delay linesChris Robinson2022-12-221-14/+7
|
* Include the reverb delay times in the fade sample countChris Robinson2022-12-201-24/+15
|
* Make sure to update the input filters with partial updatesChris Robinson2022-12-201-1/+11
|
* Clean up some reverb mixing loopsChris Robinson2022-12-191-21/+18
|
* Turn a static member function into a lambda where it's usedChris Robinson2022-12-191-31/+29
| | | | And clean up some parameters
* Remove a redundant commentChris Robinson2022-12-181-4/+1
|