Commit graph

413 commits

Author SHA1 Message Date
Zephyron
4d50d2ba16 Revert "audio: refactor SDL2 sink implementation"
This reverts commit 3aa9c0d151.
2025-02-20 16:54:43 +10:00
Zephyron
3aa9c0d151
audio: refactor SDL2 sink implementation
- Move SDLSinkStream class definition to header file
- Add additional error checking for SDL audio device availability
- Limit audio channels to stereo
- Add format verification and warning messages
- Improve audio device initialization with better error handling
- Rename device variable to audio_device_id for clarity
- Add running state flag
- Update copyright header to include citron

This refactoring improves error handling and provides better debug
information when audio device initialization fails. The implementation
is now more robust and provides clearer feedback for troubleshooting
audio issues.
2025-02-08 19:19:52 +10:00
Zephyron
4cc01f6c71
audio_core/renderer: Add compressor and splitter support for Rev13
Implement new audio features available in AudioRenderer Revision 13:

- Add AudioRendererRevision enum to track version-specific features
- Implement CompressorEffect with statistics tracking support
- Add SplitterDestination with previous volume reset functionality
- Add version checks for feature compatibility

The compressor provides dynamic range compression with configurable
parameters and optional statistics tracking. The splitter improvements
allow for more flexible volume management between audio transitions.

These changes maintain compatibility with older revisions while enabling
new features in Rev13.
2025-02-04 16:32:59 +10:00
Zephyron
9ae0eeeb87 Revert incorrect copyright attribution for non-contributed files
- In commit b3facaa6bb, the copyright header was
  updated to include "Citron Homebrew Project" across multiple files, regardless
  of whether any contributions were made.

- This commit removes the incorrect attribution and reverts the copyright header
  to its previous state.

- Copyright attribution should only be added when meaningful contributions have
  been made to the file.

- This commit ensures proper compliance with copyright standards and maintains
  correct attribution to the respective contributors.

- Special thanks to Tachi for pointing out the need for these corrections and
  ensuring that proper attribution practices are followed.
2025-01-14 15:33:24 +10:00
Zephyron
b685d5701d
Audio Core: Add support tags for compressor stats and volume reset
Added two new audio feature support tags with their corresponding revision
numbers:
- AudioCompressorStatistics (rev 16): For tracking compressor statistics
- AudioVolumeResetSupport (rev 17): For volume reset functionality

These features align with the documented Nintendo Switch audio service
capabilities and maintain compatibility with the existing feature support
system.
2025-01-03 13:34:14 +10:00
Zephyron
a9f539e193
audio_core: Add comprehensive audio feature support tags
Added new feature support tags to track audio functionality across firmware
versions. Changes include:

- Added Audio Out/In Auto buffer support tags (3.0.0+)
- Added Final Output Recorder features including work buffer (3.0.0+, 9.0.0+)
- Added Audio Renderer features like manual execution and voice drop
- Added Audio Device features including notifications and auto volume
- Added Hardware Opus decoder features including large frame support
- Added System Audio features like master volume and hearing protection

