Show messages:
1-10
…
1391-1410
1411-1430
1431-1450
1451-1470
1471-1490
1491-1510
1511-1530
…
1851-1859
Thread Split: Some posts in this thread have been moved here
From: bemfarmer
Alert messages were added to see what is going on, or not going on.
I left off the () for getStartPt()...
- Brian
From: bemfarmer
Here is an early beta version, which actually works in the xy plane, for 3+ planar poly objects.
Further testing needed.
Test 2D polys in 3D space, Poly triangles of portion of an icosahedron, is working.
Copy CentroidNode.js to nodeeditor\nodes\extensions folder.
For Testing, open Ico5Poly.3dm, of color Orange.
Also Load PolyCentroidNodeTest3.nod into nodeeditor, or some other test .nod, and Run it.
The extra point at the origin is to be investigated. EDIT, the pointarray centroidPt (pink node dot and pink wiring), is defective. (Should not be curve mode either.)
- Brian
Earlier a strange effect occurred. An icosahedron was loaded from Obj Library. 15 edges of 5 side faces were joined to form 5 polygons. Did a 2X scale of, and moved, the "Ico5Poly"
Icosahedron was deleted.
Running the CentroidNode found the centers of the Ico5Poly, But strangely also caused the orange icosahedron to re-appear.
Edit: See post 1456 for beta3.
Attachments:
IcosahedronPolyPortionTest.zip
Message 7777.1453 was deleted
From: bemfarmer
Thank you James.
It is easy enough to modify CentroidNode.js to load in the Points2 menu,
or else to just copy paste the code to the Points2 menu, minus a very few characters at beginning and end of CentroidNode.js.
I'm not sure how easy it is to convert from faces to polygon outline with miscellaneous nodes. Or if the CentroidNode should have face to edges to polygon feature added, along
with the next MoI Beta, pending Michaels upcoming surface.isPlanar property, as per previous posts.
The pink centroidPt output is still broken...AFAIK.
The script has barely been tested...
Might as well add circle and ellipse?
- Brian
Integration for closed curves centroids is still a dream:-)
From: James (JFH)
Brian,
>> Might as well add circle and ellipse?.....
Integration for closed curves centroids is still a dream:-) <<
Centroid for these shapes can be can be found by using subD/convertCurveToPoly node
before centroid node. Obviously the higher the "Div Profile" the more accurate.
For circles, any even number (except 0) input to "Div Profile" will give true centre.
For now I think your work is done here. I'd just remove centroidPt output socket.
I'm not saying it is not worth spending any more time on it, just that it good enough for now.
If you are keen to keep coding, in term of outcomes it would be better to investigate other possible nodes.
To this end, I have a suggestion, if you are interested: FATLINES.
A Fatlines node analogous to Max's scripts of the same name would be a real boon IMHO to NE.
Think islamic patterns, for example. Anyway its just a thought.
James
https://www.instagram.com/nodeology/Image Attachments:
closedCurves.gif
From: bemfarmer
CentroidNodeBeta003
The file is still in its own .js node wrapper, but has been moved to the Points2 menu. (not the Points2.js file, which could/should be done.)
So after placing beta003 in the extensions folder, if the node appears red in your .nod program, replace the node with the one from the Points2 menu.
Also fixed the raw centroid point(s) output (Pink) with the proper code, as shown in Objects.js/ObjtoArray node. (output2.pushPoint(cPtObj.item(0).pt);)
(Just use either the centroidObj point output, or the pink output, to avoid duplicate points...)
Note that Max's cVolume2 script finds centers of gravity for one extruded closed planar object, including extruded curved closed planar objects.
It seems to be a very long script.
Will look at FatLines.
- Brian
Attachments:
CentroidNodeBeta003.zip
PolyCentroidNodeTest4.zip
From: James (JFH)
Just for a bit of Conic Relief
Node circuitry images post to:
https://www.instagram.com/nodeology/
James
NE folder can be found here:
http://moi3d.com/forum/index.php?webtag=MOI&msg=9358.1Attachments:
ConicRelief.nod
Image Attachments:
ConicRelief.jpg
From: Frenchy Pilou (PILOU)
Cool image for Bees! (and for enlight users about subject of Nodes ! ;)
Sorry I have no times for the moment manage all nodes for a years! :(
From: bemfarmer
Hi James,
Do you have a link to "WaveSurf"?
For your old ProjectSurf.nod, replacing red Project node with Construct1/ProjectMP enabled the .nod to run.
- Brian
Your old paraSurf.nod has a couple of red nodes...in the copy I have.
From: James (JFH)
Brian,
>> Do you have a link to "WaveSurf"? <<
"WaveSurf" is a macro. I have attached nod file to previous post, so macro can be found within.
I had not included before, because there was nothing really new here in terms of technique. It was done specifically to post to instagram, to keep the page fresh.>> Your old ProjectSurf.nod....[&]....paraSurf.nod has a couple of red nodes..<<
All these macro need to be reworked. I don't know that any of them are worthy of dissemination. I only used "WaveSurf" and "B-Hive Grid" for that matter, due to laziness.
,>> Will look at FatLines. <<
Did you get a chance to study Max's script?
Anyway, keep up the good work
James
https://www.instagram.com/nodeology/
From: bemfarmer
James, thank you for WaveSurf macro.
I've looked at FatLines a little, and spread out, to line items, the functions shown scrunched into condensed paragraphs.
I see offset or flow, boolean union, scale1d, and still have to "decipher"/"understand" Max's code. :-)
Max is such a skilled programmer! There seems to be a lot going on...
I think that I will start converting bits of the code..., and fill in gaps in understanding...
- Brian
Message 7777.1462 was deleted
From: Frenchy Pilou (PILOU)
Cool !
I suppose you know that :
https://www.etereaestudios.com/docs_html/isfahan_htm/isfahan_index.htm
and this facinated site!
http://www.tamabi.ac.jp/idd/shiro/muqarnas/default.htm
and other cool things
https://www.ics.uci.edu/~eppstein/junkyard/penrose.html
http://www.dartmouth.edu/~matc/math5.pattern/syllabus.html (Click Art Part section)
http://www.protozone.net/AJinteractives1.html
From: James (JFH)
I was inspired by this image (top) to see if I could generate a buildable structure in NE.
All the plank elements are indeed straight (ie the bow from flow to surface has been removed).
However it is not quite there yet, because the plank thickness varies. They will need to be uniform thickness to make structure fabrication viable. Anyway it is a start.
James
https://www.instagram.com/nodeology/
NE folder can be found here:
http://moi3d.com/forum/index.php?webtag=MOI&msg=9358.1Attachments:
hexPav.nod
Image Attachments:
hexPav.jpg
From: Anthony (PROP_DESIGN)
wow very cool, useful, and ambitious. I hope you figure it out. Certainly a challenge.
From: Frenchy Pilou (PILOU)
Cool start! :)
From: mkdm
Wonderful job James!!
Congrats!
Message 7777.1468 was deleted
From: speedy (AL2000)
Hi everyone, and in particular Brian
Attached the file in which the Centroid tool
does not give the expected result ... maybe it will be
the case to consider well what this malfunction derives ...
Logically, when you have time, and if you want to do it
every tool we put at our disposal is a gift ...
"few words to the wise"
file at this link:
http://www.mediafire.com/file/oq4olj4yz9ame4y/FelixCandela.zip/file
have nice day to all
al
From: bemfarmer
Hi Speedy,
For the center 16 triangles, the centroid point is being found.
The remaining 32, 4 sided closed curves are not planar. This centroid node works for planar polygons.
(The Planar command does not work on the 32, 4 sided closed curves either.)
The center of mass of half of a solid sphere is at 3/8 of the distance from the sphere's center to the hemisphere's pole, as shown by Max's cVolume2.
For a hollow hemisphere, the distance is 1/2.
https://en.wikipedia.org/wiki/Centroid
The centroid node does not work for hemispheres either.
Wolfram gives a formula for center of mass for spherical caps.
Also Wolfram gives a formula for the centroid of a quadrilateral as the midpoint of the line between the midpoints of the diagonals.
Or "The centroid of the vertices of a quadrilateral occurs at the point of intersection of the bimedians."
http://mathworld.wolfram.com/GeometricCentroid.html
(Usually I find Wolfram math difficult to understand, and do not plan on doing integrals:-)
So the centroid for quadrilaterals, (4 line segments forming a closed quad), planar or non-planar, could be easily calculated.
The closed quads could be tested for planarity (somehow), and the calculation added to the centroid node. (I think.)
Is there a MoI method to test for planarity?
- Brian
Show messages:
1-10
…
1391-1410
1411-1430
1431-1450
1451-1470
1471-1490
1491-1510
1511-1530
…
1851-1859