summaryrefslogtreecommitdiff
path: root/drivers/pulseaudio
AgeCommit message (Collapse)Author
2023-01-23[Linux/BSD] Include headers for dynamically loaded libraries to simplify ↵bruvzg
build dependencies.
2023-01-23Convert en_GB spelling to en_US with codespellRémi Verschelde
2023-01-05One Copyright Update to rule them allRémi Verschelde
As many open source projects have started doing it, we're removing the current year from the copyright notice, so that we don't need to bump it every year. It seems like only the first year of publication is technically relevant for copyright notices, and even that seems to be something that many companies stopped listing altogether (in a version controlled codebase, the commits are a much better source of date of publication than a hardcoded copyright statement). We also now list Godot Engine contributors first as we're collectively the current maintainers of the project, and we clarify that the "exclusive" copyright of the co-founders covers the timespan before opensourcing (their further contributions are included as part of Godot Engine contributors). Also fixed "cf." Frenchism - it's meant as "refer to / see".
2022-10-01Remove usage of unitialized variablesRafał Mikrut
2022-08-25Merge pull request #64607 from RandomShaper/safe_audio_threadingRémi Verschelde
2022-08-22Replace Array return types with TypedArraykobewi
2022-08-19Make audio thread control flags safePedro J. Estébanez
2022-04-20Fix more issues found by cppcheck.bruvzg
2022-04-06Fix some issues found by cppcheck.bruvzg
2022-01-03Update copyright statements to 2022Rémi Verschelde
Happy new year to the wonderful Godot community!
2021-11-09Print the number of PulseAudio input channels when in verbose modeHugo Locurcio
This is useful information to have for troubleshooting, and it's said to sidestep a possible race condition issue that breaks microphone recording on Linux.
2021-11-06Use application name for pulseaudio deviceNathan Franke
2021-10-29AudioDriverPulseAudio: move Vector Cow access outside tight loop.Ibrahn Sahir
Replaced some in-loop uses of Vector.write with an out of loop ptrw, to avoid a lot of superfluous reads on the CowData ref count.
2021-10-26Save all 64 bits of get_ticks_msec() in more casesMax Hilbrunner
2021-06-03Fix crash when using ALSA MIDI with PulseAudioPedro J. Estébanez
2021-05-13Handle having no sinks in the PulseAudio driver.R. Alex Hofer
Also make PulseAudio errors more verbose.
2021-02-20An update to the dylibloader for older inttypesHein-Pieter van Braam-Stewart
This #define's older inttypes to their newer versions and #includes <stdint.h> in the generated files. This will help with older glibc/compiler versions using headers generated on newer systems. This closes #46223
2021-02-18Reorganize Project Settingsreduz
-Advanced Settings toggle also hides advanced properties when disabled -Simplified Advanced Bar (errors were just plain redundant) -Reorganized rendering quality settings. -Reorganized miscelaneous settings for clean up.
2021-02-18Don't clobber original library symbolsHein-Pieter van Braam-Stewart
It appears that we can get a fun circle dependency on a shared object on some system configurations causing issues with our 'fake' function pointer names. This can lead to a crash. The new wrapper generator renames all the symbols so this can't happen anymore. See https://github.com/hpvb/dynload-wrapper/commit/704135e This closes #46140
2021-02-16Dynamically load libpulse.so.0 and libasound.so.1 on LinuxHein-Pieter van Braam-Stewart
By generating stubs using https://github.com/hpvb/dynload-wrapper we can dynamically load libpulse and libasound on systems where it is available. Both are still a build-time requirement but no longer a run-time dependency. For maintenance purposes the wrappers should not need to be re-generated unless we want to bump pulse or asound to an incompatible version. It is unlikely we will want to do this any time soon. This closes #20978
2021-01-29Modernize ThreadPedro J. Estébanez
- Based on C++11's `thread` and `thread_local` - No more need to allocate-deallocate or check for null - No pointer anymore, just a member variable - Platform-specific implementations no longer needed (except for the few cases of non-portable functions) - Simpler for `NO_THREADS` - Thread ids are now the same across platforms (main is 1; others follow)
2021-01-01Update copyright statements to 2021Rémi Verschelde
Happy new year to the wonderful Godot community! 2020 has been a tough year for most of us personally, but a good year for Godot development nonetheless with a huge amount of work done towards Godot 4.0 and great improvements backported to the long-lived 3.2 branch. We've had close to 400 contributors to engine code this year, authoring near 7,000 commit! (And that's only for the `master` branch and for the engine code, there's a lot more when counting docs, demos and other first-party repos.) Here's to a great year 2021 for all Godot users 🎆
2020-11-07Reorganized core/ directory, it was too fatty alreadyreduz
-Removed FuncRef, since Callable makes it obsolete -Removed int_types.h as its obsolete in c++11+ -Changed color names code
2020-09-03Ensure header guards enclose entire header.Marcel Admiraal
2020-05-18Move mix_rate, ouput_latency to AudioDriverManagerFabio Alessandrelli
Each driver used to define the (same) project settings values `audio/mix_rate` and `audio/output_latency`, but the setting names are not driver specific. Overriding is still possible via platform tags.
2020-05-14Style: Enforce braces around if blocks and loopsRémi Verschelde
Using clang-tidy's `readability-braces-around-statements`. https://clang.llvm.org/extra/clang-tidy/checks/readability-braces-around-statements.html
2020-05-14Style: clang-format: Disable KeepEmptyLinesAtTheStartOfBlocksRémi Verschelde
Which means that reduz' beloved style which we all became used to will now be changed automatically to remove the first empty line. This makes us lean closer to 1TBS (the one true brace style) instead of hybridating it with some Allman-inspired spacing. There's still the case of braces around single-statement blocks that needs to be addressed (but clang-format can't help with that, but clang-tidy may if we agree about it). Part of #33027.
2020-05-14Port member initialization from constructor to declaration (C++11)Rémi Verschelde
Using `clang-tidy`'s `modernize-use-default-member-init` check and manual review of the changes, and some extra manual changes that `clang-tidy` failed to do. Also went manually through all of `core` to find occurrences that `clang-tidy` couldn't handle, especially all initializations done in a constructor without using initializer lists.
2020-04-02Replace NULL with nullptrlupoDharkael
2020-03-30SCons: Format buildsystem files with psf/blackRémi Verschelde
Configured for a max line length of 120 characters. psf/black is very opinionated and purposely doesn't leave much room for configuration. The output is mostly OK so that should be fine for us, but some things worth noting: - Manually wrapped strings will be reflowed, so by using a line length of 120 for the sake of preserving readability for our long command calls, it also means that some manually wrapped strings are back on the same line and should be manually merged again. - Code generators using string concatenation extensively look awful, since black puts each operand on a single line. We need to refactor these generators to use more pythonic string formatting, for which many options are available (`%`, `format` or f-strings). - CI checks and a pre-commit hook will be added to ensure that future buildsystem changes are well-formatted.
2020-02-26Reimplement Mutex with C++'s <mutex>Pedro J. Estébanez
Main: - It's now implemented thanks to `<mutex>`. No more platform-specific implementations. - `BinaryMutex` (non-recursive) is added, as an alternative for special cases. - Doesn't need allocation/deallocation anymore. It can live in the stack and be part of other classes. - Because of that, it's methods are now `const` and the inner mutex is `mutable` so it can be easily used in `const` contexts. - A no-op implementation is provided if `NO_THREADS` is defined. No more need to add `#ifdef NO_THREADS` just for this. - `MutexLock` now takes a reference. At this point the cases of null `Mutex`es are rare. If you ever need that, just don't use `MutexLock`. - Thread-safe utilities are therefore simpler now. Misc.: - `ScopedMutexLock` is dropped and replaced by `MutexLock`, because they were pretty much the same. - Every case of lock, do-something, unlock is replaced by `MutexLock` (complex cases where it's not straightfoward are kept as as explicit lock and unlock). - `ShaderRD` contained an `std::mutex`, which has been replaced by `Mutex`.
2020-02-05Remove duplicate WARN_PRINT macro.Marcel Admiraal
2020-02-05Remove duplicate ERR_PRINT macro.Marcel Admiraal
2020-01-20Revert "Exposes capture methods to AudioServer + documentation" #30468Rémi Verschelde
Reverts the following commits: - c81ec6f26d40b70283958a4ef3e216fb32cbaf14: "Exposes capture methods to AudioServer, variable renames for consistency, added documentation." - 47c558b98abf842910c780294314326662410cdf: "Expose audio callbacks as signals." - dabaa11b3c451e9b8f2cca7e563bd9ec51edb169: "Fix to make sure the capture buffers are deallocated at shutdown. Silences warnings." Some documentation improvements were kept for pre-existing methods. See rationale for reverting these changes in #30468.
2020-01-01Update copyright statements to 2020Rémi Verschelde
Happy new year to the wonderful Godot community! We're starting a new decade with a well-established, non-profit, free and open source game engine, and tons of further improvements in the pipeline from hundreds of contributors. Godot will keep getting better, and we're looking forward to all the games that the community will keep developing and releasing with it.
2019-12-28Check for null pointer in PulseAudio server info callback.Marcel Admiraal
2019-08-07Merge pull request #31077 from qarmin/coverity_bugsRémi Verschelde
Change some code proposed by Coverity and Cppcheck
2019-08-07Add some code changes/fixes proposed by Coverity and Clang Tidyqarmin
2019-07-15Exposes capture methods to AudioServer, variable renames for consistency,Saracen
added documentation.
2019-07-01Explicitly set a channel map when initialising the Pulseaudio stream.zwostein
2019-02-20Add -Wshadow=local to warnings and fix reported issues.marxin
Fixes #25316.
2019-01-07Merge pull request #24301 from marcelofg55/default_device_pulseaudioRémi Verschelde
PulseAudio driver will now change the device if the default system device changes
2019-01-01Update copyright statements to 2019Rémi Verschelde
Happy new year to the wonderful Godot community!
2018-12-12PulseAudio driver will now change the device if the default system device ↵Marcelo Fernandez
changes
2018-12-11Moved member variables to initializer listWilson E. Alvarez
2018-11-25Fix possible error when switching audio devices with PulseAudioMarcelo Fernandez
2018-11-17Fix distorted sound with PulseAudio and uneven channelsMarcelo Fernandez
2018-10-20Fix possible audio input buffer issuesMarcelo Fernandez
2018-09-28SCons: Build thirdparty code in own env, disable warningsRémi Verschelde
Also remove unnecessary `Export('env')` in other SCsubs, Export should only be used when exporting *new* objects.
2018-09-27Fix warnings about unhandled enum value in switch [-Wswitch]Rémi Verschelde
Fixes GCC 5 warnings of the form: core/io/http_client.cpp:288:9: warning: enumeration value 'STATUS_SSL_HANDSHAKE_ERROR' not handled in switch [-Wswitch] core/io/marshalls.cpp:806:9: warning: enumeration value 'AABB' not handled in switch [-Wswitch] Those can be trivial cases where adding a default fallback is the solution, or more complex issues/hidden bugs where missed values are actually meant to be handled.