S H
6e1d15f8a2
Avoid signed-shift undefined behavior in EdgeGrid distance propagation ( #16626 )
...
Danielsson propagation in EdgeGrid::Grid::calculate_sdf() doubles a negative neighbor offset (-1 or -ncols) with a left shift, which is undefined behavior in C++17. Multiply by two instead.
Adds test_edge_grid.cpp, which checks signed distances inside and outside a rectangle beyond the initial edge band. Built with -fsanitize=shift, it aborts on the old code and passes with the fix.
2026-10-19 20:44:24 -05:00
..
2026-10-19 20:44:24 -05:00
2026-10-03 13:45:21 +08:00
2026-10-19 16:08:59 +08:00
2026-10-05 16:47:17 +08:00
2026-10-19 12:05:55 -03:00
2026-10-09 19:25:53 +08:00
2026-10-13 15:13:07 -05:00
2026-10-07 14:22:32 +08:00
2026-10-13 10:49:27 -05:00
2026-10-04 14:50:15 +08:00
2026-10-03 13:45:21 +08:00
2026-10-05 23:06:01 -05:00
2026-10-05 16:47:17 +08:00
2026-10-07 14:22:32 +08:00
2026-10-05 16:47:17 +08:00
2026-10-03 13:45:21 +08:00
2026-10-05 16:47:17 +08:00
2026-10-08 13:40:36 +08:00
2026-10-19 12:05:55 -03:00
2026-10-09 16:48:48 -03:00
2026-10-03 13:45:21 +08:00
2026-10-19 20:44:24 -05:00
2026-10-03 13:45:21 +08:00
2026-10-09 22:23:07 +08:00
2026-10-05 16:47:17 +08:00
2026-10-03 13:45:21 +08:00
2026-10-04 14:50:15 +08:00
2026-10-10 16:03:34 -03:00
2026-10-03 13:45:21 +08:00
2026-10-10 01:44:42 -04:00
2026-10-13 10:53:57 -03:00
2026-10-05 11:55:18 -04:00
2026-10-09 16:48:48 -03:00
2026-10-05 21:49:32 -03:00
2026-10-05 16:47:17 +08:00
2026-10-04 14:50:15 +08:00
2026-10-07 14:22:32 +08:00
2026-10-12 21:59:17 -03:00
2026-10-08 16:00:28 -03:00
2026-10-03 13:45:21 +08:00
2026-10-16 18:47:49 +08:00
2026-10-12 21:59:17 -03:00
2026-10-05 16:47:17 +08:00
2026-10-03 13:45:21 +08:00
2026-10-03 13:45:21 +08:00
2026-10-03 13:45:21 +08:00
2026-10-03 13:45:21 +08:00
2026-10-05 16:47:17 +08:00
2026-10-19 15:53:32 -03:00
2026-10-03 13:45:21 +08:00
2026-10-03 13:45:21 +08:00
2025-12-08 22:42:11 +08:00
2026-10-09 11:52:55 +08:00
2026-10-05 16:47:17 +08:00
2026-10-05 16:47:17 +08:00
2026-10-05 14:19:47 +08:00
2026-10-19 13:29:26 +08:00
2026-10-03 13:45:21 +08:00
2026-10-03 13:45:21 +08:00
2026-10-03 13:45:21 +08:00
2026-10-19 15:53:32 -03:00
2026-10-05 16:47:17 +08:00
2026-10-05 18:29:35 +08:00
2026-10-03 13:45:21 +08:00
2026-10-03 13:45:21 +08:00
2026-10-03 13:45:21 +08:00
2026-10-03 13:45:21 +08:00
2026-10-12 21:59:17 -03:00
2026-10-05 14:19:47 +08:00
2026-10-13 19:51:07 +08:00
2026-10-19 20:30:03 -03:00
2026-10-07 14:22:32 +08:00
2026-10-05 16:47:17 +08:00
2026-10-03 13:45:21 +08:00
2026-10-04 14:50:15 +08:00
2026-10-16 18:47:49 +08:00
2026-10-03 13:45:21 +08:00
2026-10-07 14:22:32 +08:00
2026-10-05 16:47:17 +08:00
2026-10-13 22:38:04 +08:00
2026-10-05 16:47:17 +08:00
2026-10-19 20:30:03 -03:00
2026-10-19 20:30:03 -03:00