summaryrefslogtreecommitdiffstats
path: root/src/video_core
diff options
context:
space:
mode:
authorReinUsesLisp <reinuseslisp@airmail.cc>2021-06-02 08:02:33 +0200
committerameerj <52414509+ameerj@users.noreply.github.com>2021-07-23 03:51:34 +0200
commit79f2fe1a39120f498e915fa0c740b15dc0f09793 (patch)
treeee1fb2edc8193295930abbf1ad157bdaf4a682d5 /src/video_core
parentbuffer_cache: Reduce uniform buffer size from shader usage (diff)
downloadyuzu-79f2fe1a39120f498e915fa0c740b15dc0f09793.tar
yuzu-79f2fe1a39120f498e915fa0c740b15dc0f09793.tar.gz
yuzu-79f2fe1a39120f498e915fa0c740b15dc0f09793.tar.bz2
yuzu-79f2fe1a39120f498e915fa0c740b15dc0f09793.tar.lz
yuzu-79f2fe1a39120f498e915fa0c740b15dc0f09793.tar.xz
yuzu-79f2fe1a39120f498e915fa0c740b15dc0f09793.tar.zst
yuzu-79f2fe1a39120f498e915fa0c740b15dc0f09793.zip
Diffstat (limited to 'src/video_core')
-rw-r--r--src/video_core/renderer_opengl/gl_device.cpp1
-rw-r--r--src/video_core/renderer_opengl/gl_device.h5
-rw-r--r--src/video_core/renderer_opengl/gl_shader_cache.cpp1
3 files changed, 7 insertions, 0 deletions
diff --git a/src/video_core/renderer_opengl/gl_device.cpp b/src/video_core/renderer_opengl/gl_device.cpp
index 01da2bb57..3f7929f9e 100644
--- a/src/video_core/renderer_opengl/gl_device.cpp
+++ b/src/video_core/renderer_opengl/gl_device.cpp
@@ -154,6 +154,7 @@ Device::Device() {
has_precise_bug = TestPreciseBug();
has_broken_texture_view_formats = is_amd || (!is_linux && is_intel);
has_nv_viewport_array2 = GLAD_GL_NV_viewport_array2;
+ has_derivative_control = GLAD_GL_ARB_derivative_control;
has_vertex_buffer_unified_memory = GLAD_GL_NV_vertex_buffer_unified_memory;
has_debugging_tool_attached = IsDebugToolAttached(extensions);
has_depth_buffer_float = HasExtension(extensions, "GL_NV_depth_buffer_float");
diff --git a/src/video_core/renderer_opengl/gl_device.h b/src/video_core/renderer_opengl/gl_device.h
index d67f5693c..1ffd24883 100644
--- a/src/video_core/renderer_opengl/gl_device.h
+++ b/src/video_core/renderer_opengl/gl_device.h
@@ -96,6 +96,10 @@ public:
return has_nv_viewport_array2;
}
+ bool HasDerivativeControl() const {
+ return has_derivative_control;
+ }
+
bool HasDebuggingToolAttached() const {
return has_debugging_tool_attached;
}
@@ -141,6 +145,7 @@ private:
bool has_broken_texture_view_formats{};
bool has_fast_buffer_sub_data{};
bool has_nv_viewport_array2{};
+ bool has_derivative_control{};
bool has_debugging_tool_attached{};
bool use_assembly_shaders{};
bool use_asynchronous_shaders{};
diff --git a/src/video_core/renderer_opengl/gl_shader_cache.cpp b/src/video_core/renderer_opengl/gl_shader_cache.cpp
index 6ea7c0ee8..bdffac4b2 100644
--- a/src/video_core/renderer_opengl/gl_shader_cache.cpp
+++ b/src/video_core/renderer_opengl/gl_shader_cache.cpp
@@ -274,6 +274,7 @@ ShaderCache::ShaderCache(RasterizerOpenGL& rasterizer_, Core::Frontend::EmuWindo
.support_typeless_image_loads = device.HasImageLoadFormatted(),
.support_demote_to_helper_invocation = false,
.support_int64_atomics = false,
+ .support_derivative_control = device.HasDerivativeControl(),
.warp_size_potentially_larger_than_guest = true,