Fix T100132: Disable winding when calculating islands for uv sculpt tools

Winding was originally added to island detection in 5197aa04c6.
However the sculpt tools can flip faces, potentially creating orphaned
islands if winding is enabled.

Differential Revision: https://developer.blender.org/D15600
This commit is contained in:
Chris Blackbourn 2022-08-04 11:11:41 +12:00
parent 8288017635
commit dcf50cf046
Notes: blender-bot 2023-02-14 05:53:38 +01:00
Referenced by issue #100132, When UV Sculpt tools flip UVs they create new islands.
1 changed files with 6 additions and 7 deletions

View File

@ -492,13 +492,12 @@ static UvSculptData *uv_sculpt_stroke_init(bContext *C, wmOperator *op, const wm
data->uvsculpt = &ts->uvsculpt->paint;
if (do_island_optimization) {
/* We will need island information */
data->elementMap = BM_uv_element_map_create(bm, scene, false, true, true);
}
else {
data->elementMap = BM_uv_element_map_create(bm, scene, false, true, false);
}
/* Winding was added to island detection in 5197aa04c6bd
* However the sculpt tools can flip faces, potentially creating orphaned islands.
* See T100132 */
bool use_winding = false;
data->elementMap = BM_uv_element_map_create(
bm, scene, false, use_winding, do_island_optimization);
if (!data->elementMap) {
uv_sculpt_stroke_exit(C, op);