Commit Graph

630 Commits

Author SHA1 Message Date
Zephyron 65dfe3234f chore: revert Vulkan submodules to older versions for testing
Temporarily roll back the following submodules:
- VulkanMemoryAllocator: 2f382df → 539c0a8
- Vulkan-Headers: 80207f9 → e2e53a7
- Vulkan-Utility-Libraries: 524f891 → 4e246c5

This is for testing purposes only and should only be used for developers.

Signed-off-by: Zephyron <zephyron@citron-emu.org>
2025-04-28 16:33:43 +10:00
Zephyron 1ad69f3545 Update submodules: SDL, vcpkg, and Vulkan-Headers
- Update SDL to fix pipewire-related compile error
  - Removes need to hardcode -DSDL_PIPEWIRE=OFF in toolchain
- Update vcpkg to latest version
- Update Vulkan-Headers to latest version

Signed-off-by: Zephyron <zephyron@citron-emu.org>
2025-04-27 13:27:21 +10:00
Zephyron 0cdd546152 externals: Update Vulkan dependencies to latest versions
Update Vulkan-Headers, Vulkan-Utility-Libraries, VulkanMemoryAllocator, and vcpkg submodules to their latest versions to ensure compatibility with newer Vulkan features and improve rendering performance.

Signed-off-by: Zephyron <zephyron@citron-emu.org>
2025-04-19 13:26:01 +10:00
Zephyron 175a427c27 refactor(vulkan): remove depth buffer workarounds and excessive logging
- Remove special handling for reversed depth scenarios that were added for Civilization 7
- Remove excessive logging in Vulkan renderer
- Update Discord client ID
- Update Vulkan-related external dependencies

Signed-off-by: Zephyron <zephyron@citron-emu.org>
2025-04-14 22:02:29 +10:00
Zephyron 3a1c178711 Revert "nvn: Optimize shader performance by enhancing NVN bias settings"
This reverts commit 19febba866.
2025-04-12 15:12:19 +10:00
Zephyron 19febba866 nvn: Optimize shader performance by enhancing NVN bias settings
Improve GPU storage buffer detection and memory access patterns:
- Expand NVN bias address range (0x100-0x800 vs 0x110-0x610)
- Increase alignment from 16 to 32 bytes for optimal memory access
- Raise default alignment from 8 to 16 bytes for non-biased addresses
- Refactor bias handling code for better readability
- Add detailed performance-related comments

These changes help identify more storage buffers within shaders and
ensure memory accesses are better aligned, which improves overall
shader compilation and execution performance.

Update Vulkan dependencies to their latest versions.

Signed-off-by: Zephyron <zephyron@citron-emu.org>
2025-04-05 00:46:51 +10:00
Zephyron ebfc9d8347 memory: Implement enhanced memory management system
Add a flexible memory region management system that provides:
- Memory region type classification (System, Graphics, IO, Binary)
- Memory region permission management (executable, writable)
- Binary base address randomization for ASLR
- Dynamic memory mapping capabilities

Credit: boss.smc@citron-emu.org
Signed-off-by: Zephyron <zephyron@citron-emu.org>
2025-03-27 23:25:24 +10:00
Zephyron e06526cbbc Update Vulkan-related dependencies and vcpkg
- Update Vulkan-Headers from cacef303 to 78c35974
- Update VulkanMemoryAllocator from c788c521 to 29b35ea4
- Update vcpkg from e40d24cb to a7d06b3a

Signed-off-by: Zephyron <zephyron@citron-emu.org>
2025-03-21 17:23:02 +10:00
Zephyron 834cc89548 externals: Update Vulkan and vcpkg submodules
Update the following external dependencies:
- Vulkan-Headers: 0f0cfd8 → cacef303
- Vulkan-Utility-Libraries: 50563f4 → bc3a4d9f
- vcpkg: cd1099f4 → e40d24cb

This commit updates the external dependencies to their latest
compatible versions to ensure we're using up-to-date libraries.
2025-03-11 15:47:53 +10:00
Zephyron 6a31da5905 cmake: Add Profile-Guided Optimization (PGO) support
Adds support for Profile-Guided Optimization builds on both Windows (MSVC)
and Linux (GCC/Clang) platforms. This allows for performance optimizations
based on real usage patterns.

For MSVC:
- Adds /GL and /LTCG:PGINSTRUMENT flags for instrumentation
- Adds /GL and /LTCG:PGOPTIMIZE flags for optimization

For GCC:
- Adds -fprofile-generate flags for instrumentation
- Adds -fprofile-use flags for optimization

For Clang:
- Adds -fprofile-instr-generate flags for instrumentation
- Adds -fprofile-instr-use flags for optimization

Controlled by two new CMake options:
- CITRON_ENABLE_PGO_INSTRUMENT: Enable instrumentation build
- CITRON_ENABLE_PGO_OPTIMIZE: Enable optimization build

