Commit f680b02
committed
fix: picker sees through highlighted items (fix #737)
Fragments puts highlight materials in extra slots of `mesh.material` and
tags the highlighted item's `geometry.groups` entry with
`materialIndex >= 1`. Swapping to a length-1 `[_idMaterial]` array made
three skip those groups, so clicking a highlighted item read back the
element behind instead of toggling the selection off.
Pad the swap array to the original length, every slot pointing at the
override material.1 parent 09f81ea commit f680b02
1 file changed
Lines changed: 18 additions & 3 deletions
Lines changed: 18 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
435 | 435 | | |
436 | 436 | | |
437 | 437 | | |
438 | | - | |
| 438 | + | |
| 439 | + | |
| 440 | + | |
| 441 | + | |
| 442 | + | |
| 443 | + | |
| 444 | + | |
| 445 | + | |
| 446 | + | |
| 447 | + | |
| 448 | + | |
| 449 | + | |
439 | 450 | | |
440 | 451 | | |
441 | 452 | | |
| |||
659 | 670 | | |
660 | 671 | | |
661 | 672 | | |
662 | | - | |
663 | | - | |
| 673 | + | |
| 674 | + | |
| 675 | + | |
| 676 | + | |
| 677 | + | |
| 678 | + | |
664 | 679 | | |
665 | 680 | | |
666 | 681 | | |
| |||
0 commit comments