• Login
sketchucation logo sketchucation
  • Login
🤑 SketchPlus 1.3 | 44 Tools for $15 until June 20th Buy Now

[Plugin] QHull

Scheduled Pinned Locked Moved Plugins
51 Posts 20 Posters 53.7k Views 20 Watching
Loading More Posts
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • C Offline
    craigbic
    last edited by 14 May 2009, 11:41

    YES!!!! I have been really.....really....REALLY needing this lately! I can't wait to try this as soon as I am done writing this reply. I'll let you know how it goes.

    @unknownuser said:

    Can someone enlighten me, please? What it the purpose of having such a random geometry?

    Tomasz,

    I wouldn't call it "random geometry" as the "randomness" would depend on the point cloud used as the basis for the Voronoi diagram but rather call it "mathematically generated geometry". 3D Voronoi structures (2D Voronoi diagrams aside) are used in cellular-level research, bone fatigue studies, and experimental cellular architecture.

    Checkout the Sketchup Graphics Blog at http://sketchupgraphics.com

    1 Reply Last reply Reply Quote 0
    • C Offline
      craigbic
      last edited by 14 May 2009, 13:15

      Well, there are a few snags but I am still VERY pleased with this large chunk of progress. Kudus, avariant! This is a major step forward in the Qhull/Voronoi plugin development.

      Has ANYBODY been able to get the "selection" versions of Voronoi, convex, Delaunay, or half working at all? I have been unable to do so under any circumstance regardless of point cloud size or attitude in SU6. I use SU6 at work and SU7 at home so I haven't tried it in SU7 yet. I generated lsystem point clouds of various sizes and was totally unable to get them to work. Then I tried various hand-made point clouds, ones generated from sandbox meshes, and even point clouds generated from 2D Voronoi diagrams and all did not work (see error message pic).

      On the positive side, all of the operations based on points generated by rbox work just fine and it is really nice to have them working within SU! I guess for now, to generate 3D Voronoi geometry from my own points, I'll have to follow my own procedure as outlined in this post

      I feel like we're almost there and it will only take a slight nudge to get this totally working.....I am still quite excited about this.


      lsystem point cloud


      Error message I get when using a selection of points

      Checkout the Sketchup Graphics Blog at http://sketchupgraphics.com

      1 Reply Last reply Reply Quote 0
      • P Offline
        pilou
        last edited by 14 May 2009, 13:44

        @unknownuser said:

        Has ANYBODY been able to get the "selection" versions of Voronoi, convex, Delaunay, or half working at all?

        In fact yes ☀
        You must make a group before launch the Qhull plug 😉
        Half works also but result is like 111 pixel at the origin so you must rescale the result 🤓

        For your points I don't know yet but I suppose if you make a group maybe that works too 😉


        voro2.jpg

        Frenchy Pilou
        Is beautiful that please without concept!
        My Little site :)

        1 Reply Last reply Reply Quote 0
        • A Offline
          avariant
          last edited by 14 May 2009, 13:50

          OOOhhhhh.... oversight on my part!

          When examining the standard SU 'model', there usually aren't construction points. Everything is edges and faces. So, I just search for all the edges and use the starting vertex for each edge (to avoid duplicate points, I don't use the end). It never occurred to me to also search for construction points, but I can see how that would be useful!

          To see how the selection part works now, create a random convex shape. Then select the component, and do voronoi on selection. There you will see how it works. In the meantime, I'll update it to capture construction points also.

          As far as purpose.... well... it's artistic, right? 😆
          Actually, convex hull can have a legitimate purpose. If you have a complex model, do a convex hull selection on it, you'll get a sort of 'shrink wrap' shell of the entire model. I'm sure the others have legitimate purposes too. 😉

          1 Reply Last reply Reply Quote 0
          • A Offline
            avariant
            last edited by 14 May 2009, 14:26

            Add the actual plugin! (D'oh)

            EDIT: Updated to work for SU6
            EDIT 5/14/2009: Updated to work with ConstructionPoints


            QHull.zip

            1 Reply Last reply Reply Quote 0
            • A Offline
              avariant
              last edited by 14 May 2009, 14:27

              Fixed for using Construction Points.

              1 Reply Last reply Reply Quote 0
              • W Offline
                watkins
                last edited by 14 May 2009, 16:37

                A tutorial or two to demonstrate how to use this plugin would be nice.

                Regards,
                Bob

                1 Reply Last reply Reply Quote 0
                • C Offline
                  craigbic
                  last edited by 14 May 2009, 19:19

                  YES...YES.....YES!!!!! Everyhing is working now! Thank you especially for the update for use with construction points. I tried every variant I could think of, lsystem point clouds, sandbox mesh grids, convex geometry groups....it all worked.....flawlessly! It took awhile but as I told other members in other related posts.....somebody in this terrific community forum will come in and save the day!

                  Thank you avariant!!! 😄

                  Checkout the Sketchup Graphics Blog at http://sketchupgraphics.com

                  1 Reply Last reply Reply Quote 0
                  • A Offline
                    avariant
                    last edited by 14 May 2009, 19:30

                    My pleasure. It was fun, and I've always been a fan of the 3D Voronoi shapes. 😄

                    1 Reply Last reply Reply Quote 0
                    • MALAISEM Offline
                      MALAISE
                      last edited by 18 May 2009, 09:10

                      👍 👍 😄 👍

                      MALAISE

                      La Connaissance n'a de valeur que partagée

                      1 Reply Last reply Reply Quote 0
                      • halroachH Offline
                        halroach
                        last edited by 19 May 2009, 06:07

                        I haven't been able to generate any shapes with selected shapes, or with selected construction points, if in a group/components/outside a group/component. I get the following errors:
                        "qhull generated empty results"
                        "qhull failed to generate valid results"

                        ideas?

                        FlexTools - Super Quick Windows, Doors, Slats...

                        1 Reply Last reply Reply Quote 0
                        • A Offline
                          avariant
                          last edited by 19 May 2009, 16:13

                          If your points are all on the same plane, then you won't get any results.

                          To ensure it works at all:
                          1.Create new, empty scene.
                          2. Plugins->Qhull->Convex->Medium
                          3. A convex shape should be created. Select it.
                          4. Plugins->Qhull->Voronoi->Selection(Free)
                          5. A spiky shape should be created.

                          If all that works, then the problems is your input data (ie model / points).

                          1 Reply Last reply Reply Quote 0
                          • A Offline
                            avariant
                            last edited by 19 May 2009, 23:54

                            I honestly don't know the math, but A LOT of regular shapes, like cubes, planes, etc, don't generate valid voronoi results. They may still generate results from the other options, and will often work if you choose Selection (Sphere) or Selection (Box). I don't know why... math, right? 😉

                            1 Reply Last reply Reply Quote 0
                            • P Offline
                              pilou
                              last edited by 20 May 2009, 00:05

                              So is that normal? 😄
                              Always take a convex volume for any function 😉


                              Qhu.jpg

                              Frenchy Pilou
                              Is beautiful that please without concept!
                              My Little site :)

                              1 Reply Last reply Reply Quote 0
                              • P Offline
                                pilou
                                last edited by 20 May 2009, 00:07

                                No problem ! Thats fun 😉
                                (click image for erase scroll bar)
                                kul.jpg

                                Frenchy Pilou
                                Is beautiful that please without concept!
                                My Little site :)

                                1 Reply Last reply Reply Quote 0
                                • 2 Offline
                                  22curious
                                  last edited by 26 Sept 2009, 22:50

                                  Avariant - Thank's for your Qhull.rb - it could be a crucial piece of the puzzle I'm trying to solve, except I can't get it to function with my own (grouped) convex form.

                                  @avariant said:

                                  If your points are all on the same plane, then you won't get any results.

                                  To ensure it works at all:
                                  1.Create new, empty scene.
                                  2. Plugins->Qhull->Convex->Medium
                                  3. A convex shape should be created. Select it.
                                  4. Plugins->Qhull->Voronoi->Selection(Free)
                                  5. A spiky shape should be created.

                                  If all that works, then the problems is your input data (ie model / points).

                                  Also, if I follow your test instructions, Steps # 1-3 work, but using 4. Plugins->Qhull->Voronoi->Selection(Free) {or any of the other selection options for step 4) yields no results. Using one of the non-selection size options (small through huge) as Step 4 yields the anticipated spiky shape.

                                  I'm having the same trouble as Halroach (did you ever find the solution why?)

                                  @unknownuser said:

                                  Re: [Plugin] QHull

                                  Postby Halroach on Tue May 19, 2009 8:07 am
                                  I haven't been able to generate any shapes with selected shapes, or with selected construction points, if in a group/components/outside a group/component. I get the following errors:
                                  "qhull generated empty results"
                                  "qhull failed to generate valid results"

                                  Please help me find a path to generate voronoi shapes from convex polygons generated and selected by me (not by Convex). 😕

                                  Thanks!

                                  1 Reply Last reply Reply Quote 0
                                  • halroachH Offline
                                    halroach
                                    last edited by 27 Sept 2009, 06:04

                                    @22curious said:

                                    I'm having the same trouble as Halroach (did you ever find the solution why?)

                                    I haven't found a solution yet...

                                    FlexTools - Super Quick Windows, Doors, Slats...

                                    1 Reply Last reply Reply Quote 0
                                    • A Offline
                                      avariant
                                      last edited by 27 Sept 2009, 16:25

                                      Can you post a small example scene?

                                      Very "regular" results, like a cube, a sphere, all geometry in a single plane, usually won't generate valid results. It's just how the mathematics work.

                                      1 Reply Last reply Reply Quote 0
                                      • I Offline
                                        ikun
                                        last edited by 29 Sept 2009, 17:08

                                        Hello!!

                                        Thank you for the plugin!

                                        It s AMAZING!

                                        But I have the same problem as Halroach.....

                                        ... I select the group, (the convex medium), then I run voronoi Selection (Free), and suddenly, sketch up window is minimized, and appears the two error messages ...:

                                        Qhull failed to generate valid results,

                                        Qhull generated empty results
                                        ....

                                        Thank yoouuu!!

                                        1 Reply Last reply Reply Quote 0
                                        • 2 Offline
                                          22curious
                                          last edited by 29 Sept 2009, 19:33

                                          Avariant & Halroach - thanks for the prompt responses - sorry for my delay. Drowning in plugin options, looking for solutions.

                                          Here are examples of a few of my attempts to get Qhull to work with construction points, …because isn't the 'convex' script supposed to form the skin over specific construction points?

                                          Stall from Qhull>convex>selection, using group created by Lsystem, pointified, and grouped:

                                          http://i665.photobucket.com/albums/vv12/22curious/Try Qhull/Trying_convex1.png

                                          Same result from Qhull>convex>selection, removing the lines from group created by Lsystem, leaving just the grouped construction points (even though the lines are supposed to be ignored):

                                          http://i665.photobucket.com/albums/vv12/22curious/Try Qhull/Trying_convex2.png

                                          Attempt to compare the object formed by selecting the point-cloud group above, Qhull>convex> Large(100), which created an apparently random small convex polygon at the origin. I scaled up the polygon (evenly), made the faces transparent, and superimposed it on the point cloud to explore whether there was any apparent relationship between the polygon created and the group of selected points. It seems there is none…?

                                          http://i665.photobucket.com/albums/vv12/22curious/Try Qhull/Trying_convex3.png

                                          Attempt to form a convex hull around irregular polygons Qhull>convex>selection. Tried it grouped (shown). Same failure message, with an apparently random small convex polygon at the origin. This one seems to have no relationship to the objects to be 'hulled' either:

                                          http://i665.photobucket.com/albums/vv12/22curious/Try Qhull/Trying_convex4.png

                                          Tried the same thing ungrouped , same (unrelated) result:

                                          http://i665.photobucket.com/albums/vv12/22curious/Try Qhull/Trying_convex5.png

                                          Tried using Qhull>convex>selection on the selected points (after pointifying the objects above, then exporting the points), creates an object, but there's still no apparent relationship to the points:

                                          http://i665.photobucket.com/albums/vv12/22curious/Try Qhull/Trying_convex6.png

                                          Stall (sort of) from Qhull>voronoi>selection, using group created by Lsystem, pointified, and grouped. Got same failure message, but the Qhull>voronoi>selection did put a spiky object at the origin:

                                          http://i665.photobucket.com/albums/vv12/22curious/Try Qhull/Trying_voronoi1.png

                                          from Qhull>delaunay>selection, using same group. Got same message, but if did put a spiky object at the origin:

                                          http://i665.photobucket.com/albums/vv12/22curious/Try Qhull/Trying_voronoi2.png

                                          Result from Qhull>half>selection, using same subgroup.
                                          Again got same message (Qhull failed to generate valid results), but there IS a very small, apparently random spiky object at the origin:

                                          http://i665.photobucket.com/albums/vv12/22curious/Try Qhull/Trying_voronoi3.png

                                          I need to be able to manipulate surfaces formed from imported CSV points …not random objects.
                                          I'm looking for Qhull's convex.rb to generate specific convex hull surfaces, for voronoi to crack them ...as voronoi is supposed to do. The random spiky objects are fun, beautiful, and maybe even useful - but random. And are the anticipated 'cracks' reversed, forming the spikes?

                                          NOTE: I appreciate that some of the transformations I need can be handled by some of these awesome scripts:

                                          __Didier's points_cloud_triangulation.rb (finally got it to work after spending LOTS of time tracking down the required fix to the delauney.rb file, removing the './').

                                          ___Finally got ArchitectBoy's skin.rb to work when I found Christian_dl's skin-26 version… as long as I use the icons, (though it does not function through Tools> skin.rb ...?). So this creates a convex hull around faces & other polygons…but I haven't found a way to implement that script using points, or to follow with voronoi.

                                          ___ Kirill2008's Pnts2mesh.rb is also very useful - (but can we get it to work with voronoi?)

                                          __ Chris Fullmer's clf_simple_loft.rb is great for regular lines and surfaces

                                          BUT…has anyone gotten voronoi to act on (crack) surfaces created in these alternate ways?

                                          Many thanks. 22curious

                                          1 Reply Last reply Reply Quote 0
                                          • 1
                                          • 2
                                          • 3
                                          • 2 / 3
                                          • First post
                                            Last post
                                          Buy SketchPlus
                                          Buy SUbD
                                          Buy WrapR
                                          Buy eBook
                                          Buy Modelur
                                          Buy Vertex Tools
                                          Buy SketchCuisine
                                          Buy FormFonts

                                          Advertisement