Updated submodules:
- Vulkan-Headers to 0f0cfd8
- Vulkan-Utility-Libraries to 50563f4
- vcpkg to cd1099f
2025-03-07 20:23:23 +10:00
Zephyron b1d5d4e5be Update external dependencies
- Update Vulkan-Utility-Libraries submodule to 5f41f2a
- Update vcpkg submodule to efb1e74
2025-03-03 16:33:01 +10:00
Zephyron 5a65f9a094 Update external dependencies
- Vulkan-Utility-Libraries: 6be00ca → 2d8f273
- FFmpeg: d161604 → 99e2af4
- vcpkg: 9a7a33f → 23b33f5
2025-02-27 13:08:19 +10:00
Zephyron a36baad0f0 externals: Update submodule versions
- vcpkg: 37d46ed → 9a7a33f
- Vulkan-Headers: 234c4b7 → 952f776
- Vulkan-Utility-Libraries: fe7a09b → 6be00ca
- ffmpeg: 9c1294e → d161604
2025-02-25 18:34:32 +10:00
Zephyron 18f8a0f997 Add license verification for Android app
Implements a LicenseVerifier class to ensure app integrity and license compliance:
- Verifies the app's package name matches the official release
- Validates app signature against official release signature
- Allows debug and EA (Early Access) builds
- Shows violation dialog and exits if verification fails
- Enforces GPLv3 license compliance for modified versions

This helps prevent unauthorized modified versions from being distributed
without source code, as required by the GPLv3 license.
2025-02-21 18:46:48 +10:00
Zephyron 6917530ba5 Updated submodule discord-rpc to commit 20cc99aeffa08a4834f156b6ab49ed68618cf94a 2025-02-19 15:19:47 +10:00
Zephyron 1aad9fd4e3 revert f45f339ef9
revert deps: update SDL2 and FFmpeg versions

Update bundled dependencies to their latest stable versions:
- SDL2: 2.28.2 -> 2.30.12
- FFmpeg: 6.0 -> 6.1.2

Also add citron copyright header to FFmpeg CMakeLists.txt
2025-02-13 11:48:41 +00:00
Zephyron f45f339ef9 deps: update SDL2 and FFmpeg versions
Update bundled dependencies to their latest stable versions:
- SDL2: 2.28.2 -> 2.30.12
- FFmpeg: 6.0 -> 6.1.2

Also add citron copyright header to FFmpeg CMakeLists.txt
2025-02-12 17:59:32 +10:00
Zephyron 298e797592 Update external dependencies
Updated the following submodules to their latest versions:
- vcpkg: 74ec888 → 33e9c99
- cpp-httplib: a609330 → 39a64fb
- cpp-jwt: 10ef573 → 4a970bc
- discord-rpc: 20cc99a → 2acd05a
- enet: 39a72ab → 657eaf9
- libusb: c060e9c → de38189
- oaknut: 9d09110 → 94c726c
- opus: 101a71e → 734aed0
- simpleini: 382ddbb → 6048871
2025-02-12 15:58:47 +10:00
Zephyron 7b6495aced
build: update dependencies and relax version requirements
- Update Vulkan validation layers to 1.4.304.1
- Update Qt to 6.8.2
- Remove strict version requirements for various dependencies
- Update Vulkan-Headers, VulkanMemoryAllocator, and vcpkg submodules
- Reorganize discord-rpc compile options

This change makes the build system more flexible by removing unnecessary
version constraints while ensuring compatibility with newer versions of
key dependencies.
2025-02-08 19:13:51 +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 e8bbdbce42
externals: Update Vulkan and related dependencies
Update the following external dependencies:
- Vulkan-Headers e43027a -> 39f924b
- Vulkan-Utility-Libraries 8ec8482 -> fe7a09b
- VulkanMemoryAllocator 7ab8483 -> 72c309a
- libadrenotools 5cd3f5c -> 8fae8ce
- vcpkg 2b8927f -> 2ded45c
2025-02-01 19:44:36 +10:00
Zephyron 33f8cd0c7e deps: Update Vulkan dependencies and remove fmt version constraint
- Update Vulkan-Headers to e43027a (1.4.306)
- Update Vulkan-Utility-Libraries to 8ec8482
- Update vcpkg to 2b8927f
- Remove version constraint for fmt package requirement
- Update VulkanHeaders version requirement to 1.4.306

This updates several external dependencies to their latest versions and
removes the specific version requirement for fmt while maintaining the
REQUIRED flag. The Vulkan-Headers version requirement is updated to match
the new submodule version.
2025-01-27 13:25:16 +10:00
Zephyron 450d80fc81 Remove SPIRV-Tools and SPIRV-Headers submodules temporarily
The SPIRV-Tools and SPIRV-Headers submodules are being temporarily removed
to fix their directory structure. They will be re-added in a follow-up
commit with the correct directory organization.
2025-01-18 17:04:33 +10:00
Zephyron b938893599 memory: Improve null pointer and unmapped memory handling
- Update vcpkg baseline to a42af01b72c28a8e1d7b48107b33e4f286a55ef6
- Add SPIRV-Tools and SPIRV-Headers as submodules
- Update Vulkan-related submodules to latest stable versions
- Improve memory access error handling:
  - Add specific handling for null pointer accesses in ARM32 emulation
  - Return 0 for null pointer reads instead of undefined behavior
  - Silently ignore writes to null pointers
  - Add more detailed error messages distinguishing between null pointer
    access and other unmapped memory errors
  - Treat addresses below 0x1000 as potential null pointer accesses

