summaryrefslogtreecommitdiffstats
path: root/src/video_core/renderer_opengl/gl_device.cpp
diff options
context:
space:
mode:
authorReinUsesLisp <reinuseslisp@airmail.cc>2019-11-02 08:08:31 +0100
committerReinUsesLisp <reinuseslisp@airmail.cc>2019-11-02 09:05:34 +0100
commit76ca2a5f82f4df64cb839af42c93acb6705411ae (patch)
tree22ef46bef8f32d8b2aa2f3928a96b30b3f69e213 /src/video_core/renderer_opengl/gl_device.cpp
parentMerge pull request #3054 from FernandoS27/fix-tld4-2 (diff)
downloadyuzu-76ca2a5f82f4df64cb839af42c93acb6705411ae.tar
yuzu-76ca2a5f82f4df64cb839af42c93acb6705411ae.tar.gz
yuzu-76ca2a5f82f4df64cb839af42c93acb6705411ae.tar.bz2
yuzu-76ca2a5f82f4df64cb839af42c93acb6705411ae.tar.lz
yuzu-76ca2a5f82f4df64cb839af42c93acb6705411ae.tar.xz
yuzu-76ca2a5f82f4df64cb839af42c93acb6705411ae.tar.zst
yuzu-76ca2a5f82f4df64cb839af42c93acb6705411ae.zip
Diffstat (limited to 'src/video_core/renderer_opengl/gl_device.cpp')
-rw-r--r--src/video_core/renderer_opengl/gl_device.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/video_core/renderer_opengl/gl_device.cpp b/src/video_core/renderer_opengl/gl_device.cpp
index 64de7e425..c65b24c69 100644
--- a/src/video_core/renderer_opengl/gl_device.cpp
+++ b/src/video_core/renderer_opengl/gl_device.cpp
@@ -51,8 +51,11 @@ bool HasExtension(const std::vector<std::string_view>& images, std::string_view
} // Anonymous namespace
Device::Device() {
+ const std::string_view vendor = reinterpret_cast<const char*>(glGetString(GL_VENDOR));
const std::vector extensions = GetExtensions();
+ const bool is_nvidia = vendor == "NVIDIA Corporation";
+
uniform_buffer_alignment = GetInteger<std::size_t>(GL_UNIFORM_BUFFER_OFFSET_ALIGNMENT);
shader_storage_alignment = GetInteger<std::size_t>(GL_SHADER_STORAGE_BUFFER_OFFSET_ALIGNMENT);
max_vertex_attributes = GetInteger<u32>(GL_MAX_VERTEX_ATTRIBS);
@@ -64,6 +67,7 @@ Device::Device() {
has_variable_aoffi = TestVariableAoffi();
has_component_indexing_bug = TestComponentIndexingBug();
has_precise_bug = TestPreciseBug();
+ has_fast_buffer_sub_data = is_nvidia;
LOG_INFO(Render_OpenGL, "Renderer_VariableAOFFI: {}", has_variable_aoffi);
LOG_INFO(Render_OpenGL, "Renderer_ComponentIndexingBug: {}", has_component_indexing_bug);