Commit Graph

2071 Commits

Author SHA1 Message Date
Lioncash d7834bd6b4 D3D12: Migrate logging over to fmt
Migrates the logging over to the fmt-capable logger.
2020-11-09 02:59:51 -05:00
JosJuice 28aa04312c Common/LinearDiskCache: Replace std::fstream with File::IOFile
File::IOFile is better suited to this type of task.
Split out from a future PR.
2020-11-05 00:31:17 +01:00
Jordan Woyak d2f80a4595
Merge pull request #9138 from martymac/VK_NULL_HANDLE-fix
Fix build on FreeBSD i386 - nullptr vs VK_NULL_HANDLE
2020-11-03 08:28:11 -06:00
Ganael Laplanche d456e2e391 Resolve VkDeviceMemory/nullptr type mismatch to fix build on FreeBSD i386 2020-11-03 07:47:43 +01:00
JMC47 6a3a71cfd7
Merge pull request #9141 from Techjar/but-for-how-long
Re-enable GPU Texture Decoding under MoltenVK
2020-10-29 01:22:13 -04:00
mazes-80 f375ee72a2
CMake: Add option to enable/disable Vulkan video backend 2020-10-23 20:14:46 +02:00
Techjar 0c01712d13 DriverDetails: Remove bug for broken GPU Texture Decoding 2020-10-08 10:13:40 -04:00
Stenzek 24bb947eff Vulkan: Use VK_LAYER_KHRONOS_validation for validation
VK_LAYER_LUNARG_standard_validation is deprecated.
2020-10-01 17:21:46 +10:00
Techjar 69358b2186 VideoBackends: Disable GPU Texture Decoding under MoltenVK
It's broken and causes spectacular artifacts and crashes.
2020-09-07 17:28:05 -04:00
JosJuice 6eefc3c524 Make default graphics backend not show up as empty
Fixes https://bugs.dolphin-emu.org/issues/12245.

I considered making a change to DolphinQt instead of
the core, but then additional effort would've been
required to add the same fix to the Android GUI once
we start using the new config system there.
2020-09-06 12:56:45 +02:00
Shawn Hoffman 969ea6e4f5 msvc: enable /Zc:preprocessor and make build compile cleanly 2020-08-27 21:58:48 -07:00
Shawn Hoffman 4db06bf85b ogl: init ProgramShaderCache::s_ubo_align to 1.
silences a warning that it may cause div-by-zero.
2020-08-27 15:15:52 -07:00
Shawn Hoffman 938fd4e438 use constexpr for some compile-time expressions 2020-08-23 13:57:05 -07:00
Shawn Hoffman 6ef9d70701 name some threads 2020-08-22 17:22:07 -07:00
LC 4a34b74e68
Merge pull request #9035 from shuffle2/vs-pretty
misc vcxproj cleanup
2020-08-22 20:13:25 -04:00
Shawn Hoffman cff4806d8d windows: fix build if pch were to be disabled 2020-08-22 16:18:24 -07:00
Shawn Hoffman 2f47f486af msbuild: re-enable standalone vcxproj processing 2020-08-22 16:17:50 -07:00
Shawn Hoffman 94bf48b67c msbuild: refactor stuff out of project files (for dolphin) 2020-08-22 16:17:50 -07:00
Shawn Hoffman 3a0d8c0208 msbuild: enable D3DCommon to use pch 2020-08-22 16:17:50 -07:00
Shawn Hoffman 36ace8eb52 prettify some constructs in vcxproj files 2020-08-22 16:17:50 -07:00
LC 487cd7abd9
Merge pull request #8905 from JosJuice/jni-encoding
Android: Use correct encoding when converting strings
2020-07-18 22:13:14 -04:00
Filip Gawin 0ede5d1537 Use range loop (if possible) 2020-07-18 18:29:16 -05:00
JosJuice 15d9fab0bb Common: Rename UTF16ToUTF8
This function does *not* always convert from UTF-16. It converts
from UTF-16 on Windows and UTF-32 on other operating systems.

Also renaming UTF8ToUTF16 for consistency, even though it
technically doesn't have the same problem since it only was
implemented on Windows.
2020-07-08 14:51:35 +02:00
JosJuice 6f298378a1 Reword "Please avoid forcing Dolphin to use MSAA by the driver" message
Some users who get this error don't seem to gain much understanding
of how to resolve the problem from reading the error message.
2020-07-08 11:34:36 +02:00
orbea ba2d04b793 Externals: Fix build failures with the newer glslang.
v2: Don't include glslang project wide.
2020-05-30 18:54:21 -07:00
Lioncash 86f8768268 VideoCommon/ShaderGenCommon: Make template functions regular functions
These are only ever used with ShaderCode instances and nothing else.
Given that, we can convert these helper functions to expect that type of
object as an argument and remove the need for templates, improving
compiler throughput a marginal amount, as the template instantiation
process doesn't need to be performed.

We can also move the definitions of these functions into the cpp file,
which allows us to remove a few inclusions from the ShaderGenCommon
header. This uncovered a few instances of indirect inclusions being
relied upon in other source files.

One other benefit is this allows changes to be made to the definitions
of the functions without needing to recompile all translation units that
make use of these functions, making change testing a little quicker.

