From a3bcf6fe2104839d9ead80c68c7bb8a5aacbb729 Mon Sep 17 00:00:00 2001 From: 0x2CA <2478557459@qq.com> Date: Tue, 14 Oct 2025 04:12:58 +0800 Subject: [PATCH] windows: Fix shader rotation order for pattern rendering (#39993) old image new image Release Notes: - N/A --- crates/gpui/src/platform/windows/shaders.hlsl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/crates/gpui/src/platform/windows/shaders.hlsl b/crates/gpui/src/platform/windows/shaders.hlsl index c3ad2952db..d6168eea09 100644 --- a/crates/gpui/src/platform/windows/shaders.hlsl +++ b/crates/gpui/src/platform/windows/shaders.hlsl @@ -390,7 +390,7 @@ float4 gradient_color(Background background, float pattern_period = pattern_height * sin(stripe_angle); float2x2 rotation = rotate2d(stripe_angle); float2 relative_position = position - bounds.origin; - float2 rotated_point = mul(rotation, relative_position); + float2 rotated_point = mul(relative_position, rotation); float pattern = fmod(rotated_point.x, pattern_period); float distance = min(pattern, pattern_period - pattern) - pattern_period * (pattern_width / pattern_height) / 2.0f; color = solid_color;