mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-22 06:38:09 +02:00
The scissor planes we were setting up did not actually correspond to scissor with widths / heights being a multiple of full pixels, rather they had an excess width / height of (nearly) half a pixel (at the x0 and y0 edges). (Note it's not an actual scissor as in graphics APIs terms, it's the intersection of fb/viewport/scissor.) Without multisampling that was still fine (since we always test at pixel center) however vk cts complained (for some reason only when using 8 samples (not announced by lavapipe yet) - no idea why it doesn't fail when using 4 samples), in tests such as dEQP-VK.renderpass2.depth_stencil_resolve.image_2d_17_1.samples_8.s8_uint.depth_zero_stencil_zero_testing_stencil_samplemask, which uses scissor and noted that the result for some pixels which are outside the rendering area don't contain the clear color. And actually a llvmpipe test was failing as well. There is in fact no need for separate adjustments for msaa at all, as long as we ensure that x0, y0, x1, y1 all are exactly on their respective plane edges (inclusive for x0/y0, exclusive for x1/y1). So the logic is mostly reverted to what it was before this was adjusted for msaa (albeit the original code then had an excess adjustment of nearly a full pixel at the x0 and y0 edges which is probably why it didn't work for msaa). Fixes a couple cases of clip-and-scissor-blit tests in llvmpipe and various other drivers hitting this indirectly. Interestingly though not quite all cases are fixed and even more odd is that not exactly the same cases are fixed for all drivers, so maybe there's more to it (need to respect bottom_edge_rule or something similar?) Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37181> |
||
|---|---|---|
| .. | ||
| ci | ||
| tests | ||
| meson.build | ||
| virgl_buffer.c | ||
| virgl_context.c | ||
| virgl_context.h | ||
| virgl_driinfo.h.in | ||
| virgl_encode.c | ||
| virgl_encode.h | ||
| virgl_public.h | ||
| virgl_query.c | ||
| virgl_resource.c | ||
| virgl_resource.h | ||
| virgl_screen.c | ||
| virgl_screen.h | ||
| virgl_staging_mgr.c | ||
| virgl_staging_mgr.h | ||
| virgl_streamout.c | ||
| virgl_texture.c | ||
| virgl_tgsi.c | ||
| virgl_transfer_queue.c | ||
| virgl_transfer_queue.h | ||
| virgl_video.c | ||
| virgl_video.h | ||
| virgl_winsys.h | ||