aboutsummaryrefslogtreecommitdiffstats
path: root/alc/alc.cpp
Commit message (Collapse)AuthorAgeFilesLines
* clang-tidy cleanups (#800)Rosen Penev2023-01-151-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * 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]>
* Avoid a dead storeChris Robinson2023-01-131-1/+0
|
* Avoid unnecessary uses of make_optionalChris Robinson2023-01-131-20/+20
|
* 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
|
* 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-061-5/+0
| | | | | | 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.
* Use a simple spinlock to protect the current global contextChris Robinson2022-12-301-7/+17
| | | | | This will be much for efficient than a recursive mutex, given the amount of contention will be very low.
* Avoid using a macro to wrap standard attributesChris Robinson2022-12-061-2/+2
|
* Avoid LIKELY/UNLIKELY macrosChris Robinson2022-12-051-2/+2
|
* Add missing device_clock/source_latency enums for queryingChris Robinson2022-11-291-0/+9
|
* Add preliminary support for 7.1.4 output modesChris Robinson2022-11-031-0/+3
| | | | | | | | I don't know how different sound APIs handle 7.1.4 ("Atmos" or "Auro3D") output, but currently it simply specifies the additional channels with the height channel labels. This isn't likely how it works for a virtualized channel bed, for playing over other with-height configurations (7.1.2, 5.1.4, etc), but this should be an okay start.
* Add functions to start sources at a particular device timeChris Robinson2022-11-031-0/+3
| | | | | | | | This starts a source at a particular device clock time, rounded to the nearest sample (really, 4th sample for SIMD reasons), allowing to start a sound at a particular point in the output instead of the next update. Unlike using negative offsets, this is not affected by pitch/velocity.
* Add a warning when using the old UHJ filter optionChris Robinson2022-10-211-2/+8
|
* Add separate filter options for UHJ encoding and decodingChris Robinson2022-10-211-5/+16
|
* Add an IIR filter option for UHJ encoding/decodingChris Robinson2022-10-211-2/+4
| | | | | | This uses the reversed-allpass trick to maintain linear phase. with a 256- sample look-ahead/delay to minimize distortion. This should better preserve low frequencies while maintaining a proper phase response.
* Allow the remix tables to be variable lengthChris Robinson2022-08-281-9/+9
|
* Rename the UHJ filter config optionChris Robinson2022-08-091-2/+2
|
* Add an option for higher quality UHJ filtersChris Robinson2022-08-081-14/+26
|
* Parameterize the UHJ filter lengthChris Robinson2022-08-071-2/+2
|
* Don't store and manage wet buffers separatelyChris Robinson2022-07-151-7/+13
|
* Allocate EffectSlots in clustersChris Robinson2022-07-151-0/+14
|
* Dynamically allocate EffectSlot objectsChris Robinson2022-07-151-2/+2
|
* Add a config compat option for NFC distance scalingChris Robinson2022-07-071-1/+1
| | | | | | | | | | | | Currently there's no way for an application to specify the "real world" scale for in-game units. If the game doesn't use one unit to represent what should be perceived as one meter to the user, the NFC filter's effect will be too near or too far sounding. This allows adjusting the unit scale as applied to the NFC filters only, correcting the misalignment. This also removes the influence of EFX's MetersPerUnit from the NFC filters, since many games don't use it, and those that do won't know it also influences the perceived wave curvature along with the air absorption strength.
* Use an inline function instead of a function-like macroChris Robinson2022-06-121-6/+7
|
* Disable EAX if the Chorus effect is disabledChris Robinson2022-06-101-2/+7
|
* Increase the priority of the ALSA backendChris Robinson2022-06-041-3/+3
| | | | | | | | | So that it's tried before sndio. Many Linux systems seem to have libsndio installed as a hard dependency from SDL2, but not the server component to actually make it work. And because there's no way to test if it's usable without opening a device, the backend would get selected over ALSA and subsequently fail to work. As a result, Linux users that don't use PipeWire or PulseAudio would have to explicitly configure for ALSA.
* Ensure enough default sends for EAX with the config option setChris Robinson2022-05-271-10/+24
|
* Move EAX files to their own sub-directoryChris Robinson2022-05-161-2/+2
|
* Handle 3D7.1 as a separate channel configurationChris Robinson2022-04-261-0/+4
| | | | | | | It's treated as 5.1 + 2 aux channels. This allows AL_DIRECT_CHANNELS_SOFT to behave better, not forwarding rear left/right channel inputs to lower front and upper rear, and allows reporting a more appropriate output mode to the app instead of 7.1.
* Finalize ALC_SOFT_output_modeChris Robinson2022-04-171-1/+1
|
* Use a bool type for boolean parametersChris Robinson2022-04-161-1/+1
|
* Include ALC_OUTPUT_MODE_SOFT with ALC_ALL_ATTRIBUTESChris Robinson2022-04-161-4/+10
|
* Update the ALC_SOFT_output_mode surround enumsChris Robinson2022-04-151-0/+3
| | | | | | The values are identical to the matching loopback channel configuration enums, so for example ALC_5POINT1_SOFT is interchangable with ALC_SURROUND_5_1_SOFT, this is simply providing a cleaner styling for potential future modes.
* Fix ALC_SOFT_reopen_device for the null device extension listChris Robinson2022-04-011-1/+1
|
* Finalize ALC_SOFT_reopen_deviceChris Robinson2022-04-011-1/+1
|
* Remove the reversed all-pass trick in MixDirectHrtfBaseChris Robinson2022-03-301-2/+0
| | | | Given the minimum phase HRTF, it's not going to stay linear phase anyway.
* Make and use a Default enum for StereoEncodingChris Robinson2022-03-291-6/+6
|
* Rename ALC_STEREO_PLAIN_SOFT and don't duplicate ALC_HRTF_SOFTChris Robinson2022-03-291-3/+3
|
* Handle more modes with the ALC_OUTPUT_MODE_SOFT attributeChris Robinson2022-03-231-180/+207
|
* Better ensure attributes are properly tracedChris Robinson2022-03-171-28/+15
|
* Fix tracing the ALC_OUTPUT_MODE_SOFT attributeChris Robinson2022-03-171-1/+1
|
* Add options to reverse local X and Y coordinatesChris Robinson2022-03-101-7/+13
| | | | | To go along with reverse-z on the other axii. This is only for games that have position/orientation errors causing top-bottom (or left-right) inversion.
* Add a config option for reverse-zChris Robinson2022-03-101-1/+11
| | | | | | The same as the __ALSOFT_REVERSE_Z env var, but in the config file. Should only be used for per-game config files (either along side the executable, or setting the ALSOFT_CONF env var when launching the app).
* Make some local constexpr variables staticChris Robinson2022-02-231-24/+18
|
* Avoid more unnecessary atomicsChris Robinson2022-02-131-1/+1
|
* Don't make mPropsDirty atomicChris Robinson2022-02-131-1/+1
| | | | It's only ever used under the ALCcontext::mPropLock mutex.
* Don't hide EAX functions behind a contextChris Robinson2022-02-101-4/+28
| | | | | | | The standard says a function being returned doesn't necessarily mean it's usable, and calling them will return failure if called when not usable. The config option still prevents it from being returned, to better hide it when disabled globally.