Announcements
Notice: Upload of PDF documents is currently unavailable across the Community due to an ongoing issue.

edgeToFaceSelect is bugged?

edgeToFaceSelect is bugged?

dmitriy.shpilevoy
Collaborator Collaborator
7,443 Views
5 Replies
Message 1 of 6

edgeToFaceSelect is bugged?

dmitriy.shpilevoy
Collaborator
Collaborator

Trying to convert edge to face selection in Unwrap Editor using maxscript. It only works if 2 or more edges selected and at least 2 edges are not touching.

 

1 create default plane and convert it to Editable Poly

2 apply Unwrap UVW modifier and open its editor

3 switch to face mode and select all faces(you need it to see face selection changes)

4 switch to edge mode and select any single edge

5 in Listener run 

$.modifiers[1].edgeToFaceSelect()

6 switch to faces

You can see that No faces are selected.

 

To see how it is supposed to work:

1b create default plane and convert it to Editable Poly

2b apply Unwrap UVW modifier and open its editor

3b switch to face mode and select all faces(you need it to see face selection changes)

4b switch to edge mode and select 2 edges that are not touching and share same face(top and bottom or left and right edges of the same face)

5b in Listener run 

$.modifiers[1].edgeToFaceSelect()

6b switch to faces

Face that has both of these edges, is selected as expected.

 

If I select a single edge and convert selection to faces via UI, by clicking on faces button while holding Ctrl - it will work as expected, thus I assume the problem is with edgeToFaceSelect()

but that method doesn't produce any events in macrorecorder so I can't use it.

0 Likes
7,444 Views
5 Replies
Replies (5)
Message 2 of 6

dmitriy.shpilevoy
Collaborator
Collaborator

There is some fundamental issue with Unwrap selection conversion.

These have same broken behavior when using maxscript:

vertToEdgeSelect()
vertToFaceSelect()
but work as expected via user interface (Ctrl+click on different selection mode)

 

If I can do it through user interface then code that works is already there. From user point of view, fix should be as easy as switching maxscript from whatever it calls at the moment to calling code that works.

 

Posted here and tried to report directly from within 3dsmax, so far not even an automated response.

0 Likes
Message 3 of 6

denisT.MaxDoctor
Advisor
Advisor

what MAX version do you use?

2016, 2020, 2022, 2023 work as expected for me. I don't see any problems. All sub-conversion methods work with and without modifier panel opened. 

 

0 Likes
Message 4 of 6

dmitriy.shpilevoy
Collaborator
Collaborator

Tried in

2021 #(23000, 57, 0, 23, 3, 2, 3508, 2021, ".3.2 Security Fix")

2022 #(24000, 60, 0, 24, 2, 0, 2334, 2022, ".2 Update ")

2023 #(25000, 62, 0, 25, 3, 0, 3640, 2023, ".3 Update")

2023 tested on three different machines

 

> All sub-conversion methods work with and without modifier panel opened.

You can select a single vertex in Unwrap Editor and convert it to edges or faces, or select a single edge and convert it to faces selection using maxscript command?

Can you describe your exact steps to convert single edge to faces selection in Unwrap Editor with maxscript please, maybe I'm missing crucial step somewhere?

0 Likes
Message 5 of 6

denisT.MaxDoctor
Advisor
Advisor

I didn't read your original post carefully. You are talking specifically about the case of a single sub-selection and conversion.

As you can see, the manual built-in methods from the top menu of the "Edit UVWs" dialog do not work for a single case either. The modifier in this case for the CTRL+ option first expands the sub-selection and then converts the result. You can do the same by checking for the single selection case and applying the expandSelection method before the conversion.
A single edge-to-face conversion is a little tricky. You can first do an edge-to-vert convert, expand, and finally do a vert-to-face.

0 Likes
Message 6 of 6

dmitriy.shpilevoy
Collaborator
Collaborator

edgeToFaceSelect.jpg

Thanks for the tip with single vertex conversion. BTW, how did you figure out max does selection expanding first? I didn't see it in help docs and it doesn't show up in macrorecorder. Is there an article I can read on what is going on under the hood of "Edit UVWs"?

 

Unfortunately it doesn't work for edgeToFaceSelect().

Issue can occur even with multiple edges selected, single edge is just clearer way to demonstrate it. I can probably catch these cases by selecting random face first, do edgeToFaceSelect() and then check if getSelectedFaces() returns empty array, but real problem is that expand selects too much.

 

Here's the case that shows difference between expand and ctrl+click approaches.

0 Likes