[Plugin] Create 3d mesh from construction points... ver 1.0
-
Hi Kirill,
Maybe a progress bar would be handy, because when generating a 20x20 mesh or higher takes a long time.
I've PM'ed you a version of your script with Todd's progress bar class (renamed to avoid any conflict with other scripts ). It is based on the "m" size of mesh, that's-to-say if you select a 20x10 mesh, you'll get 5% by 5% progress numbers in the status bar.
Of course feel free to keep it or delete it, but users may think SU is frozen when creating big meshes .
Another question: is it due to the "z" calculation formula that the mesh doesn't "stick" to the construction points exactly ? or did I miss something ?
Best regards, -
Thanks for feedback! Especially for progressbar, of course I keep it
Didier, you did not miss about exactness... As I mentioned in description, plugin creates only approximate 3d mesh surface and it is really due to the "z" calculation formula.
I'm going to make it more accurate. I just need to adapt cumulative mesh length minimization algorithm from another project (more info: http://lss2008.livejournal.com/9938.html). Of course, it will take a little time -
-
This is very impressive, thank you very much!
-
Maybe a roadkill bunny that got squashed by a truck, so all its z values are the same?
Chris
-
@chris fullmer said:
Maybe a roadkill bunny that got squashed by a truck, so all its z values are the same?
Chris
Well... Actually a rectangular (not necessary flat) bunny would be more suitable, I guess .
The initial 6000 points girl:
Failed 'pnts2mesh.rb' test:
Only rectangular hat is more or less succesful:
Well, the current algorithm is better when you've got few construction points and need to obtain a smooth rectangular piece of terrain (similar to the sandbox tool).
The plugin treats each construction point as a local extremum of the result surface.
If the points cloud is quite dense, then Constrained Delaunay Triangulation (CDT) is more proper choice. -
Hi, kirill2008:
Thank you for this timely and very useful plugin.
I am in the process of using it for a site topo.
I hope you can refine the z precision. Currently, I am correcting z's by moving the geometry one by one. This probably affects the local surrounding slopes and elevations and produces a surface no more accurate than leaving the z's alone.You mentioned the Constrained Delaunay Triangulation. Is this available for use in Sketchup 6 or 7 through the User Interface?
Thanks once again.
mitcorb -
Hi Mitcorb,
You could either use points_cloud_triangulation (if you already have the points imported) or Cloud_V6 (if you "only" have the xyz data). Practically, both use the same (Delaunay) triangulation method - at least as far as I know.
-
Thanks, Gaieus
I will give these a look.
I salute you for your tireless efforts.
mitcorb -
@mitcorb said:
Currently, I am correcting z's by moving the geometry one by one.
OMG, it's no good... I'll try to fix z calculation as soon as possible. But I guess you need to try alternative terrain generation tools also, because I doubt whether little (btw, experimental) plugin has enough power to perform complex topo site work.
@mitcorb said:
You mentioned the Constrained Delaunay Triangulation. Is this available for use in Sketchup 6 or 7 through the User Interface?
Yes it is available. If you have terrain contours (horizontals), then you may try to generate triangulated surface from contours. It is one of "Sand box tool" (built-in) possibilities.
-
@jim said:
Need a test model?
I'm afraid 'pnts2mesh.rb' will fail in such test
You see, plugin creates only rectangular 3d mesh and calculates only one z level for each x,y position. It has no enough power to process a bunny -
OK, thanks.
I did not realize that Sketchup was already using these concepts in its standard tools.
That is what is so good about this forum.By the way, I am merely experimenting with the plugin and I do realize that the original intention of Sketchup was to be a "quick" vizualization tool. Actually, doing the tedious knitting to tweak a model is a learning process in itself, and having gone through the process, I feel that my learning curve is beginning to level out a bit, as far as modeling goes. (still much to learn about ruby and rendering)
Thanks again, I am having fun.
mitcorb -
@mitcorb said:
That is what is so good about this forum.
I agreee. This forum keeps very friendly atmosphere as well and it's great and positive.
Advertisement