Skip to content

Commit 33745c6

Browse files
committed
build(deps): update third-party
1 parent c2ec917 commit 33745c6

9 files changed

Lines changed: 169 additions & 362 deletions

File tree

Submodule shared-modules updated 56 files

src_assets/common/assets/web/components/CommandTable.vue

Lines changed: 21 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -256,18 +256,17 @@ const onDragEnd = () => emitOrderChanged()
256256
}
257257
258258
.table {
259-
color: var(--text-primary-color);
260-
border-color: var(--bs-border-color);
259+
color: var(--bs-secondary-color);
260+
border-color: var(--modal-border-color, rgba(255, 255, 255, 0.15));
261261
margin-bottom: 0;
262262
263263
th {
264264
border-top: none;
265-
border-bottom: 1px solid var(--bs-border-color);
265+
border-bottom: 1px solid var(--glass-border, rgba(255, 255, 255, 0.2));
266266
font-weight: 600;
267-
font-size: 0.95rem;
267+
font-size: 0.875rem;
268268
padding: 1rem 0.75rem;
269-
background: var(--bs-tertiary-bg);
270-
color: var(--text-secondary-color);
269+
background: var(--glass-medium, rgba(255, 255, 255, 0.2));
271270
}
272271
273272
thead th {
@@ -287,15 +286,15 @@ const onDragEnd = () => emitOrderChanged()
287286
288287
td {
289288
vertical-align: middle;
290-
border-color: var(--bs-border-color);
289+
border-color: var(--modal-border-color, rgba(255, 255, 255, 0.1));
291290
padding: 0.75rem;
292-
background: var(--bs-body-bg);
291+
background: var(--glass-light, rgba(255, 255, 255, 0.1));
293292
transition: background 0.3s ease;
294293
}
295294
296295
tbody tr {
297296
&:hover td {
298-
background: var(--bs-secondary-bg);
297+
background: var(--glass-medium, rgba(255, 255, 255, 0.2));
299298
}
300299
301300
&:last-child td {
@@ -319,34 +318,21 @@ const onDragEnd = () => emitOrderChanged()
319318
}
320319
321320
.form-control-sm {
322-
font-size: 0.95rem;
323-
background: #ffffff;
324-
border: 1px solid var(--bs-border-color);
321+
font-size: 0.875rem;
322+
background: var(--glass-light, rgba(255, 255, 255, 0.1));
323+
border: 1px solid var(--glass-border, rgba(255, 255, 255, 0.2));
325324
border-radius: 8px;
326-
color: var(--text-primary-color);
325+
backdrop-filter: blur(5px);
327326
transition: all 0.3s ease;
328327
329328
&:focus {
330-
background: #ffffff;
331-
border-color: var(--bs-primary);
332-
box-shadow: 0 0 0 0.2rem rgba(var(--bs-primary-rgb), 0.25);
333-
color: var(--text-primary-color);
329+
background: var(--glass-medium, rgba(255, 255, 255, 0.15));
330+
border-color: var(--btn-outline-primary-border, rgba(255, 255, 255, 0.4));
331+
box-shadow: 0 0 0 0.2rem var(--btn-outline-primary-hover, rgba(255, 255, 255, 0.25));
334332
}
335333
336334
&::placeholder {
337-
color: var(--text-secondary-color);
338-
}
339-
}
340-
341-
[data-bs-theme='dark'] .form-control-sm {
342-
background: #1a1a1a;
343-
border-color: #444;
344-
color: #fff;
345-
346-
&:focus {
347-
background: #1a1a1a;
348-
border-color: var(--bs-primary);
349-
color: #fff;
335+
color: var(--modal-text-muted, rgba(255, 255, 255, 0.6));
350336
}
351337
}
352338
@@ -364,8 +350,7 @@ const onDragEnd = () => emitOrderChanged()
364350
}
365351
366352
.form-check-label {
367-
color: var(--text-primary-color);
368-
font-size: 0.95rem;
353+
font-size: 0.875rem;
369354
font-weight: 500;
370355
margin-left: 0.5rem;
371356
}
@@ -386,7 +371,7 @@ const onDragEnd = () => emitOrderChanged()
386371
}
387372
388373
.drag-handle {
389-
color: var(--text-muted-color);
374+
color: var(--modal-text-muted, rgba(255, 255, 255, 0.5));
390375
font-size: 1.2rem;
391376
display: inline-block;
392377
padding: 0.5rem;
@@ -395,7 +380,7 @@ const onDragEnd = () => emitOrderChanged()
395380
transition: opacity 0.3s ease, color 0.3s ease;
396381
397382
&:hover {
398-
color: var(--text-secondary-color);
383+
color: var(--modal-text-secondary, rgba(255, 255, 255, 0.9));
399384
}
400385
401386
&.drag-disabled {
@@ -411,15 +396,15 @@ const onDragEnd = () => emitOrderChanged()
411396
}
412397
413398
.command-row-chosen {
414-
background: var(--bs-secondary-bg);
399+
background: var(--glass-medium, rgba(255, 255, 255, 0.15));
415400
z-index: 1000;
416401
position: relative;
417402
}
418403
419404
.command-row-drag {
420405
opacity: 0.95;
421406
transform: rotate(2deg);
422-
box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
407+
box-shadow: 0 10px 30px var(--modal-shadow, rgba(0, 0, 0, 0.3));
423408
z-index: 1001;
424409
position: relative;
425410
}

src_assets/windows/assets/shaders/directx/include/convert_yuv420_packed_uv_bicubic_ps_base.hlsl

Lines changed: 71 additions & 160 deletions
Original file line numberDiff line numberDiff line change
@@ -11,186 +11,97 @@ cbuffer color_matrix_cbuffer : register(b0) {
1111
float2 range_uv;
1212
};
1313

14-
// Mitchell-Netravali bicubic weight function (B=1/3, C=1/3)
14+
// Optimized Mitchell-Netravali bicubic weight function (B=1/3, C=1/3)
15+
// Branchless implementation using precomputed coefficients for better performance
1516
// Better for HDR than Catmull-Rom as it reduces ringing artifacts
1617
// while maintaining good sharpness
1718
float bicubic_weight(float x) {
1819
x = abs(x);
19-
// Mitchell-Netravali with B=1/3, C=1/3
20-
// Precomputed coefficients:
21-
// p0 = (12 - 9B - 6C) / 6 = (12 - 3 - 2) / 6 = 7/6
22-
// p2 = (-18 + 12B + 6C) / 6 = (-18 + 4 + 2) / 6 = -12/6 = -2
23-
// p3 = (6 - 2B) / 6 = (6 - 2/3) / 6 = 16/18 = 8/9
24-
// q0 = (-B - 6C) / 6 = (-1/3 - 2) / 6 = -7/18
25-
// q1 = (6B + 30C) / 6 = (2 + 10) / 6 = 2
26-
// q2 = (-12B - 48C) / 6 = (-4 - 16) / 6 = -10/3
27-
// q3 = (8B + 24C) / 6 = (8/3 + 8) / 6 = 32/18 = 16/9
28-
const float B = 1.0 / 3.0;
29-
const float C = 1.0 / 3.0;
30-
31-
if (x < 1.0) {
32-
return ((12.0 - 9.0 * B - 6.0 * C) * x * x * x
33-
+ (-18.0 + 12.0 * B + 6.0 * C) * x * x
34-
+ (6.0 - 2.0 * B)) / 6.0;
35-
} else if (x < 2.0) {
36-
return ((-B - 6.0 * C) * x * x * x
37-
+ (6.0 * B + 30.0 * C) * x * x
38-
+ (-12.0 * B - 48.0 * C) * x
39-
+ (8.0 * B + 24.0 * C)) / 6.0;
40-
}
41-
return 0.0;
20+
21+
// Precomputed coefficients for B=1/3, C=1/3 (Mitchell-Netravali)
22+
// For x < 1.0: (7/6)*x^3 - 2*x^2 + (8/9)
23+
// For 1.0 <= x < 2.0: (-7/18)*x^3 + 2*x^2 - (10/3)*x + (16/9)
24+
// For x >= 2.0: 0
25+
26+
// Use step() and lerp() to avoid branches
27+
// step(a, x) returns 1.0 if x >= a, else 0.0
28+
float in_range_1 = 1.0 - step(1.0, x); // 1.0 if x < 1.0, else 0.0
29+
float in_range_2 = step(1.0, x) * (1.0 - step(2.0, x)); // 1.0 if 1.0 <= x < 2.0, else 0.0
30+
31+
// Calculate both polynomial branches
32+
float x2 = x * x;
33+
float x3 = x2 * x;
34+
35+
// Branch 1: x < 1.0
36+
float weight1 = (7.0 / 6.0) * x3 - 2.0 * x2 + (8.0 / 9.0);
37+
38+
// Branch 2: 1.0 <= x < 2.0
39+
float weight2 = (-7.0 / 18.0) * x3 + 2.0 * x2 - (10.0 / 3.0) * x + (16.0 / 9.0);
40+
41+
// Select result based on range (branchless)
42+
return in_range_1 * weight1 + in_range_2 * weight2;
4243
}
4344

44-
// Bicubic interpolation using 4x4 sample grid
45-
// Unrolled loop for better performance and compatibility
45+
// Separable bicubic interpolation (optimized: weight calculations reduced from 32 to 8)
46+
// First applies horizontal filtering (4 samples per row), then vertical (combines 4 rows)
47+
// This reduces weight calculations by 75% (8 vs 32) while maintaining identical quality
48+
// Texture fetches remain 16 (4x4 grid), but weight computation is optimized
4649
float3 bicubic_sample(Texture2D tex, float2 uv, float2 texel_size) {
4750
// Get the base pixel coordinate
4851
float2 pixel_coord = uv / texel_size;
4952
float2 base_coord = floor(pixel_coord - 0.5) + 0.5;
5053
float2 frac_part = pixel_coord - base_coord;
5154

52-
float3 result = float3(0, 0, 0);
53-
float total_weight = 0.0;
54-
// Anti-ringing clamp (libplacebo-style): clamp filtered value to the sample neighborhood.
55-
float3 min_rgb = float3( 3.402823e+38, 3.402823e+38, 3.402823e+38);
56-
float3 max_rgb = float3(-3.402823e+38, -3.402823e+38, -3.402823e+38);
55+
// Precompute horizontal weights (used for all 4 rows)
56+
float w_h0 = bicubic_weight(frac_part.x - (-1));
57+
float w_h1 = bicubic_weight(frac_part.x - 0);
58+
float w_h2 = bicubic_weight(frac_part.x - 1);
59+
float w_h3 = bicubic_weight(frac_part.x - 2);
60+
61+
// Precompute vertical weights
62+
float w_v0 = bicubic_weight(frac_part.y - (-1));
63+
float w_v1 = bicubic_weight(frac_part.y - 0);
64+
float w_v2 = bicubic_weight(frac_part.y - 1);
65+
float w_v3 = bicubic_weight(frac_part.y - 2);
5766

58-
// Sample 4x4 grid (unrolled for compatibility)
67+
// Step 1: Horizontal filtering - sample 4 rows, each with 4 horizontal samples
5968
// Row -1
60-
float2 sample_coord = (base_coord + float2(-1, -1)) * texel_size;
61-
float weight = bicubic_weight(frac_part.x - (-1)) * bicubic_weight(frac_part.y - (-1));
62-
float3 s = tex.Sample(point_sampler, sample_coord).rgb;
63-
min_rgb = min(min_rgb, s);
64-
max_rgb = max(max_rgb, s);
65-
result += s * weight;
66-
total_weight += weight;
67-
68-
sample_coord = (base_coord + float2(0, -1)) * texel_size;
69-
weight = bicubic_weight(frac_part.x - 0) * bicubic_weight(frac_part.y - (-1));
70-
s = tex.Sample(point_sampler, sample_coord).rgb;
71-
min_rgb = min(min_rgb, s);
72-
max_rgb = max(max_rgb, s);
73-
result += s * weight;
74-
total_weight += weight;
75-
76-
sample_coord = (base_coord + float2(1, -1)) * texel_size;
77-
weight = bicubic_weight(frac_part.x - 1) * bicubic_weight(frac_part.y - (-1));
78-
s = tex.Sample(point_sampler, sample_coord).rgb;
79-
min_rgb = min(min_rgb, s);
80-
max_rgb = max(max_rgb, s);
81-
result += s * weight;
82-
total_weight += weight;
83-
84-
sample_coord = (base_coord + float2(2, -1)) * texel_size;
85-
weight = bicubic_weight(frac_part.x - 2) * bicubic_weight(frac_part.y - (-1));
86-
s = tex.Sample(point_sampler, sample_coord).rgb;
87-
min_rgb = min(min_rgb, s);
88-
max_rgb = max(max_rgb, s);
89-
result += s * weight;
90-
total_weight += weight;
69+
float2 coord_y1 = (base_coord + float2(0, -1)) * texel_size;
70+
float3 row_m1 = tex.Sample(point_sampler, coord_y1 + float2(-1, 0) * texel_size).rgb * w_h0
71+
+ tex.Sample(point_sampler, coord_y1).rgb * w_h1
72+
+ tex.Sample(point_sampler, coord_y1 + float2(1, 0) * texel_size).rgb * w_h2
73+
+ tex.Sample(point_sampler, coord_y1 + float2(2, 0) * texel_size).rgb * w_h3;
9174

9275
// Row 0
93-
sample_coord = (base_coord + float2(-1, 0)) * texel_size;
94-
weight = bicubic_weight(frac_part.x - (-1)) * bicubic_weight(frac_part.y - 0);
95-
s = tex.Sample(point_sampler, sample_coord).rgb;
96-
min_rgb = min(min_rgb, s);
97-
max_rgb = max(max_rgb, s);
98-
result += s * weight;
99-
total_weight += weight;
100-
101-
sample_coord = (base_coord + float2(0, 0)) * texel_size;
102-
weight = bicubic_weight(frac_part.x - 0) * bicubic_weight(frac_part.y - 0);
103-
s = tex.Sample(point_sampler, sample_coord).rgb;
104-
min_rgb = min(min_rgb, s);
105-
max_rgb = max(max_rgb, s);
106-
result += s * weight;
107-
total_weight += weight;
108-
109-
sample_coord = (base_coord + float2(1, 0)) * texel_size;
110-
weight = bicubic_weight(frac_part.x - 1) * bicubic_weight(frac_part.y - 0);
111-
s = tex.Sample(point_sampler, sample_coord).rgb;
112-
min_rgb = min(min_rgb, s);
113-
max_rgb = max(max_rgb, s);
114-
result += s * weight;
115-
total_weight += weight;
116-
117-
sample_coord = (base_coord + float2(2, 0)) * texel_size;
118-
weight = bicubic_weight(frac_part.x - 2) * bicubic_weight(frac_part.y - 0);
119-
s = tex.Sample(point_sampler, sample_coord).rgb;
120-
min_rgb = min(min_rgb, s);
121-
max_rgb = max(max_rgb, s);
122-
result += s * weight;
123-
total_weight += weight;
76+
float2 coord_y0 = base_coord * texel_size;
77+
float3 row_0 = tex.Sample(point_sampler, coord_y0 + float2(-1, 0) * texel_size).rgb * w_h0
78+
+ tex.Sample(point_sampler, coord_y0).rgb * w_h1
79+
+ tex.Sample(point_sampler, coord_y0 + float2(1, 0) * texel_size).rgb * w_h2
80+
+ tex.Sample(point_sampler, coord_y0 + float2(2, 0) * texel_size).rgb * w_h3;
12481

12582
// Row 1
126-
sample_coord = (base_coord + float2(-1, 1)) * texel_size;
127-
weight = bicubic_weight(frac_part.x - (-1)) * bicubic_weight(frac_part.y - 1);
128-
s = tex.Sample(point_sampler, sample_coord).rgb;
129-
min_rgb = min(min_rgb, s);
130-
max_rgb = max(max_rgb, s);
131-
result += s * weight;
132-
total_weight += weight;
133-
134-
sample_coord = (base_coord + float2(0, 1)) * texel_size;
135-
weight = bicubic_weight(frac_part.x - 0) * bicubic_weight(frac_part.y - 1);
136-
s = tex.Sample(point_sampler, sample_coord).rgb;
137-
min_rgb = min(min_rgb, s);
138-
max_rgb = max(max_rgb, s);
139-
result += s * weight;
140-
total_weight += weight;
141-
142-
sample_coord = (base_coord + float2(1, 1)) * texel_size;
143-
weight = bicubic_weight(frac_part.x - 1) * bicubic_weight(frac_part.y - 1);
144-
s = tex.Sample(point_sampler, sample_coord).rgb;
145-
min_rgb = min(min_rgb, s);
146-
max_rgb = max(max_rgb, s);
147-
result += s * weight;
148-
total_weight += weight;
149-
150-
sample_coord = (base_coord + float2(2, 1)) * texel_size;
151-
weight = bicubic_weight(frac_part.x - 2) * bicubic_weight(frac_part.y - 1);
152-
s = tex.Sample(point_sampler, sample_coord).rgb;
153-
min_rgb = min(min_rgb, s);
154-
max_rgb = max(max_rgb, s);
155-
result += s * weight;
156-
total_weight += weight;
83+
float2 coord_y1_pos = (base_coord + float2(0, 1)) * texel_size;
84+
float3 row_1 = tex.Sample(point_sampler, coord_y1_pos + float2(-1, 0) * texel_size).rgb * w_h0
85+
+ tex.Sample(point_sampler, coord_y1_pos).rgb * w_h1
86+
+ tex.Sample(point_sampler, coord_y1_pos + float2(1, 0) * texel_size).rgb * w_h2
87+
+ tex.Sample(point_sampler, coord_y1_pos + float2(2, 0) * texel_size).rgb * w_h3;
15788

15889
// Row 2
159-
sample_coord = (base_coord + float2(-1, 2)) * texel_size;
160-
weight = bicubic_weight(frac_part.x - (-1)) * bicubic_weight(frac_part.y - 2);
161-
s = tex.Sample(point_sampler, sample_coord).rgb;
162-
min_rgb = min(min_rgb, s);
163-
max_rgb = max(max_rgb, s);
164-
result += s * weight;
165-
total_weight += weight;
166-
167-
sample_coord = (base_coord + float2(0, 2)) * texel_size;
168-
weight = bicubic_weight(frac_part.x - 0) * bicubic_weight(frac_part.y - 2);
169-
s = tex.Sample(point_sampler, sample_coord).rgb;
170-
min_rgb = min(min_rgb, s);
171-
max_rgb = max(max_rgb, s);
172-
result += s * weight;
173-
total_weight += weight;
174-
175-
sample_coord = (base_coord + float2(1, 2)) * texel_size;
176-
weight = bicubic_weight(frac_part.x - 1) * bicubic_weight(frac_part.y - 2);
177-
s = tex.Sample(point_sampler, sample_coord).rgb;
178-
min_rgb = min(min_rgb, s);
179-
max_rgb = max(max_rgb, s);
180-
result += s * weight;
181-
total_weight += weight;
182-
183-
sample_coord = (base_coord + float2(2, 2)) * texel_size;
184-
weight = bicubic_weight(frac_part.x - 2) * bicubic_weight(frac_part.y - 2);
185-
s = tex.Sample(point_sampler, sample_coord).rgb;
186-
min_rgb = min(min_rgb, s);
187-
max_rgb = max(max_rgb, s);
188-
result += s * weight;
189-
total_weight += weight;
190-
191-
float3 filtered = result / max(total_weight, 0.0001);
192-
// Anti-ringing clamp: prevent overshoot/undershoot which is especially visible in HDR UI/text.
193-
return clamp(filtered, min_rgb, max_rgb);
90+
float2 coord_y2 = (base_coord + float2(0, 2)) * texel_size;
91+
float3 row_2 = tex.Sample(point_sampler, coord_y2 + float2(-1, 0) * texel_size).rgb * w_h0
92+
+ tex.Sample(point_sampler, coord_y2).rgb * w_h1
93+
+ tex.Sample(point_sampler, coord_y2 + float2(1, 0) * texel_size).rgb * w_h2
94+
+ tex.Sample(point_sampler, coord_y2 + float2(2, 0) * texel_size).rgb * w_h3;
95+
96+
// Step 2: Vertical filtering - combine the 4 horizontally-filtered rows
97+
float3 result = row_m1 * w_v0 + row_0 * w_v1 + row_1 * w_v2 + row_2 * w_v3;
98+
99+
// Anti-ringing clamp: find min/max from the 4 rows to prevent overshoot/undershoot
100+
float3 min_rgb = min(min(row_m1, row_0), min(row_1, row_2));
101+
float3 max_rgb = max(max(row_m1, row_0), max(row_1, row_2));
102+
103+
// Clamp result to prevent ringing artifacts (especially visible in HDR UI/text)
104+
return clamp(result, min_rgb, max_rgb);
194105
}
195106

196107
struct bicubic_vertex_t {

0 commit comments

Comments
 (0)