How to get global positions of points?

Topics concerning ICE & Math
Post Reply
dox
Posts: 3
Joined: 26 Jan 2014, 16:59

How to get global positions of points?

Post by dox » 26 Jan 2014, 20:11

Hi folks,

I'm currently working on a script to collect global positions of points from a selected mesh.
That works as long as I don't rotate two or three axes of the mesh. After some stressful hours I got to know about ICE and thought it might be an alternative.

In these green boxes are the local vertex positions... (img1) On the autodesk documentations sites is written that local values can be converted to global ones but I couldn't make it work. (img2)

Can someone help me figuring this out?

gotchee
Posts: 21
Joined: 08 Jul 2010, 19:52
Location: Hamburg, Germany

Re: How to get global positions of points?

Post by gotchee » 26 Jan 2014, 20:25

Hi,

the use of "multiply Vector by Matrix" is right. Now you just need to show the values after the multiply-Node and you should see the global positions.

And if you just need to get the global point positions of an object, your ICE tree could be much simpler.

Cheers

dox
Posts: 3
Joined: 26 Jan 2014, 16:59

Re: How to get global positions of points?

Post by dox » 26 Jan 2014, 20:51

you just need to show the values after the multiply-Node
Seriously, I'm newbe. I don't know how to do that.
I made a "green V" on the yellow line after the multiply-Node but that didn't show the values.

gotchee
Posts: 21
Joined: 08 Jul 2010, 19:52
Location: Hamburg, Germany

Re: How to get global positions of points?

Post by gotchee » 26 Jan 2014, 21:17

Ok sorry :ymblushing:
Just make a "V" on the yellow line after the "Multiply Vector by Matrix"-Node by rightclicking on it and then choosing "Show values" (or somerhing in the like)
Also rightclick on the first "V" and choose "hide values".

Now you should see the global position displayed in the viewport.

dox
Posts: 3
Joined: 26 Jan 2014, 16:59

Re: How to get global positions of points?

Post by dox » 26 Jan 2014, 21:45

Edit:
Ups, I forgot the .kine.global.
Still no global value and the mesh is deformed.

img

gotchee
Posts: 21
Joined: 08 Jul 2010, 19:52
Location: Hamburg, Germany

Re: How to get global positions of points?

Post by gotchee » 26 Jan 2014, 22:28

I'm not in front of a softimage right now, so let me build you a theoretical tree.
I think your tree doesn't show the right values, because you are using the "Get closest location"-Node in a wrong context. You would need that node for example in cases where you need to look for data on a different object than itself etc.
Nevertheless, here is the tree:

Two Get Data-nodes, one Multiply Vector by Matrix, one Set Data
self.pointpoisition--->plug this into the Vector port of the Multiply by matrix
self.kine.global------>plug this into the Matrix port of the Multiply by matrix
Connect the output of the Multiply by matrix to the Set Data node and enter something like self.MyCustomData in the Set Data node.
Now rightclick on the connection between the multply vector by matrix node and the set data and select "Show Values". Set the show values option to numeric and you should see the global point position.

Hope this helps.

User avatar
probiner
Posts: 127
Joined: 17 Apr 2013, 11:52

Re: How to get global positions of points?

Post by probiner » 26 Jan 2014, 23:12

I'm finishing my compound on this matter that I have been working on the past couple of weeks. Will release it next week if I don't break a leg or I don't have "homework" :P
Looking like this:

Image

Right now I would just like to make a compound mask for it for more simple presentation for routine'ish operations and to have it output the final filtered matrix, not just the multiplied vectors, as I expose here: http://www.si-community.com/community/v ... =15&t=4800

I've been working on it so it handles a broad range of routines I'll be facing more and more to achieve mesh deformations.

Cheers

Post Reply

Who is online

Users browsing this forum: No registered users and 15 guests