From ea1066f76e459c6fa850e08babee3c40e56c281a Mon Sep 17 00:00:00 2001 From: Connor McLaughlin Date: Sun, 28 Jun 2020 21:44:45 +1000 Subject: [PATCH] GL/StreamBuffer: Use glBufferData() on all drivers --- src/common/gl/stream_buffer.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/common/gl/stream_buffer.cpp b/src/common/gl/stream_buffer.cpp index 09c2d81ea..6de7702fe 100644 --- a/src/common/gl/stream_buffer.cpp +++ b/src/common/gl/stream_buffer.cpp @@ -286,6 +286,8 @@ std::unique_ptr StreamBuffer::Create(GLenum target, u32 size) return buf; } + // BufferSubData is slower on all drivers except NVIDIA... +#if 0 const char* vendor = reinterpret_cast(glGetString(GL_VENDOR)); if (std::strcmp(vendor, "ARM") == 0 || std::strcmp(vendor, "Qualcomm") == 0) { @@ -294,6 +296,9 @@ std::unique_ptr StreamBuffer::Create(GLenum target, u32 size) } return detail::BufferSubDataStreamBuffer::Create(target, size); +#else + return detail::BufferDataStreamBuffer::Create(target, size); +#endif } } // namespace GL \ No newline at end of file