MaxScript function uv.getSelectedGeomEdges broken ?

MaxScript function uv.getSelectedGeomEdges broken ?

Anonymous
Not applicable
954 Views
11 Replies
Message 1 of 12

MaxScript function uv.getSelectedGeomEdges broken ?

Anonymous
Not applicable
the unwrap functions like getSelectedGeomEdges or getSelectedGeomEdgesbyNode arent working anymore.
they allways return undefined when used.
is there a way to convert selected UV-Edges to Mesh Edges somehow ??

the GeomVert function works fine

thanks in advance
0 Likes
955 Views
11 Replies
Replies (11)
Message 2 of 12

Anonymous
Not applicable
Broken in mine aswell.
0 Likes
Message 3 of 12

Steve_Curley
Mentor
Mentor
Moved to the Maxscript forum (from Max 2010) - you will get better responses by posting in the most appropriate forum.

Max 2016 (SP1/EXT1)
Win7Pro x64 (SP1). i5-3570K @ 4.4GHz, 8Gb Ram, DX11.
nVidia GTX760 (2GB) (Driver 430.86).

0 Likes
Message 4 of 12

Anonymous
Not applicable
I just googled for
unwrap5.getSelectedGeomEdges()

and
getSelectedGeomEdgesByNode 


because booth return in my case as well undefined, it seems that they are Broken in 3dsMax 2010. is there a fix in the work?

Now I have a script a workaround because of this broken method in Maxscript :(
0 Likes
Message 5 of 12

Anonymous
Not applicable
I'm trying this with Max2011 right now for a script I'm working on, and it's still broken. Seems like it just always returns Undefined.
0 Likes
Message 6 of 12

Anonymous
Not applicable
the same in Max 2009, at least it works in Max 9
0 Likes
Message 7 of 12

Anonymous
Not applicable
@ AUTODESK: Any response or updates on this? I am working on a script for someone and I need this functionality, its still BROKEN!!!! in max 2010. If I or my company pays such a high amount of money for 3dsMax I should be able to expect at least some support or fix.

How am I supposed to transfer UV geo selections to poly / edge bit array selections otherwise?
0 Likes
Message 8 of 12

Steve_Curley
Mentor
Mentor
These are peer-to-peer forums, not an official support channel.

Best I can advise is to report this as a bug using the Defect Report Submission Form.

Max 2016 (SP1/EXT1)
Win7Pro x64 (SP1). i5-3570K @ 4.4GHz, 8Gb Ram, DX11.
nVidia GTX760 (2GB) (Driver 430.86).

0 Likes
Message 9 of 12

a3dcreator
Advocate
Advocate
I Myself am running into the same issue.
has anyone found a workaround or solution to the problem?

thanks.
0 Likes
Message 10 of 12

Anonymous
Not applicable
Hi guys,

I also ran into this problem and managed to get a workaround for this.
Note the solution is not really good, as it loops through basically all edges of the object.
So here's how I did it:

-- example InValues for hte function
InObject = $;
InCompareEdgesCount = ( polyop.getEdgeSelection InObject.baseObject ).count;

-- the function compute the selected UV GeomEdges by
-- going through all edges that are available ( InCompareEdgesCount )
-- takes also the object as input
-- returns an array of the selected edges
function fGetUVGeomEdges InObject InCompareEdgesCount =
(
-- change to edge mode
subobjectLevel = 2;
OutEdges = #();
-- get the uv edge IDs of the selected edges
local bSOriginalUVEdges = copy ( ( InObject.modifiers.getSelectedEdgesByNode InObject ) as array ) #noMap;
local bSEdges = 1;

while bSEdges <= InCompareEdgesCount do
(
-- reset selection just to be sure and select the next edge
InObject.modifiers.setSelectedGeomEdgesByNode #{} InObject;
InObject.modifiers.setSelectedGeomEdgesByNode #{bSEdges} InObject;
-- get the uv edges IDs of the currently selected edge
local bSCurrentUVEdges = copy ( ( InObject.modifiers.getSelectedEdgesByNode InObject ) as array ) #noMap;

-- check if the currently selected edge is one of the originally selected edges by
-- checking if the uv edge IDs match and add the edge ID then
if ( ( findItem bSOriginalUVEdges bSCurrentUVEdges ) != 0 ) then
(
OutEdges = append OutEdges bSEdges;

-- check if all original edges were found by selecting the OutEdges and comparing the count of the uv edge IDs count with the original
InObject.modifiers.setSelectedGeomEdgesByNode #{} InObject;
InObject.modifiers.setSelectedGeomEdgesByNode ( OutEdges as bitArray ) InObject;
local CompareCheck = copy ( ( InObject.modifiers.getSelectedEdgesByNode InObject ) as array ) #noMap;

if ( CompareCheck.count == bSOriginalUVEdges.count ) then
(
bSEdges = InCompareEdgesCount;
); -- end of check

); -- end of check

-- count on
bSEdges += 1;
); -- end of loop

-- return result
OutEdges;

); -- end of function


I hope it helps.
0 Likes
Message 11 of 12

Babas33340
Community Visitor
Community Visitor
someone found a "clean" workaround to that ?

Thanks
0 Likes
Message 12 of 12

Anonymous
Not applicable
I Myself am running into the same issue.
has anyone found a workaround or solution to the problem?

thanks.


is it hard to ask the mesh about its edge selection?
0 Likes