v1.5
modeling drawing
Adds an edge between an existing point and a "virtual" point somewhere on an edge. This command can only be called
after the SplitEdge command.
Note: This command uses output arguments. C# and some
scripting languages (such as JScript, PerlScript and Python) don't support arguments passed by reference. Normally
you can get the output arguments via either XSIApplication.ExecuteCommand method (C#) or the
ISIVTCollection (scripting languages), but this command
already returns a value.
The only available workaround in this case is to create a VBScript custom command which returns both the output
arguments and the return value in one array. For details, see
What Happens when the Function Already Returns a Value?.
oLong = AddEdge( [ConnectionSet], [Ratio], [ImmediateMode], [NewPointID], [NewEdgeID] ); |
Returns the ID of the new point created by the operation as a Long (or existing point if ratio=0 or 100)
Parameter | Type | Description | ||||||||
---|---|---|---|---|---|---|---|---|---|---|
ConnectionSet | ConnectionSet |
Specifies the point and the edge (two elements, in that order) to connect. Default Value:
Currently selected components are used. |
||||||||
Ratio | Double |
ratio where to split the input edge
|
||||||||
ImmediateMode | siOperationMode |
Specifies whether or not the operator should be immediately frozen. Default Value: siPersistentOperation |
||||||||
NewPointID | Integer | ID of the new point created by the operation (or existing point if ratio=0 or 100) | ||||||||
NewEdgeID | Integer | ID of the new edge created by the operation |
' Create a cylinder and add an edge loop around the top half of the cylinder CreatePrim "Cylinder", "MeshSurface" SplitEdge "cylinder.edge[11]", 58.529, False, True AddEdge "cylinder.pnt[42];cylinder.edge[9]", 52.338, True AddEdge "cylinder.pnt[43];cylinder.edge[23]", 31.911, True AddEdge "cylinder.pnt[44];cylinder.edge[34]", 50.164, True AddEdge "cylinder.pnt[45];cylinder.edge[45]", 38.716, True AddEdge "cylinder.pnt[46];cylinder.edge[56]", 37.706, True AddEdge "cylinder.pnt[47];cylinder.edge[67]", 54.800, True AddEdge "cylinder.pnt[48];cylinder.edge[78]", 27.452, True AddEdge "cylinder.pnt[LAST];cylinder.edge[90]", 0.000, True |