Moving the definitions into the cpp file also allows us to completely
hide DefineOutputMember() from external view, given it's only ever used
inside of GenerateVSOutputMembers().
2020-05-25 21:12:29 -04:00
Stenzek bf74553878 FramebufferManager: Copy to color format for depth readbacks on GLES
glReadPixels() with depth formats is not supported.

Should fix broken EFB access on GLES.
2020-05-24 16:11:11 +10:00
degasus fc0df37d94 Fix windows build system. 2020-04-29 12:56:52 +02:00
Léo Lam 0fe4985f8d
Merge pull request #8689 from howard0su/cleanup_sign
Remove warnings of -Wsign-compare
2020-04-28 13:36:21 +02:00
Léo Lam 9d44af4c31
Merge pull request #8696 from howard0su/cleanup_shadow
Cleanup warnings of -Wmissing-declarations
2020-04-27 15:33:01 +02:00
Stenzek a2f4fafe86 Vulkan: Switch from vkCreateMacOSSurfaceMVK() to vkCreateMetalSurfaceEXT()
Since we are calling this off the UI thread, we can't use anything which
accesses the underlying NSView object. We create and set the Metal layer
on the UI thread before the video backend is initialized. This extension
is both compatible with MoltenVK and gfx-portability for accepting a
layer at surface creation.
2020-04-07 18:56:55 +10:00
Jun Su 81f8099cc6 Remove warnings of -Wsign-compare
Cast the variable to the coresponding type.
2020-03-25 07:57:14 +08:00
Jun Su b6ff15c130 Cleanup warnings of -Wmissing-declarations
Add static to the functions which is not intentionally
export to big scope.
2020-03-24 20:16:10 +08:00
Stenzek fb947296b0 Vulkan: Pass CAMetalLayer to MoltenVK instead of NSView
Gets rid of the warning for calling [NSView layer] off the main thread.
2020-03-11 23:11:26 +10:00
Stenzek a545344268 VideoBackends: Make it possible for PrepareWindow to change the surface
Again, needed for MoltenVK.
2020-03-11 23:10:30 +10:00
Stenzek 08cc73108a Vulkan: Treat VK_SUBOPTIMAL_KHR as VK_SUCCESS on Android
Android 10 seems to expect a prerotated/transformed swap chain for optimal
presentation. For now, until we implement that, just ignore the hint.
2020-01-31 19:16:06 +10:00
Stenzek ead65b0d8c Vulkan: Log when a swap chain resize is occurring
This may help us debug performance problems in the future.
2020-01-31 19:11:43 +10:00
Ryan Meredith e5f6d9320f Add Dolphin version and current video backend to shader compilation logs 2020-01-24 03:29:38 -05:00
David Korth f5fe692842 Use pre-increment for iterators instead of post-increment.
Pre-increment is more efficient, since it doesn't have to return the
old iterator.
2019-12-29 23:45:02 -05:00
David Korth 05101b251c OGL/Render.cpp, InitDriverInfo(): Use std::string_view to eliminate string copies.
Consolidate the NVIDIA Tegra and non-Tegra checks into one branch.
2019-12-29 23:45:02 -05:00
Stenzek 6fcb1c6c46 Add an ARM64 target to Visual Studio projects 2019-12-28 19:20:41 +10:00
Casey Carter 222bc6a443 Include <memory> for std::unique_ptr in DXContext.h 2019-12-19 14:25:12 -08:00
Stenzek e05bc33899 Vulkan: Call VertexManagerBase initialize 2019-12-09 19:16:15 +10:00
Stenzek 07c43b192f D3D12: Call VertexManagerBase initialize 2019-12-09 19:16:04 +10:00
Anthony fdb78b64e1
Merge pull request #8513 from lioncash/bounding-box
VideoCommon/BoundingBox: Make interface for querying bounding box data
2019-12-07 18:40:02 -08:00
Lioncash 9bd533ebe4 VideoCommon/BoundingBox: Make interface for querying bounding box data
Rather than expose the bounding box members directly, we can instead
provide an interface for code to use. This makes it nicer to transition
from global data, as the interface function names are already in
place.
2019-12-05 11:48:42 -05:00
Lioncash 10f7674651 VideoCommon/IndexGenerator: Eliminate static state
Now that we've extracted all of the stateless functions that can be
hidden, it's time to make the index generator a regular class with
active data members.

This can just be a member that sits within the vertex manager base
class. By deglobalizing the state of the index generator we also get rid
of the wonky dual-initializing that was going on within the OpenGL
backend.

Since the renderer is always initialized before the vertex manager, we
now only call Init() once throughout the execution lifecycle.
2019-12-05 10:49:32 -05:00
Stenzek dd23a1ee79 Update VS projects/solutions to VS2019 2019-11-30 13:42:52 +10:00
Lioncash c792961000 Common: Unify logging namespace with Common
Previously the logging was a in a little bit of a disarray. Some things
were in namespaces, and other things were not.

Given this code will feature a bit of restructuring during the
transition over to fmt, this is a good time to unify it under a single
namespace and also remove functions and types from the global namespace.

Now, all functions and types are under the Common::Log namespace. The
only outliers being, of course, the preprocessor macros.
2019-11-28 05:13:21 -05:00
Silent a68789a70c
D3DCommon: Remove unused GetDebugObjectName and tidy up SetDebugObjectName 2019-11-10 16:07:32 +01:00