General technical questions about v3 Moi's API
 1-2  3-22  23-26

Previous
Next
 From:  mkdm
8010.23 In reply to 8010.22 
Hi Michael,

Thank you very much for these clarifications.

Have a nice day.

- Marco (mkdm).
  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged

Previous
Next
 From:  Mindset (IGNITER)
8010.24 In reply to 8010.20 
> factory.generateVertices();
> var corners = factory.getCreatedObjects();

How can I get the x,y coordinates of a corner?

var factory = moi.command.createFactory( 'fillet' );
factory.setInput( 0, objlist );
factory.generateVertices();
var points = factory.getCreatedObjects();
factory.cancel();
for ( var j = 0; j < points.length; j++ )
{
var pnt = points.item(j);

moi.ui.alert( "pnt = " + pnt);


moi.ui.alert( "pnt.x = " + pnt.x);


moi.ui.alert( "pnt.y = " + pnt.y);


}

___________

I tried to treat it as an array as well... no luck so far.

Thanks,
-- Mindset

  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged

Previous
Next
 From:  Karsten (KMRQUS)
8010.25 In reply to 8010.24 
Hello Mindset,

try something like this: points.item(i).pt.x
pt is a mathPoint (moi.VectorMath.createPoint())

var pnt = points.item(j); gives you an PointObject (visible Object like a line or a cube) that has a mathpoint inside:-) the mathpoint has x,y,z

I hope that helps.

Have a nice day
-Karsten
  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged

Previous
 From:  Mindset (IGNITER)
8010.26 In reply to 8010.25 
Wunderbar!
Du bist eine kräftige Stimme

THANK YOU very much, Kersten.
-- Mindset
  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged
 

Reply to All Reply to All

 

 
 
Show messages:  1-2  3-22  23-26