mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-05 07:28:11 +02:00
gallium/auxiliary/vl: Fix coordinates clamp in compute shaders
Fixes:a6a43963ed("gallium/auxiliary/vl: Clamp coordinates in compute shaders") Acked-by: Thong Thai <thong.thai@amd.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26123> (cherry picked from commitef0546152f)
This commit is contained in:
parent
f56bb3ec4b
commit
73b6b7497e
2 changed files with 5 additions and 9 deletions
|
|
@ -424,7 +424,7 @@
|
|||
"description": "gallium/auxiliary/vl: Fix coordinates clamp in compute shaders",
|
||||
"nominated": true,
|
||||
"nomination_type": 1,
|
||||
"resolution": 0,
|
||||
"resolution": 1,
|
||||
"main_sha": null,
|
||||
"because_sha": "a6a43963ed0648649d70bfe7998971c1927d9b51",
|
||||
"notes": null
|
||||
|
|
|
|||
|
|
@ -956,14 +956,10 @@ draw_layers(struct vl_compositor *c,
|
|||
drawn.translate_y = layer->viewport.translate[1];
|
||||
drawn.sampler0_w = (float)layer->sampler_views[0]->texture->width0;
|
||||
drawn.sampler0_h = (float)layer->sampler_views[0]->texture->height0;
|
||||
drawn.clamp_x = (float)samplers[0]->texture->width0 *
|
||||
(layer->src.br.x - layer->src.tl.x) - 0.5;
|
||||
drawn.clamp_y = (float)samplers[0]->texture->height0 *
|
||||
(layer->src.br.y - layer->src.tl.y) - 0.5;
|
||||
drawn.chroma_clamp_x = (float)sampler1->texture->width0 *
|
||||
(layer->src.br.x - layer->src.tl.x) - 0.5;
|
||||
drawn.chroma_clamp_y = (float)sampler1->texture->height0 *
|
||||
(layer->src.br.y - layer->src.tl.y) - 0.5;
|
||||
drawn.clamp_x = (float)samplers[0]->texture->width0 * layer->src.br.x - 0.5;
|
||||
drawn.clamp_y = (float)samplers[0]->texture->height0 * layer->src.br.y - 0.5;
|
||||
drawn.chroma_clamp_x = (float)sampler1->texture->width0 * layer->src.br.x - 0.5;
|
||||
drawn.chroma_clamp_y = (float)sampler1->texture->height0 * layer->src.br.y - 0.5;
|
||||
drawn.chroma_offset_x = chroma_offset_x(s->chroma_location);
|
||||
drawn.chroma_offset_y = chroma_offset_y(s->chroma_location);
|
||||
set_viewport(s, &drawn, samplers);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue