summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDave Airlie <airlied@redhat.com>2020-06-09 09:16:42 +1000
committerDave Airlie <airlied@redhat.com>2020-06-09 15:13:32 +1000
commit575ddb719407a8298fe9b78a51ce7cb944c74d4b (patch)
tree37c200d95e664dd1813eef827b1de24898ce2353
parent46a4272fd97ccf1d1cfa99cc9b6fc1a983a48019 (diff)
more subpixels fixes
-rw-r--r--src/gallium/drivers/llvmpipe/lp_screen.c1
-rw-r--r--src/gallium/frontends/vallium/val_device.c4
2 files changed, 3 insertions, 2 deletions
diff --git a/src/gallium/drivers/llvmpipe/lp_screen.c b/src/gallium/drivers/llvmpipe/lp_screen.c
index 304e5283e6b..bb46825db78 100644
--- a/src/gallium/drivers/llvmpipe/lp_screen.c
+++ b/src/gallium/drivers/llvmpipe/lp_screen.c
@@ -336,6 +336,7 @@ llvmpipe_get_param(struct pipe_screen *screen, enum pipe_cap param)
return 32;
case PIPE_CAP_RASTERIZER_SUBPIXEL_BITS:
case PIPE_CAP_VIEWPORT_SUBPIXEL_BITS:
+ case PIPE_CAP_RASTERIZER_SUBPIXEL_BITS:
return 8;
case PIPE_CAP_MULTISAMPLE_Z_RESOLVE:
case PIPE_CAP_RESOURCE_FROM_USER_MEMORY:
diff --git a/src/gallium/frontends/vallium/val_device.c b/src/gallium/frontends/vallium/val_device.c
index 8355dea0ba4..81fc66e97a4 100644
--- a/src/gallium/frontends/vallium/val_device.c
+++ b/src/gallium/frontends/vallium/val_device.c
@@ -390,7 +390,7 @@ void val_GetPhysicalDeviceProperties(VkPhysicalDevice physicalDevice,
.maxComputeWorkGroupCount = { grid_size[0], grid_size[1], grid_size[2] },
.maxComputeWorkGroupInvocations = max_threads_per_block,
.maxComputeWorkGroupSize = { block_size[0], block_size[1], block_size[2] },
- .subPixelPrecisionBits = pdevice->pscreen->get_param(pdevice->pscreen, PIPE_CAP_VIEWPORT_SUBPIXEL_BITS),
+ .subPixelPrecisionBits = pdevice->pscreen->get_param(pdevice->pscreen, PIPE_CAP_RASTERIZER_SUBPIXEL_BITS),
.subTexelPrecisionBits = 4 /* FIXME */,
.mipmapPrecisionBits = 4 /* FIXME */,
.maxDrawIndexedIndexValue = UINT32_MAX,
@@ -400,7 +400,7 @@ void val_GetPhysicalDeviceProperties(VkPhysicalDevice physicalDevice,
.maxViewports = MAX_VIEWPORTS,
.maxViewportDimensions = { (1 << 14), (1 << 14) },
.viewportBoundsRange = { -16384.0, 16384.0 },
- .viewportSubPixelBits = 13, /* We take a float? */
+ .viewportSubPixelBits = pdevice->pscreen->get_param(pdevice->pscreen, PIPE_CAP_VIEWPORT_SUBPIXEL_BITS),
.minMemoryMapAlignment = 4096, /* A page */
.minTexelBufferOffsetAlignment = pdevice->pscreen->get_param(pdevice->pscreen, PIPE_CAP_TEXTURE_BUFFER_OFFSET_ALIGNMENT),
.minUniformBufferOffsetAlignment = pdevice->pscreen->get_param(pdevice->pscreen, PIPE_CAP_CONSTANT_BUFFER_OFFSET_ALIGNMENT),