These changes should provide more graceful handling of null pointer
accesses and improve stability when running games that attempt invalid
memory operations.
2025-01-18 15:20:13 +10:00
Zephyron 132077e18f fix: Implement SetGestureOutputRanges to handle unimplemented function error
- Added the SetGestureOutputRanges function to the IHidServer class to address the unimplemented function '92' error.
- This fix was discovered through log analysis, which showed a critical assertion failure in the HID service for an unknown function '92'.
- The log indicated a userspace panic and backtrace, pointing to the need for implementing this function to prevent execution breaks.
- Updated CMakeLists.txt to remove specific version requirements for several packages, enhancing flexibility.
- Updated subproject commit references for VulkanMemoryAllocator and vcpkg.

- REF: https://switchbrew.org/wiki/HID_services#ActivateGesture
2025-01-15 19:20:37 +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 6d5475a9cf Android: Update build system and dependencies
- Update Gradle from 8.1 to 8.10.2
- Update Android Gradle Plugin from 8.1.2 to 8.8.0
- Update Kotlin from 1.9.20 to 2.1.20-Beta1
- Update various AndroidX dependencies to latest versions
- Update NDK from 26.1 to 27.2 (with RC1/RC2 options commented)
- Update Java target from 17 to 21
- Update Android target SDK from 34 to 35
- Enable additional optimizations in release builds:
  - Enable shrinkResources
  - Use proguard-android-optimize.txt
  - Disable JNI debugging
- Replace vector drawables with PNG for ic_citron
- Comment out unused ComputeInline constant in dma_pusher.cpp
- Update Gradle wrapper and configuration files

This updates the Android build system and dependencies to their latest
versions while enabling additional optimizations for release builds.
The ic_citron icon was converted from vector to PNG format for better
compatibility.
2025-01-13 15:17:39 +10:00
Zephyron 27d662ad0e
submodules(vcpkg): Update To Latest Commit 2025-01-03 14:38:39 +10:00
Zephyron 733d648b5a
vulkan: Update To 1.4.304 2025-01-02 16:39:09 +10:00
Zephyron 468ace6b0b
core: Update copyright headers
- Update copyright headers to include Citron Homebrew Project
- Add 2025 to copyright years
2024-12-31 17:36:08 +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
liamwhite 564a65a82e
Merge pull request #12981 from lat9nq/tzdb-asan-custom
tzdb_to_nx: Update to latest
2024-02-10 22:42:47 -05:00
lat9nq 68b2db21b1 tzdb_to_nx: Update to latest
Includes memory leak fix.

Includes option to specify a custom zoneinfo dir.
2024-02-10 17:45:18 -05:00
Merry 211544fbc8 externals: Update dynarmic to 6.6.3 2024-02-10 19:40:47 +00:00
Alexandre Bouvier 73e7a259fd cmake: prefer system oaknut library 2024-01-30 02:57:50 +01:00
liamwhite 51f5a6f1f8
Merge pull request #12830 from merryhime/dynamic-dual_code_block
externals/dynarmic: Update to 6.6.1
2024-01-29 15:27:04 -05: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
liamwhite 278dd589ec
Merge pull request #12439 from FireBurn/vkresult
Simplify VkResult lookup
2024-01-29 09:08:32 -05:00
Merry 6cc82fd430 externals/dynarmic: Update to 6.6.1 2024-01-28 17:04:01 +00:00
Merry 2bc0132d0c externals/oaknut: Update to 2.0.1 2024-01-28 16:50:14 +00:00
K900 3065ab0fd8 nx_tzdb: add another safety assertion 2024-01-27 17:28:04 +03:00
K900 a2407a2964 nx_tzdb: check for unpacked directory
Otherwise things get funny if the archive is downloaded, but the unpacking was interrupted.
2024-01-27 17:25:52 +03: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
Kelebek1 e4915fb7d2 Rework time service to fix time passing offline. 2024-01-24 04:26:55 +00:00
Mike Lothian f854ffd015 Add Vulkan-Utility-Libraries dependency 2024-01-22 01:30:44 +00:00
lat9nq d99830b59c externals: Update txdb_to_nx
Includes a fix lat9nq/tzdb_to_nx@1e82342 that fixes a build issue on Mac OS.
2024-01-09 17:29:38 -05:00
Liam 4f83b00f6f general: fix trailing whitespace 2024-01-08 09:34:32 -05:00
Jan Beich ecfba79d98 externals: update Vulkan-Headers to v1.3.274 2023-12-20 01:13:09 +01:00
FearlessTobi 46c259bb20 vcpkg: Update fmt to 10.1.1
Should fix compiling on the latest version of MSVC.
2023-12-12 19:27:20 +01:00
Alexandre Bouvier d2bb9e9729 cmake: prefer system gamemode library 2023-11-30 16:54:00 +01:00