aboutsummaryrefslogtreecommitdiff
path: root/src/video_core
AgeCommit message (Collapse)Author
2021-05-17Merge pull request #6322 from ameerj/fast-null-bufferbunnei
buffer_cache: Ensure null buffers cannot take the fast uniform bind path
2021-05-16buffer_cache: Ensure null buffers cannot take the fast uniform bind pathameerj
Fixes a crash in New Pokemon Snap
2021-05-15Merge pull request #6289 from ameerj/oob-blitbunnei
texture_cache: Handle out of bound texture blits
2021-05-07texture_cache: Handle out of bound texture blitsameerj
Some games interleave a texture blit using regions which are out-of-bounds. This addresses the interleaving to avoid oob reads from the src texture.
2021-05-05hle: kernel: Rename Process to KProcess.bunnei
2021-04-25Merge pull request #6237 from ameerj/nvdec-end-fixbunnei
nvhost_vic: Fix device closure
2021-04-24vk_texture_cache: Swap R and B channels of color flipped formatameerj
Swaps the Red and Blue channels of the A1B5G5R5_UNORM texture format, which was being incorrectly rendered.
2021-04-24nvhost_vic: Fix device closureameerj
Implements the OnClose method of the nvhost_vic device, and removes the remnants of an older implementation. Also cleans up some of the surrounding code.
2021-04-19texture_cache/util: Fix src being used instead of dst within DeduceBlitImagesLioncash
This line can only ever be reached if src is null, so dereferencing it here is a logic bug that slipped through. Instead, we dereference dst instead which is guaranteed to be valid.
2021-04-16Merge pull request #6125 from ogniK5377/nvdec-close-devbunnei
nvdrv: Cleanup CDMA Processor on device closure
2021-04-16Address issuesChloe Marcec
2021-04-14Merge pull request #6196 from bunnei/asserts-settingbunnei
core: settings: Add setting for debug assertions and disable by default.
2021-04-14common: Move settings to common from core.bunnei
- Removes a dependency on core and input_common from common.
2021-04-13Merge pull request #6191 from lioncash/vdtorbunnei
engine_interface: Add missing virtual destructor
2021-04-13Merge pull request #6190 from lioncash/constfn2bunnei
vk_master_semaphore: Add missing const qualifier for IsFree()
2021-04-13Merge pull request #6188 from lioncash/bitsbunnei
vk_texture_cache: Make use of bit_cast where applicable
2021-04-13Merge pull request #6187 from lioncash/sign-convbunnei
texure_cache/util: Resolve implicit sign conversions with std::reduce
2021-04-12engine_interface: Add missing virtual destructorLioncash
Eliminates a potential bug vector related to inheritance. Plus, we should generally be specifying the destructor as virtual within purely virtual interfaces to begin with.
2021-04-12vk_master_semaphore: Deduplicate atomic access within IsFree()Lioncash
We can just reuse the already existing KnownGpuTick() to deduplicate the access.
2021-04-12vk_master_semaphore: Add missing const qualifier for IsFree()Lioncash
This member function doesn't modify class state.
2021-04-12vk_texture_cache: Make use of Common::BitCast where applicableLioncash
Also clarify the TODO comment a little more on the lacking implementations for std::bit_cast.
2021-04-12texure_cache/util: Resolve implicit sign conversions with std::reduceLioncash
Amends implicit sign conversions occurring with usages of std::reduce and also relocates it to its own utility function to reduce verbosity a little bit.
2021-04-12query_cache: Make use of std::erase_ifLioncash
Same behavior, but much more straightforward to read.
2021-04-11Merge pull request #6181 from Joshua-Ashton/robustness_featuresRodrigo Locatti
vulkan_device: Enable EXT_robustness2 features
2021-04-11vk_buffer_cache: Fix offset for NULL vertex buffersJoshua Ashton
The Vulkan spec states: If an element of pBuffers is VK_NULL_HANDLE, then the corresponding element of pOffsets must be zero. https://www.khronos.org/registry/vulkan/specs/1.2-extensions/man/html/vkCmdBindVertexBuffers2EXT.html#VUID-vkCmdBindVertexBuffers2EXT-pBuffers-04112
2021-04-11vulkan_device: Enable EXT_robustness2 featuresJoshua Ashton
When this was being made mandatory, these enablement of these features was removed, but this is still needed. Fixes: 757fd1e91716 ("vulkan_device: Require VK_EXT_robustness2")
2021-04-11renderer_vulkan: Check return value of AcquireNextImageJoshua Ashton
We can get into a really bad state by ignoring this leading to device loss and using incorrect resources.
2021-04-07video_core: Use a CV for blocking commands.Markus Wick
There is no need for a busy loop here. Let's just use a condition variable to save some power.
2021-04-07video_core/gpu_thread: Keep the write lock for allocating the fence.Markus Wick
Else the fence might get submited out-of-order into the queue, which makes testing them pointless. Overhead should be tiny as the mutex is just moved from the queue to the writing code.
2021-04-07video_core/gpu_thread: Implement a ShutDown method.Markus Wick
This was implicitly done by `is_powered_on = false`, however the explicit method allows us to block until the GPU is actually gone. This should fix a race condition while removing the other subsystems while the GPU is still active.
2021-04-07common/threadsafe_queue: Provide Wait() method.Markus Wick
It shall block until there is something to consume in the queue. And use it for the GPU emulation instead of the spin loop. This is only in booting the emulator, however in BOTW this is the case for about 1 second.
2021-04-05vp9: Avoid memcpy with null pointerslat9nq
Avoid sending null pointer to memcpy as reported by Undefined Behaviour Sanitizer. Replaces the std::memcpy calls in SpliceVectors with std::copy calls. Opting to replace all the memcpy's with copy's. Co-authored-by: LC <mathew1800@gmail.com>
2021-03-30Merge pull request #5927 from ameerj/astc-computeRodrigo Locatti
video_core: Accelerate ASTC texture decoding using compute shaders
2021-03-30nvdrv: Cleanup CDMA Processor on device closureChloe Marcec
Brings us a step closer to unifying all channels to share a common interface.
2021-03-30vulkan_common: enable OpenGL interop on other UnicesJan Beich
2021-03-25astc_decoder: Refactor for style and more efficient memory useameerj
2021-03-24gl_device: unblock async shaders on other Unix systemsJan Beich
Mesa is the primary OpenGL provider on all FreeDesktop systems. For example, iris is used on Intel GPU + FreeBSD by default.
2021-03-21gl_device: Block async shaders on AMD and Intellat9nq
Currently, the Windows versions of the Intel OpenGL driver and the AMD proprietary OpenGL driver do not properly support (or in fact degrade) when asynchronous shader compilation is enabled. This blocks specifically those drivers from using this feature. This affects AMDGPU-PRO on Linux, and AMD's and Intel's OpenGL drivers on Windows.
2021-03-13astc_decoder: Reimplement LayersRodrigo Locatti
Reimplements the approach to decoding layers in the compute shader. Fixes multilayer astc decoding when using Vulkan.
2021-03-13astc_decoder: Fix out of bounds memory accessameerj
resolves a crash with some anamolous textures found in Astral Chain.
2021-03-13renderer_vulkan: Accelerate ASTC decodingameerj
Co-Authored-By: Rodrigo Locatti <reinuseslisp@airmail.cc>
2021-03-13host_shaders: Modify shader cmake integration to allow for larger shadersameerj
using a raw string to encapsulate the entire shader code limits us to shaders of size less than 2KB. This change overcomes this limitation.
2021-03-13renderer_opengl: Accelerate ASTC texture decoding with a compute shaderameerj
ASTC texture decoding is currently handled by a CPU decoder for GPU's without native ASTC decoding support (most desktop GPUs). This is the cause for noticeable performance degradation in titles which use the format extensively. This commit adds support to accelerate ASTC decoding using a compute shader on OpenGL for GPUs without native support.
2021-03-12Merge pull request #6028 from bunnei/raster-cachebunnei
video_core: rasterizer_accelerated: Use a flat array instead of interval_map for cached pages.
2021-03-12video_core: rasterizer_accelerated: Fix un/signed mismatch.bunnei
2021-03-09Merge pull request #5891 from ameerj/bgra-oglRodrigo Locatti
renderer_opengl: Use compute shaders to swizzle BGR textures on copy
2021-03-08Merge pull request #6021 from ReinUsesLisp/skip-cache-heuristicbunnei
buffer_cache: Heuristically decide to skip cache on uniform buffers
2021-03-04texture_cache: Blacklist BGRA8 copies and views on OpenGLameerj
In order to force the BGRA8 conversion on Nvidia using OpenGL, we need to forbid texture copies and views with other formats. This commit also adds a boolean relating to this, as this needs to be done only for the OpenGL api, Vulkan must remain unchanged.
2021-03-04renderer_opengl: Swizzle BGR textures on copyameerj
OpenGL does not natively support BGR internal formats, which causes many BGR textures to render incorrectly, with Red and Blue channels swapped. This commit aims to address this by swizzling the blue and red channels on texture copies when a BGR format is encountered.
2021-03-04Merge pull request #5989 from ReinUsesLisp/cmdpoolbunnei
vk_command_pool: Reduce the command pool size from 4096 to 4