[Mesa-dev] [PATCH 4/5] radv: Fix fragment resolve destination offset.
Bas Nieuwenhuizen
bas at basnieuwenhuizen.nl
Wed Dec 27 11:19:47 UTC 2017
On Wed, Dec 27, 2017 at 5:25 AM, Dieter Nützel <Dieter at nuetzel-hh.de> wrote:
> Am 27.12.2017 01:20, schrieb Bas Nieuwenhuizen:
>>
>> The position start at (dst.x, dst.y), so if we want the source to
>> start at (src.x, src.y), we have to offset by (src.x-dst.x,src.y-dst.y).
>>
>> Haven't tested that this fixed anything yet, but found by inspection.
>> Fixes: 69136f4e633 "radv/meta: add resolve pass using fragment/vertex
>> shaders"
>> ---
>> src/amd/vulkan/radv_meta_resolve_fs.c | 4 ++--
>> 1 file changed, 2 insertions(+), 2 deletions(-)
>>
>> diff --git a/src/amd/vulkan/radv_meta_resolve_fs.c
>> b/src/amd/vulkan/radv_meta_resolve_fs.c
>> index 756309efd2e..53a3d68284a 100644
>> --- a/src/amd/vulkan/radv_meta_resolve_fs.c
>> +++ b/src/amd/vulkan/radv_meta_resolve_fs.c
>> @@ -407,8 +407,8 @@ emit_resolve(struct radv_cmd_buffer *cmd_buffer,
>> cmd_buffer->state.flush_bits |= RADV_CMD_FLAG_FLUSH_AND_INV_CB;
>>
>> unsigned push_constants[2] = {
>> - src_offset->x,
>> - src_offset->y,
>> + src_offset->x - dst_offset->x,
>> + src_offset->y - dst_offset->y,
>
>
> Shouldn't that look like this:
>
> + src_offset->x - dest_offset->x,
> + src_offset->y - dest_offset->y,
>
> Even compilation error is solved.
Woops, yes indeed.
>
> With this fixed,
>
> series is
>
> Tested-by: Dieter Nützel <Dieter at nuetzel-hh.de>
Thanks.
>
> Dieter
>
>> };
>> radv_CmdPushConstants(radv_cmd_buffer_to_handle(cmd_buffer),
>>
>> device->meta_state.resolve_fragment.p_layout,
More information about the mesa-dev
mailing list