XYZ coords of a plane – MEL ?

Hello, simple description:

Imagine you had a plane and it was subdivided x & y by arbitrary amounts – you then animated this plane through maya 3D space over time:

How can I get Maya to output a file (.txt .xml or .tiff even) that gives each subdivisions centre point on the planes position in 3D space ?

Slightly more detailed description>> So imagine a square plane 2×2 units large created flat centred at the origin was subdivided by 2 in each x and y so it was now defined by 4 1×1 squares. The planes top left subdivided square would have a centre at -0.5, 0, -0.5 (XYZ) (the original top left that is, it is free to rotate or move however and no longer be ‘top left’).

So my text file for this first frame would be:

-0.5, 0, -0.5 (top left)
0.5, 0, -0.5 (top right)
-0.5, 0, 0.5 (bot left)
0.5, 0, 0.5 (bot right)

and if I were to move the subdivided square – I dunno, pivot 90deg around its ‘top’ edge so it was standing up the next output would be:

-0.5, 0.5, 1 (top left)
0.5, 0.5, 1 (top right)
-0.5, 1.5, 1 (bot left)
0.5, 1.5, 1 (bot right)

You’ll notice I used a typical scheme where you read from top left to right then down to bot right and had the x y z values tab delimited and the subdivision position line delimited. This is just an example (I got hose numbers just by eyeballing it).

I’d want much more subdivisions in reality and deform the plane also, importantly:

Could it be done with an nCloth ??

I may as well be a complete beginner with maya and programming, but have a little experience in both a long while ago, should with a struggle be able to nut it out :wip: , but any hints or similar programming re. this kind of carry on would be *greatly appreciated*

MEL ?? possibly within the app UI itself ?

:thanks:
:splat:

No Responses to “XYZ coords of a plane – MEL ?”

Post a Comment