summaryrefslogtreecommitdiff
path: root/src/audio_core (follow)
Commit message (Collapse)AuthorAgeFilesLines
* core/core_timing: Make callback parameters consistentGravatar Lioncash2019-03-241-1/+1
| | | | | | | | | | | In some cases, our callbacks were using s64 as a parameter, and in other cases, they were using an int, which is inconsistent. To make all callbacks consistent, we can just use an s64 as the type for late cycles, given it gets rid of the need to cast internally. While we're at it, also resolve some signed/unsigned conversions that were occurring related to the callback registration.
* audio_core/cubeb_sink: Convert _MSC_VER ifdefs to _WIN32Gravatar Lioncash2019-03-092-4/+4
| | | | This behavior also needs to be visible for MinGW builds as well.
* audio_core/cubeb_sink: Ensure COM is initialized on Windows prior to calling ↵Gravatar Lioncash2019-02-272-0/+19
| | | | | | | cubeb_init cubeb now requires that COM explicitly be initialized on the thread prior to calling cubeb_init.
* audio_core/audio_renderer: Name previously unknown parameters of ↵Gravatar Lioncash2019-02-271-6/+8
| | | | | | | | | | | AudioRendererParameter Provides names for previously unknown entries (aside from the two u8 that appear to be padding bytes, and a single word that also appears to be reserved or padding). This will be useful in subsequent changes when unstubbing behavior related to the audio renderer services.
* audio_core/cubeb_sink: Initialize CubebSinkStream's last_frame data memberGravatar Lioncash2019-02-251-1/+1
| | | | | Ensures that all member variables are initialized in a deterministic manner across the board.
* audio_core/cubeb_sink: Add override specifier to destructorGravatar Lioncash2019-02-251-1/+1
| | | | | CubebSinkStream inherits from a base class with a virtual destructor, so override can be appended to CubebSinkStream's destructor.
* audio_core/cubeb_sink: Resolve variable shadowing warnings in SamplesInQueueGravatar Lioncash2019-02-251-2/+2
| | | | | | The name of the parameter was shadowing the member variable of the same name. Instead, alter the name of the parameter to prevent said shadowing.
* audio_core/codec: Resolve truncation warnings within DecodeADPCMGravatar Lioncash2019-02-251-2/+2
| | | | | The assignments here were performing an implicit truncation from int to s16. Make it explicit that this is desired behavior.
* audio_core/buffer: Make const and non-const getter for samples consistentGravatar Lioncash2019-02-162-2/+2
| | | | This way proper const/non-const selection can occur.
* core_timing: Convert core timing into a classGravatar Lioncash2019-02-156-17/+28
| | | | | | | | | | | 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.
* core_timing: Rename CoreTiming namespace to Core::TimingGravatar Lioncash2019-02-122-14/+15
| | | | | | Places all of the timing-related functionality under the existing Core namespace to keep things consistent, rather than having the timing utilities sitting in its own completely separate namespace.
* dsp_interface: fix sound being played while volume is 0Gravatar fearlessTobi2019-01-261-1/+1
| | | | | According to documentation, if the argument of std::exp is zero, one is returned. However we want the return value to be also zero in this case so no audio is played.
* audio_core: remove unnecessary spaces on commentsGravatar Otávio Pace2019-01-141-2/+2
|
* audio_core: Convert LOG_CRITICAL + UNREACHABLE over to ↵Gravatar Lioncash2018-12-283-10/+6
| | | | | | | | 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.
* Merge pull request #1902 from lioncash/audioGravatar bunnei2018-12-146-32/+55
|\ | | | | audio_core: Make g_sink_details internally linked
| * audio_core: Make g_sink_details internally linkedGravatar Lioncash2018-12-136-32/+55
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We can hide the direct array from external view and instead provide functions to retrieve the necessary info. This has the benefit of completely hiding the makeup of the SinkDetails structure from the rest of the code. Given that this makes the array hidden, we can also make the array constexpr by altering the members slightly. This gets rid of several static constructor calls related to std::vector and std::function. Now we don't have heap allocations here that need to occur before the program can even enter main(). It also has the benefit of saving a little bit of heap space, but this doesn't matter too much, since the savings in that regard are pretty tiny.
* | Avoid (expensive) audio interpolation when sample rates already matchGravatar heapo2018-12-062-4/+8
|/
* core: Port all current usages of Event to Readable/WritableEventGravatar Zach Hilman2018-11-292-5/+6
|
* audio_core/audio_renderer: Fix typo in AuxInfo member nameGravatar Lioncash2018-11-131-1/+1
|
* microprofile: Drop ReleaseActiveBuffer scope.Gravatar Markus Wick2018-11-061-4/+0
| | | | | This was created with the unfinished resampling PR in mind. As the resampling is now on the audio thread, we don't need to care about this here any more.
* time_stretch: Switch to values of CitraGravatar fearlessTobi2018-10-291-3/+3
|
* cubeb_sink: ignore null-name device when selectingGravatar Weiyi Wang2018-10-271-1/+2
| | | | We already ignore them on listing devices. We should do the same when selecting devices. This fix a crash when opening a specific device while there is a null device in the list
* time_stretch: Remove unused m_channel_count member variableGravatar Lioncash2018-10-242-3/+1
| | | | This is only stored to, but never read from.
* EffectOutStatus padding is now in hexGravatar David Marcec2018-10-091-1/+1
|
* Fixups for softlockGravatar David Marcec2018-10-072-6/+7
|
* 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-072-13/+120
|
* stream: Preserve enum class type in GetState()Gravatar Lioncash2018-09-234-11/+11
| | | | | | 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-234-0/+13
|
* Logging: Change the TimeStretch::Process log from debug to trace level.Gravatar Subv2018-09-201-1/+1
| | | | This function is called too many times and makes the debug logging basically unusable due to the spam.
* time_stretch: Remove unused <array> includeGravatar Lioncash2018-09-171-1/+0
| | | | This isn't used within this header and isn't necessary.
* stream: Replace includes with forward declarations where applicableGravatar Lioncash2018-09-172-3/+7
| | | | | Avoids propagating includes in headers where it's not necessary to do so.
* audio_renderer: Replace includes with forward declarations where applicableGravatar Lioncash2018-09-172-39/+52
| | | | | | | | | 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.
* Merge pull request #1314 from lioncash/castGravatar bunnei2018-09-171-2/+2
|\ | | | | audio_core/time_stretch: Silence truncation warnings in Process()
| * audio_core/time_stretch: Silence truncation warnings in Process()Gravatar Lioncash2018-09-131-2/+2
| | | | | | | | The SoundTouch API only accepts uint amount of samples.
* | Merge pull request #1321 from lioncash/audio-shadowGravatar bunnei2018-09-171-4/+4
|\ \ | | | | | | cubeb_sink: Get rid of variable shadowing within CubebSink's constructor
| * | cubeb_sink: Get rid of variable shadowing within CubebSink's constructorGravatar Lioncash2018-09-141-4/+4
| |/ | | | | | | | | The parameter of the lambda was shadowing the variable that was being assigned to.
* | Merge pull request #1320 from lioncash/nameGravatar bunnei2018-09-171-1/+1
|\ \ | | | | | | cubeb_sink: Correct context name in ListCubebSinkDevices()
| * | cubeb_sink: Correct context name in ListCubebSinkDevices()Gravatar Lioncash2018-09-141-1/+1
| |/ | | | | | | This ain't Citra.
* / Port #4182 from Citra: "Prefix all size_t with std::"Gravatar fearlessTobi2018-09-1516-64/+67
|/
* Merge pull request #1298 from lioncash/viewGravatar bunnei2018-09-122-2/+4
|\ | | | | audio_core/sink_details: Change std::string parameter into std::string_view
| * audio_core/sink_details: Change std::string parameter into std::string_viewGravatar Lioncash2018-09-112-2/+4
| | | | | | | | | | The given string is only ever used for lookup and comparison, so we can just utilize a non-owning view to string data here
* | Merge pull request #1163 from FearlessTobi/add-audio-stretchingGravatar bunnei2018-09-127-49/+185
|\ \ | |/ |/| audio_core: Add audio stretching support
| * audio_core: Flush stream when not playing anythingGravatar MerryMage2018-09-126-0/+23
| |
| * cubeb_sink: Downsample arbitrary number of channelsGravatar MerryMage2018-09-091-10/+9
| |
| * cubeb_sink: Perform audio stretchingGravatar MerryMage2018-09-083-24/+26
| |
| * audio_core: Add audio stretcherGravatar MerryMage2018-09-083-0/+101
| |
| * cubeb_sink: Hold last available value instead of writing zerosGravatar MerryMage2018-09-081-5/+15
| | | | | | | | This reduces clicking in output audio should we underrun.
| * cubeb_sink: Use RingBufferGravatar MerryMage2018-09-081-40/+26
| |
| * Add audio stretching supportGravatar fearlessTobi2018-09-085-0/+15
| |