Commit graph

37 commits

Author SHA1 Message Date
David Marcec
f17f347e03 Preliminary effects 2020-08-17 01:23:55 +10:00
David Marcec
5f24aa9e0f Fix stream channel count when outputting to stereo 2020-07-25 13:31:43 +10:00
David Marcec
4c85fba0db Queue extra mix buffer 2020-07-25 12:39:36 +10:00
David Marcec
81b2b4fbe9 audio_core: Apollo Part 1, AudioRenderer refactor 2020-07-25 12:39:34 +10:00
David Marcec
eea2cabf83 audren: Implement RendererInfo
Fixes ZLA softlock
2020-06-13 14:04:28 +10:00
David Marcec
9f8eb0c39a fix logic error & scale sample volume based on voice volume 2020-05-11 12:56:15 -04:00
David Marcec
7965018e64 pass by const ref instead 2020-05-11 12:56:15 -04:00
David Marcec
de00a5eb8c audio_renderer: Better voice mixing and 6 channel downmixing
Supersedes #3738 and #3321
2020-05-11 12:56:15 -04:00
David
c95dd42b72 audio_renderer: Preliminary BehaviorInfo (#3736)
* audio_renderer: Preliminary BehaviorInfo

* clang format

* Fixed IsRevisionSupported

* fixed IsValidRevision

* Fixed logic error & spelling errors & crash

* Addressed issues
2020-04-20 22:57:30 -04:00
bunnei
5b9e69e7fe core: memory: Move to Core::Memory namespace.
- helpful to disambiguate Kernel::Memory namespace.
2020-04-17 00:59:28 -04:00
Lioncash
cc3d6fdf73 core/memory: Migrate over Read{8, 16, 32, 64, Block} to the Memory class
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.
2019-11-26 21:55:39 -05:00
Lioncash
e04aeb9531 core: Prepare various classes for memory read/write migration
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.
2019-11-26 21:55:37 -05:00
bunnei
5cb0f276fe kernel: Replace usage of boost::intrusive_ptr with std::shared_ptr for 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.
2019-11-24 20:15:51 -05:00
David Marcec
b5e55f275b Used revision 5 instead of 7, marked constexpr as static 2019-09-21 16:24:56 +10:00
David Marcec
e4b4e60f49 Added frame_count for REV7 audio renderer
Added framecount
2019-09-20 10:42:09 +10:00
David Marcec
88565f46b6 Clang format 2019-07-13 01:49:32 +10:00
David Marcec
a5e5b9e9c7 Addressed issues 2019-07-13 01:35:40 +10:00
David Marcec
00c7dc08de "AudioRenderer" thread should have a unique name
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.
2019-07-13 01:22:08 +10:00
David Marcec
3b243f1b3e addressed issue 2019-07-08 14:49:16 +10:00
David Marcec
846440ab93 audren: Only manage wave buffers with a size
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
2019-07-01 21:20:23 +10:00
Lioncash
1c3371c921 core_timing: Convert core timing into a class
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.
2019-02-15 21:50:25 -05:00
Lioncash
f652c969a4 audio_core: Convert LOG_CRITICAL + UNREACHABLE over to 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.
2018-12-28 14:13:58 -05:00
heapo
4c83e5cd1e Avoid (expensive) audio interpolation when sample rates already match 2018-12-06 09:46:08 -08:00
Zach Hilman
fe0071f8fa core: Port all current usages of Event to Readable/WritableEvent 2018-11-29 08:45:41 -05:00
David Marcec
5f33966902 Fixups for softlock 2018-10-07 14:25:39 +11:00
David Marcec
a097860593 Fixed missing return
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.
2018-10-07 14:19:55 +11:00
David Marcec
f572064010 Fixed smo softlock 2018-10-07 14:14:09 +11:00
Lioncash
9254ec6fde stream: Preserve enum class type in GetState()
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.
2018-09-23 20:03:38 -04:00
David Marcec
5d1edf66c1 Added audren:u#GetAudioRendererState 2018-09-23 22:32:01 +10:00
Lioncash
01a14e4bdf audio_renderer: Replace includes with forward declarations where applicable
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.
2018-09-17 15:08:30 -04:00
fearlessTobi
1190ea6ddb Port #4182 from Citra: "Prefix all size_t with std::" 2018-09-15 15:21:06 +02:00
MerryMage
ed0dc20280 audio_renderer: Rename AudioOut instance to audio_out 2018-09-08 16:50:12 +01:00
MerryMage
26aa4ae7a8 audio_renderer: samples_remaining counts frames, not samples 2018-08-13 11:26:50 +01:00
MerryMage
0525998743 audio_core: Interpolate 2018-08-13 11:26:50 +01:00
David Marcec
7d49bcdb1b Pushed the requested sample rate instead of our fixed sample rate 2018-08-12 14:58:36 +10:00
David Marcec
f3ef58207e Added GetAudioRendererSampleRate, GetAudioRendererSampleCount & GetAudioRendererMixBufferCount
GetAudioRendererSampleRate is set as a "STUB" as a game could check if the sample rate it sent and the sample rate it wants don't match. Just a thought of something which could happen so keeping it as stub for the mean time
2018-08-12 14:46:12 +10:00
bunnei
5904aa20ce audio_core: Implement audren_u audio playback. 2018-08-04 21:54:30 -04:00