As documented at https://developer.apple.com/documentation/quartzcore/cametallayer/1478168-framebufferonly: "If the value is true (the default), the CAMetalLayer class allocates its MTLTexture objects in ways that are optimized for display purposes. However, you may not sample, read from, or write to those textures. To support sampling and pixel read/write operations on the layer’s textures (at a cost to performance), set this value to false." Since we call replaceRegion in MacOSSurfaceMVK::present() to write pixels from system memory, we need to set this flag to false explicitly. Bug: b/137673628 Change-Id: I83e28a2940261d9eedf30d7c96427c23d85ac639 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/36608Tested-by:Nicolas Capens <nicolascapens@google.com> Reviewed-by:
Alexis Hétu <sugoi@google.com>
| Name |
Last commit
|
Last update |
|---|---|---|
| .. | ||
| BUILD.gn | Loading commit data... | |
| MacOSSurfaceMVK.h | Loading commit data... | |
| MacOSSurfaceMVK.mm | Loading commit data... | |
| VkSurfaceKHR.cpp | Loading commit data... | |
| VkSurfaceKHR.hpp | Loading commit data... | |
| VkSwapchainKHR.cpp | Loading commit data... | |
| VkSwapchainKHR.hpp | Loading commit data... | |
| Win32SurfaceKHR.cpp | Loading commit data... | |
| Win32SurfaceKHR.hpp | Loading commit data... | |
| XcbSurfaceKHR.cpp | Loading commit data... | |
| XcbSurfaceKHR.hpp | Loading commit data... | |
| XlibSurfaceKHR.cpp | Loading commit data... | |
| XlibSurfaceKHR.hpp | Loading commit data... | |
| libX11.cpp | Loading commit data... | |
| libX11.hpp | Loading commit data... |