PointPicker scripting
All  1-5  6-7

Previous
Next
 From:  Michael Gibson
10802.6 In reply to 10802.5 
Hi Brian,

re:
> So I can either convert cPlane1 to cPlane2 with a new base point, which I still do not know how to do.?

I'm a little confused by your question, are you maybe getting the "base point" for the pointpicker mixed up with the origin point of a MoiCoordinateFrame object? Those are different things.

You can set the origin of a MoiCoordinateFrame object like this:
cPlane2.origin = pt;


> Or else, I can open a 2nd pointpicker, and feed the new base point to it by script, not by manual pick,
> and get the cPlane2 from the second pointpicker.ptframe.?

I may need you to describe a little more about what you're trying to do with cPlane2.

Is the confusing part maybe that you're trying to use cPlane1 and cPlane2 for separate things but they are both referring to the same MoiCoordinateFrame object?

If you want an independent frame try creating a new one using:

var cPlane2 = moi.vectorMath.createFrame();

cPlane2.xaxis = cPlane1.xaxis;
cPlane2.yaxis = cPlane1.yaxis;
cPlane2.zaxis = cPlane1.zaxis;
cPlane2.origin = pt;

- Michael
  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:  bemfarmer
10802.7 In reply to 10802.6 
Thank you Michael,

I have been a lot confused.

But your last response about "If you want an independent frame try creating a new one using:"
is exactly what I need for the script!

So the cPlane1.xaxis; and cPlane1.yaxis; and cPlane1.zaxis; are not locked to a specific point in 3D space, because they are Vectors,
but they commonly are thought of as emanating from the local Origin, which is located at the world coordinate point pt.
And the three axes do correspond with the grid axes of the particular View, so the 2D points, (or possibly 3D points), can be plotted.
The world coordinate point pt, will establish the local Origin of the frame. The local Origin point is ( 0, 0, 0 )

My cPlane2 origin will be in a different location than the cPlane1 origin.

Again,
Thank you very much.

- Brian

I should not have been talking about BasePt, when I should have meant origin point.
  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: All  1-5  6-7