Jump to content

Polygon / Pivot Orient works with Copy, broken with Facet


Recommended Posts

Hi Everyone,

I am working on some assets that will be exported to 3DS max, in more details I have a piece of geometry and I use a facet node with the "unique points" option checked to separate each face, run a few ops on them and then export them.

After importing it in 3DS max I run a script that makes every face an instance to each other, and makes some transformations to keep them in position.

Here's the catch: when I do this with a model whose faces have been separated by the facet node, it doesn't work correctly (the faces rotate at a weird angle). If, instead, I usa a copy node and stamp some boxes on the points of the SAME geometry, it all works perfectly.

I believe the copy node does some automatic operations (I read something about the orient and up attributes) that corrects the orientation. I tried any sort of operation on normals with no luck - any clue about how I could make it work with the facet implementation as well?

post-8841-0-35627000-1382370949_thumb.pn

post-8841-0-86463300-1382370953_thumb.pn

Link to comment
Share on other sites

Not sure what do you do on those points, example file would help.

Copy sop reads attributes stored on points and uses them to construct transform matrix.

Copy sop works as follows:

Key:

O = orient matrix

S = scale matrix (scale * pscale)

L = alignment matrix (*)

R = rot matrix

T = trans matrix (trans + P)

(*) The alignment matrix (L) is defined by N or v and up.

IF N exists AND up exists and isn't {0,0,0}:

L = mlookatup(N,0,up)

ELSE IF N exists:

L = dihedral({0,0,1},N)

ELSE IF v exists AND up exists and isn't {0,0,0}:

L = mlookatup(v,0,up)

ELSE IF v exists:

L = dihedral({0,0,1},v)

END

IF orient exists:

Transform = O*R*S*T

ELSE:

Transform = S*L*R*T

END

  • Like 1
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...