This provides more complete feature detection for audio functionality
introduced in firmware versions 3.0.0 through 19.0.1.
2024-12-31 18:42:49 +10:00
Zephyron
b3facaa6bb
chore: update project references and add Citron copyright
- Replaced all references to the old project name with Citron.
- Added Citron copyright information alongside existing notices in all files.
2024-12-31 17:07:49 +10:00
Liam
964e19ab56 oboe_sink: handle temporary stream creation failure 2024-02-23 10:30:52 -05:00
Liam
2c00599a53 audio: fix released buffer bounds check 2024-02-22 20:20:31 -05:00
Liam
2e4a6b7f92 audio: format 2024-02-20 22:51:39 -05:00
Liam
c575a85233 audio: rewrite IAudioDevice 2024-02-20 22:15:38 -05:00
Liam
ea4703cb31 audio: rewrite IHardwareOpusDecoderManager 2024-02-20 22:15:38 -05:00
Liam
6012c9fe3a audio: rewrite IAudioRendererManager 2024-02-20 22:15:37 -05:00
Liam
a05bd3c47e audio: rewrite IAudioOut 2024-02-20 22:15:37 -05:00
Liam
2a2c92f181 audio: rewrite IAudioInManager 2024-02-20 22:15:37 -05:00
FearlessTobi
310c1f50be scope_exit: Make constexpr
Allows the use of the macro in constexpr-contexts.
Also avoids some potential problems when nesting braces inside it.
2024-02-19 16:00:46 +01:00
liamwhite
90cb852908
Merge pull request #12814 from Kelebek1/time_new_ipc
Move time services to new IPC and add debug printing
2024-01-29 09:08:46 -05:00
Kelebek1
19a2f12692 Use the input process handle to get the correct application's memory 2024-01-28 18:51:43 +00:00
Kelebek1
da410506a4 Move time services to new IPC.
Add some fixes/improvements to usage with the new IPC
2024-01-27 03:30:09 +00:00
Fernando Sahmkow
590d9b7e1d Core: Clang format and other small issues. 2024-01-18 21:12:30 -05:00
Fernando Sahmkow
0a2536a0df SMMU: Initial adaptation to video_core. 2024-01-18 21:12:30 -05:00
Viktor Szépe
90ab89a0b0 Merge remote-tracking branch 'origin/master' into typos3 2024-01-16 00:09:00 +00:00
Viktor Szépe
2044ae6b3a Fix more typos 2024-01-15 23:26:53 +00:00
Liam
d940974789 audio: fetch process object from handle table 2024-01-12 10:03:16 -05:00
Liam
f34d3d7e84 core_timing: remove user data value 2023-12-23 15:36:44 -05:00
Fernando S
d61df0f400
Merge pull request #12387 from liamwhite/oboe
android: add oboe audio sink
2023-12-19 16:15:07 +01:00
Liam
a7731abb72 oboe_sink: specify additional required parameters 2023-12-18 17:27:32 -05:00
Liam
797e8fdbc3 oboe_sink: set low latency performance mode 2023-12-17 21:05:00 -05:00
Liam
e01c535178 oboe_sink: implement channel count querying 2023-12-17 10:10:14 -05:00
Liam
7239547ead android: add oboe audio sink 2023-12-17 01:42:59 -05:00
Liam
6851e93296 audio: skip coefficient normalization for downmix 2023-12-16 13:05:55 -05:00
Kelebek1
ffbba74c91 Have GetActiveChannelCount return the system channels instead of host device channels 2023-12-16 12:49:28 -05:00
Liam
de594995da opus: fix stereo stream count check in multistream decoder object 2023-11-17 08:26:22 -05:00
Liam
ecaa038b4d audio_core: ignore renderer wait when stream is paused 2023-11-12 23:10:53 -05:00
Kelebek1
90aa937593 Convert files to LF eol 2023-11-04 18:25:40 +00:00
Kelebek1
a294beb116 Allow 0 stereo count 2023-11-03 11:45:40 -04:00
Liam
68ea0a2b72 audio: fix shutdown deadlock in audio renderer 2023-10-13 16:34:31 -04:00
Kelebek1
ec6ddaf766 Clear DSP buffer after each execution 2023-10-10 18:22:08 +01:00
Liam
0448eb6f0f ci: fix new codespell errors 2023-10-02 18:03:05 -04:00
liamwhite
d6cf54dd2f
Merge pull request #11520 from Kelebek1/estimated_time
Do not consider voice commands in time estimation, fix adpcm estimate
2023-09-18 09:30:56 -04:00
Kelebek1
5d7571114e Do not consider voice commands in time estimation, fix adpcm estimate 2023-09-18 10:38:14 +01:00
Kelebek1
67e2d5c28b Reimplement HardwareOpus 2023-09-16 11:56:25 -04:00
liamwhite
3df56dc790
Merge pull request #11465 from Kelebek1/skip_remaining_reset
[Audio] Do not reset the remaining command count each time
2023-09-10 13:40:32 -04:00
Kelebek1
800d6f7d0d Fix data source version 1 command looping 2023-09-08 15:03:21 +01:00
Kelebek1
4baaaf6a99 Do not reset the command buffer command count each time 2023-09-07 20:53:48 +01:00
liamwhite
69949e7964
Merge pull request #11428 from Kelebek1/adsp_rework
Rework ADSP into a wrapper for apps
2023-09-06 09:13:06 -04:00
Kelebek1
ebd19dec99 Rework ADSP into a wrapper for apps 2023-09-04 17:12:16 +01:00
Danila Malyutin
785e480b62 msvc: set warning level to /W4 globally
And fix a bunch of warnings
2023-09-03 18:42:10 +04:00
liamwhite
52c71e7eb6
Merge pull request #11408 from Kelebek1/fix_audio_node_id
[Audio] Fix node id index in DropVoices
2023-08-29 09:27:40 -04:00
Kelebek1
1d201c71dc Fix node id index in DropVoices 2023-08-28 10:35:30 +01:00