MoI discussion forum
MoI discussion forum

Full Version: nodeeditor documentation

Show messages:  1-20  21-22

From: bemfarmer
2 Jan 2019   [#1]
After many drafts in Word, here is some documentation of Macros in nodeeditor.
- Brian

To be added to Docs:
Note, the order of the text lines can be changed by Max' addition a few years ago of the ability to Alt+Drag the input Dots in the Macro. (I had forgotten this.)

Attachments:
MACROS IN NODEEDITOR.zip


From: Frenchy Pilou (PILOU)
2 Jan 2019   [#2]
Excellent!
From: Barry-H
2 Jan 2019   [#3] In reply to [#1]
Great,
the more documentation on the functions of the node editor should encourage more people to use it.
Many thanks
Barry
From: Michael Gibson
2 Jan 2019   [#4] In reply to [#1]
Thanks Brian - I added a link to your post on the Wiki here: http://moi3d.com/wiki/Nodeeditor#Macro

- Michael
From: bemfarmer
2 Jan 2019   [#5] In reply to [#4]
Thank you Michael, and everyone for the encouragement.

The ordering of the input slots of a Macro in module view, from top to bottom, is currently determined by the order in which progenitor input nodes are created or copy/pasted. Maybe MaxS could provide a way to change the order of the input slots?

(Similarly for output slots.)

Currently, to re-order the slots, to "move" a slot down, it must be re-created or copy/pasted, and then be wired in the same, then removing the slot that need to be lower down...

Ctrl+Left Click on any node results in a copy of the node.

- Brian
From: bemfarmer
3 Jan 2019   [#6]
Two page Consolidated Node Selection Menus, for printing and reference.
Node selection menus are shown for the Categories of nodes.
(.zip file is only slightly smaller.)

Word .docx files are available, if anyone is interested.
To get pictures side by side in Word, check the picture vs words icon with only 2 blue lines, in Word 365.
Word is becoming easier to use, but is still awkward. Adobe FrameMaker is the creme de la creme, but is too expensive to justify...

I'm using SnagIt 13 and PhotoScapeX for additional cropping.

- Brian

Attachments:
ConsolidatedNodeSelectionMenus2019.pdf


From: Max Smirnov (SMIRNOV)
5 Jan 2019   [#7] In reply to [#5]
Hi Brian,
thank you for this documentation. Great!

>>Maybe MaxS could provide a way to change the order of the input slots?
This feature was in my todo list for a long time :) And finally I made it today.
You can download updated version from my site:
http://moi.maxsm.net/files/nodeeditor/ne.swap.macro.io2.zip

Now you can rearrange inputs and outputs of any macro node. Hold Alt(Option) key and drag input/output dot.

I didn't test it well, so there can be some bugs.


P.S. file updated (bug fixed)
From: Frenchy Pilou (PILOU)
5 Jan 2019   [#8]
You are champions!
From: bemfarmer
5 Jan 2019   [#9] In reply to [#7]
Hi Max,

Thank you for the two upgrades to Nodeeditor!


Alt key on pc keyboard, Option key on mac keyboard.

Alt (Left Mouse button) Drag of Dot works ONLY for a Macro in its modular display. It also works for another Macro inside of a Macro.
Their Input Dots may be re-ordered, or their output Dots may be re-ordered.
(By design, there is no Dot dragging of Input/Output slots in regular nodes.

Copy of nodes is now working between all node canvases.

(Tested with MoI_v4Beta)
- Brian
From: bemfarmer
10 Jan 2019   [#10]
With limited space, I'll post this documentation for Points (Array) node, and MathPts node for a while, and plan on incorporating it to the wiki documentation.
It took a while to understand what the two nodes do, and how they work.
- Brian

Attachments:
Points Array Node and MathPts Node.pdf


From: bemfarmer
10 Jan 2019   [#11] In reply to [#10]
Some documentation on Datatypes, with the same caveats as the previous post.
- Brian

Attachments:
Datatypes.pdf


From: bemfarmer
11 Jan 2019   [#12]
HexFlatGrid2Demo.nod is attached. It was finally possible to use only one mathPts node.
More was learned about how the mathPts node works, as shown in the pdf...

- Brian

Attachments:
HexFlatGrid2 Documentation.pdf
HexFlatGrid2Demo.zip


From: bemfarmer
12 Jan 2019   [#13] In reply to [#12]
Here is the Kagome.nod file.

Reference:
https://en.wikipedia.org/wiki/Trihexagonal_tiling

This node is similar to the HexFlatGridDemo.nod, with some different increments and different offsets.
Less that 2 rows does not work properly, due to the trick recovery of du for an integer array index for "v" resulting in division by zero, when rows = 1.
Note that the trick formula for recovering the array of "u" values should have +Umin added, and the integer array formula should be
(u-Umin)/du. (Correspondingly for dv and Vmin in the Kagome.nod, for row offset.) The formula in the HexFlatGridDemo ommited the Umin, as Umin=0 in that case.
(Similarly the HexFlatGridDemo does not work for less than 2 columns.)
(The triangles have not been done.)

It would be helpful to have an i integer array variable available for "u" values, and a j integer array variable for "v" values, in the mathPts array, and points array.
But this might be too complicated? And some abcd multiple array values?

- Brian

Attachments:
Kagome2.zip


From: bemfarmer
13 Jan 2019   [#14]
In math node and in mathPts node, formulas, cos(a) does NOT equal cos[a].
sqrt(b) does NOT equal sqrt[b].
() yields the correct number.
[] yields the wrong number.
- Brian

(Now my .nod produces the correct geometry)
From: bemfarmer
16 Jan 2019   [#15]
A quick couple of questions:
My current .nod assembly requires input of many lines. Each line is to be converted to many pointarray points.
The points in each cluster of points are to be manipulated, and the new cluster of points is to be turned into a curve, mode interpcurve.
The problem is that interpcurve chains all of the point clusters together, but the desired result is that each cluster should be a separate curve.
Is there any separator or clustering mechanism in pointarray?

indexSelect node could grab a cluster, but each successive cluster still needs to be processed separately.

I thought that each line could be turned into a straight polyline. The polyline would be considered to be a cluster of points.
Points in the polyline would be manipulated and converted into a new polyline object.
Turning the new polyline into an interpcurve would require a new version of Curve node, with a polyline object input.
Each polyline object input would have to be converted to a separate interpcurve.

The other question is whether concat and concat2 are the same.
BatchPts and concatPts seem to do the same thing?
EDIT, 3/12/2022, thats bundlePts. (bundlePts was superceded by bundleArray in Points mode.)

- Brian
From: Karsten (KMRQUS)
16 Jan 2019   [#16] In reply to [#15]
Hello Brian,

you can manipulate the pointarrays by using a combination of split points and point ext. Here you can insert other values for the xlength, ylength and zlength - inner organization of pointarrays. I've attached an example.

>>>>The other question is whether concat and concat2 are the same.
Concat2 was created as a time were the concat command was splitted in seperate nodes for numarray pointarray and objects. Max has them joint together also - the only difference today is the maximum number of inputs and the naming of them.

>>>>BatchPts and concatPts seem to do the same thing?
I think you mean bundlePts vs. Concat in Point mode. the difference is in the order. Concat takes a pointarray and adds a second one. BundlePts takes the first point of the first pointarray and than the first point of the second pointarray and places them to the output array - and so on. So you can create e.g. points on different curves, bundle them and draw new curves across the base curves.

Have a nice day
Karsten

p.s.: If you want to use curve instead of convertPts you have to set zlength and xlength in the pointExt node;-)

Attachments:
test.nod


From: Karsten (KMRQUS)
16 Jan 2019   [#17] In reply to [#16]
And a demo of bundlePts

3 Lines with points on them

bundled and curves over the result

Attachments:
bundlePts.nod


From: bemfarmer
16 Jan 2019   [#18] In reply to [#17]
Hi Karsten,
Thank you very much for all of the information and examples.

- Brian
From: bemfarmer
18 Jan 2019   [#19]
PointArray Documentation and Parsing to Clusters

This post is a request for clarification, and a preliminary attempt to document the PointArray, and a request for clarification of the length parameters, etc..
It is also a suggestion for a new “Parsing” node.

So far, for myself, the (inner organization) data structure of the PointArray, and the separation of a pointarray into clusters, and superclusters of points is not clear, nor intuitive as to how to do it. Karsten has described the SplitPts node and the PointsExt node which are helpful. The last 3 entries of the ArrayLogger node are the xlength, ylength and zlength.

The points in a pointarray are more than just raw points coordinates of (x, y, z).
Seven of the 10 properties of the pointarray are pt.x, pt.y, pt.z, Rx, Ry, Rz, and Scale.
Somehow Frame fits in here?
And what is the purpose of Scale. How, where, and when does it cause Scaling?

The other 3 properties are:

The xlength is ? The number of points in a cluster? Starts at 100, and divided down to 20 in Karsten’s example.
xlength is rounded in some way to an integer.

The ylength is ? The number of clusters? (5 in Karsten’s example.)
Tells Ucurve to start or stop?
If the number of points does not divide evenly, some points are used twice?

The zlength is ? Some other index???

The “Parsing” node would have:
Input for a PointArray. (100 elements)
Input for the number of points in a cluster. (xlength?)
Input for the number of clusters. (supercluster?)
Input for grouping several clusters. (supersupercluster?)
Output a pointarray which the convertpts node, or the curve node will create separate curves for.
Another node which will group separate curves together according to the supercluster number…?

The points in an objectarray are MoI3D geometric, displayable entities. They are much more than a raw point,
and are different than a pointarray.

- Brian

I tried using some hex polygons as input, with strange results. I want to map the sides to curves...and recombine...
From: Karsten (KMRQUS)
18 Jan 2019   [#20] In reply to [#19]
Hello Brian,

at first - yes it's a frame description:
x,y,z, Euler-angles (x,y,z by using rotation order x,y,z), scale mostly 1 (useful for some programming - can be used as scale factor or for transformation proposes (homogenous coordinates).

The x-length, y- length, z-length is an organizations structure. For most of the things one value would be enough, but if you have a look to the points node it organizes the output in rows, columns and levels. Depending on the node that gets the info the processing can be differ. Please have a look to the points node with the unum, vnum and wnum values that set exactly the values in the pointarray at the output. The convertPts in U-Mode uses xlength as the number of points for a curve and ylength*zlength=number of curves. In W-Mode it uses the y length for the number of points and xlength*zlength = number of curves. The curve node takes x-length as the number of points for a curve and zlength for the number of curves. Typically these details should be hidden for the user, but sometimes you need them for special things. Please play with this node and look to the results and the array logger.

I hope that brings a little bit light to the tunnel.

Have a nice weekend
Karsten

Show messages:  1-20  21-22