summaryrefslogtreecommitdiff
path: root/src/audio_core/audio_renderer.cpp (follow)
Commit message (Collapse)AuthorAgeFilesLines
* Project AndioGravatar Kelebek12022-07-221-343/+0
|
* Rework CoreTimingGravatar Kelebek12022-07-101-3/+7
|
* core: Replace all instances of ResultCode with ResultGravatar german772022-06-261-4/+4
|
* general: Convert source file copyright comments over to SPDXGravatar Morph2022-04-231-3/+2
| | | | | This formats all copyright comments according to SPDX formatting guidelines. Additionally, this resolves the remaining GPLv2 only licensed files by relicensing them to GPLv2.0-or-later.
* audio_core: Preserve front channel volume after 6 to 2 downmixGravatar Kelebek12021-07-081-19/+11
| | | | | | Many games report 6 channel output while only providing data for 2. We only output 2-channel audio regardless, and in the downmixing, front left/right only provide 36% of their volume. This is done assuming all of the other channels also contain valid data, but in many games they don't. This PR alters the downmixing to preserve front left/right, so volume is not lost. This improves volume in Link's Awakening, New Super Mario Bros U, Disgaea 6, Super Kirby Clash.
* Fix XC2/VOEZ crashing, add audio looping and a few misc fixesGravatar Kelebek12021-07-011-67/+63
|
* Decouple audio processing and run at variable rateGravatar Kelebek12021-06-271-75/+103
| | | | | | Currently, processing of audio samples is called from AudioRenderer's Update method, using a fixed 4 buffers to process the given samples. Games call Update at variable rates, depending on framerate and/or sample count, which causes inconsistency in audio processing. From what I've seen, 60 FPS games update every ~0.004s, but 30 FPS/160 sample games update somewhere between 0.02 and 0.04, 5-10x slower. Not enough samples get fed to the backend, leading to a lot of audio skipping. This PR seeks to address this by de-coupling the audio consumption and the audio update. Update remains the same without calling for buffer queuing, and the consume now schedules itself to run based on the sample rate and count.
* general: Replace RESULT_SUCCESS with ResultSuccessGravatar Morph2021-06-021-1/+1
| | | | Transition to PascalCase for result names.
* common: Move settings to common from core.Gravatar bunnei2021-04-141-1/+1
| | | | - Removes a dependency on core and input_common from common.
* hle: service: Acquire and release a lock on requests.Gravatar bunnei2020-12-281-8/+5
| | | | - This makes it such that we can safely access service members from CoreTiming thread.
* Merge pull request #5000 from lioncash/audio-errorGravatar bunnei2020-12-021-3/+3
|\ | | | | audio_core: Make shadowing and unused parameters errors
| * audio_core: Make shadowing and unused parameters errorsGravatar Lioncash2020-12-031-3/+3
| | | | | | | | Moves the audio code closer to enabling warnings as errors in general.
* | audio_core: Remove temp_mix_bufferGravatar Chloe Marcec2020-11-281-2/+1
|/ | | | It's unused and doesn't need to be initialized
* Addressed changesGravatar Chloe Marcec2020-11-171-2/+2
|
* audren: Make use of nodiscard, rework downmixing, release all buffersGravatar Chloe Marcec2020-11-171-25/+85
| | | | | | Preliminary work for upmixing & general cleanup. Fixes basic issues in games such as Shovel Knight and slightly improves the LEGO games. Upmixing stitll needs to be implemented. Audio levels in a few games will be fixed as we now use the downmix coefficients when possible instead of supplying our own
* Revert "core: Fix clang build"Gravatar bunnei2020-10-201-2/+2
|
* core: Fix clang buildGravatar Lioncash2020-10-171-2/+2
| | | | | | | Recent changes to the build system that made more warnings be flagged as errors caused building via clang to break. Fixes #4795
* audio_core: Remove unnecessary inclusionsGravatar Lioncash2020-09-251-4/+1
| | | | | Same behavior, but removes header dependencies where they don't need to be.
* Preliminary effectsGravatar David Marcec2020-08-171-4/+5
|
* Fix stream channel count when outputting to stereoGravatar David Marcec2020-07-251-1/+1
|
* Queue extra mix bufferGravatar David Marcec2020-07-251-0/+1
|
* audio_core: Apollo Part 1, AudioRenderer refactorGravatar David Marcec2020-07-251-372/+169
|
* audren: Implement RendererInfoGravatar David Marcec2020-06-131-3/+16
| | | | Fixes ZLA softlock
* fix logic error & scale sample volume based on voice volumeGravatar David Marcec2020-05-111-7/+9
|
* pass by const ref insteadGravatar David Marcec2020-05-111-8/+7
|
* audio_renderer: Better voice mixing and 6 channel downmixingGravatar David Marcec2020-05-111-11/+85
| | | | Supersedes #3738 and #3321
* audio_renderer: Preliminary BehaviorInfo (#3736)Gravatar David2020-04-201-10/+22
| | | | | | | | | | | | | * audio_renderer: Preliminary BehaviorInfo * clang format * Fixed IsRevisionSupported * fixed IsValidRevision * Fixed logic error & spelling errors & crash * Addressed issues
* core: memory: Move to Core::Memory namespace.Gravatar bunnei2020-04-171-7/+8
| | | | - helpful to disambiguate Kernel::Memory namespace.
* core/memory: Migrate over Read{8, 16, 32, 64, Block} to the Memory classGravatar Lioncash2019-11-261-8/+9
| | | | | | | | | | | | | | With all of the trivial parts of the memory interface moved over, we can get right into moving over the bits that are used. Note that this does require the use of GetInstance from the global system instance to be used within hle_ipc.cpp and the gdbstub. This is fine for the time being, as they both already rely on the global system instance in other functions. These will be removed in a change directed at both of these respectively. For now, it's sufficient, as it still accomplishes the goal of de-globalizing the memory code.
* core: Prepare various classes for memory read/write migrationGravatar Lioncash2019-11-261-11/+13
| | | | | | | | | | Amends a few interfaces to be able to handle the migration over to the new Memory class by passing the class by reference as a function parameter where necessary. Notably, within the filesystem services, this eliminates two ReadBlock() calls by using the helper functions of HLERequestContext to do that for us.
* kernel: Replace usage of boost::intrusive_ptr with std::shared_ptr for ↵Gravatar bunnei2019-11-241-1/+1
| | | | | | | | kernel objects. (#3154) * kernel: Replace usage of boost::intrusive_ptr with std::shared_ptr for kernel objects. - See https://github.com/citra-emu/citra/pull/4710 for details.
* Used revision 5 instead of 7, marked constexpr as staticGravatar David Marcec2019-09-211-2/+2
|
* Added frame_count for REV7 audio rendererGravatar David Marcec2019-09-201-0/+10
| | | | Added framecount
* Clang formatGravatar David Marcec2019-07-131-1/+2
|
* Addressed issuesGravatar David Marcec2019-07-131-1/+1
|
* "AudioRenderer" thread should have a unique nameGravatar David Marcec2019-07-131-2/+3
| | | | Creating multiple "AudioRenderer" threads cause the previous thread to be overwritten. The thread will name be renamed to AudioRenderer-InstanceX, where X is the current instance number.
* addressed issueGravatar David Marcec2019-07-081-1/+1
|
* audren: Only manage wave buffers with a sizeGravatar David Marcec2019-07-011-3/+5
| | | | | | We shouldn't be incrementing if wave buffers are empty. They are considered invalid/unused wave buffers. This fixes the issue of certain sounds looping when they shouldn't
* core_timing: Convert core timing into a classGravatar Lioncash2019-02-151-3/+4
| | | | | | | | | | | Gets rid of the largest set of mutable global state within the core. This also paves a way for eliminating usages of GetInstance() on the System class as a follow-up. Note that no behavioral changes have been made, and this simply extracts the functionality into a class. This also has the benefit of making dependencies on the core timing functionality explicit within the relevant interfaces.
* audio_core: Convert LOG_CRITICAL + UNREACHABLE over to ↵Gravatar Lioncash2018-12-281-4/+2
| | | | | | | | UNIMPLEMENTED/UNIMPLEMENTED_MSG These two macros being used in tandem were used prior to the introduction of UNIMPLEMENTED and UNIMPLEMENTED_MSG. This provides equivalent behavior, just with less typing/reading involved.
* Avoid (expensive) audio interpolation when sample rates already matchGravatar heapo2018-12-061-2/+5
|
* core: Port all current usages of Event to Readable/WritableEventGravatar Zach Hilman2018-11-291-2/+2
|
* Fixups for softlockGravatar David Marcec2018-10-071-5/+6
|
* Fixed missing returnGravatar David Marcec2018-10-071-1/+1
| | | | | Softlock explanation: after effects are initialized in smo, nothing actually changes the state. It expects the state to always be initialized. With the previous testing, updating the states much like how we handle the memory pools continue to have the softlock(which is why I said it probably wasn't effects) after further examination it seems like effects need to be initialized but the state remains unchanged until further notice. For now, assertions are added for the aux buffers to see if they update, unable to check as I haven't gotten smo to actually update them yet.
* Fixed smo softlockGravatar David Marcec2018-10-071-13/+71
|
* stream: Preserve enum class type in GetState()Gravatar Lioncash2018-09-231-1/+1
| | | | | | Preserves the meaning/type-safetiness of the stream state instead of making it an opaque u32. This makes it usable for other things outside of the service HLE context.
* Added audren:u#GetAudioRendererStateGravatar David Marcec2018-09-231-0/+4
|
* audio_renderer: Replace includes with forward declarations where applicableGravatar Lioncash2018-09-171-0/+40
| | | | | | | | | Avoids including unnecessary headers within the audio_renderer.h header, lessening the likelihood of needing to rebuild source files including this header if they ever change. Given std::vector allows forward declaring contained types, we can move VoiceState to the cpp file and hide the implementation entirely.
* Port #4182 from Citra: "Prefix all size_t with std::"Gravatar fearlessTobi2018-09-151-12/+12
|
* audio_renderer: Rename AudioOut instance to audio_outGravatar MerryMage2018-09-081-6/+6
|