• Login
sketchucation logo sketchucation
  • Login
πŸ€‘ SketchPlus 1.3 | 44 Tools for $15 until June 20th Buy Now

[Plugin] Drop Vertices

Scheduled Pinned Locked Moved Plugins
51 Posts 17 Posters 147.9k Views
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.
  • T Offline
    TIG Moderator
    last edited by 9 Aug 2011, 16:11

    This will do it

    v=[];t=0;m=Sketchup.active_model;m.entities.each{|e|v<<e.vertices if e.class==Sketchup;;Edge};v.flatten!;v.uniq!;p t=v.length;tt=0;m.definitions.each{|d|v=[];d.entities.each{|e|v<<e.vertices if e.class==Sketchup;;Edge};v.flatten!;v.uniq!;tt=tt+(v.length*d.instances.length)};p tt;p gt=t+tt;puts
    

    Copy+Paste this one-liner into the Ruby Console + <Enter> it prints the total of all unique vertices in the model AND then those vertices inside groups/instance [multiplied by the number of instances of each] and then the grand total of the two.

    TIG

    1 Reply Last reply Reply Quote 0
    • W Offline
      wyatt
      last edited by 9 Aug 2011, 19:19

      I think this will be a very useful plugin. I can't get Lowest, Highest, Average, or Middle to work though. No matter which ones I pick, all the vertices go to zero. First I created a surface with undulating edges, selected the outer edges, and ran the plugin. I thought that's what I saw in the videos, and that process works for the other tools. Did I miss something, or is there a bug in the .2 release that wasn't there in .1?

      1 Reply Last reply Reply Quote 0
      • M Offline
        MartinK
        last edited by 9 Aug 2011, 21:42

        Thanks for another great plugin. I may be missing something, but is there a way to specify, by picking a point, where the selected vertices drop/raise to?

        1 Reply Last reply Reply Quote 0
        • T Offline
          TIG Moderator
          last edited by 10 Aug 2011, 08:46

          • Lowest/Highest/Middle should adjust the vertices' z-value to match the z-value of the vertex in the selection that is lowest/highest/midway-between ??? Can you post and example of a SKP where it fails...
          • You can't 'pick a point' - depending on the tool you've selected you can specify a 'Z value' or it drops/lifts to objects etc...

          TIG

          1 Reply Last reply Reply Quote 0
          • M Offline
            MartinK
            last edited by 10 Aug 2011, 11:16

            Thanks for the answer.

            1 Reply Last reply Reply Quote 0
            • M Offline
              MartinK
              last edited by 10 Aug 2011, 12:22

              I seem to be having the same problem as Wyatt, vertices only move to Z=0 no matter what method I use. I can't post the SKP as it is a large site model. Just wondering if anyone else has had this issue with Version 1.2.

              Thanks

              1 Reply Last reply Reply Quote 0
              • T Offline
                TIG Moderator
                last edited by 10 Aug 2011, 12:33

                I have checked and there is 'a rabbit away' !
                Watch out for fixed code soon πŸ˜’

                TIG

                1 Reply Last reply Reply Quote 0
                • T Offline
                  TIG Moderator
                  last edited by 10 Aug 2011, 13:05

                  Here's v1.3 http://forums.sketchucation.com/viewtopic.php?p=346754#p346754
                  It fixes a last minute typo in my code that affected Lowest/Highest/Middle results - it should now work as advertised - feedback please...dvs.PNG

                  TIG

                  1 Reply Last reply Reply Quote 0
                  • W Offline
                    wyatt
                    last edited by 10 Aug 2011, 13:52

                    The high/low/middle work correctly now. Thank you for this script.

                    1 Reply Last reply Reply Quote 0
                    • M Offline
                      MartinK
                      last edited by 10 Aug 2011, 14:21

                      That seems to have done the trick. Many thanks. πŸ‘

                      1 Reply Last reply Reply Quote 0
                      • S Offline
                        simon le bon
                        last edited by 12 Aug 2011, 13:57

                        Thank you so much Dear TIG for this brand new tool.

                        ("to middle" and "to average" options don't work for me with su6_free and su7_pro)

                        Coming back to the thread which had (re)initiated the need for such a tool: What's the best way to flatten some geometry lines

                        I'm trying the old problem (not solved by SandboxTools/stamp)to achieve to drop vertices of a 3d path onto a 3d terrain. (I would like start with a path "melted up an down", "included" with/into the terrain)
                        I have made my road/path triangulated (with Sandboxtools/from contour)
                        Tip: I use [Plugin] Select Outer Edges v1.0 by Chris Fullmer to select outer edges πŸ˜’

                        But Whatever the option I choose with Drop Vertices I got aberrant result πŸ˜•


                        http://i274.photobucket.com/albums/jj245/Spendauballet/SketchUp/thdropverts_001.jpg

                        to nearest object , to nearest below..

                        http://i274.photobucket.com/albums/jj245/Spendauballet/SketchUp/thdropverts_002.jpg

                        Any Idea ??

                        (Alternatively, I have tried "Drape CPoints" + "Triangulate Points" and also "Artisan"€ and this one gives the better results for me from now, using "Crease Selection" Edges+vertices on the total path face .


                        http://i274.photobucket.com/albums/jj245/Spendauballet/SketchUp/thdropverts_003.jpg

                        Cheers
                        simon.


                        Re: thank you dear Tig for your [Plugin] Work Plane v2.3 by TIG on Sat Sep 25, 2010 I'm using for long >>referencing to "this"

                        1 Reply Last reply Reply Quote 0
                        • T Offline
                          TIG Moderator
                          last edited by 12 Aug 2011, 15:59

                          Simon

                          DropVertices isn't DrapeCapture.PNG

                          TIG

                          1 Reply Last reply Reply Quote 0
                          • S Offline
                            simon le bon
                            last edited by 12 Aug 2011, 18:18

                            Bonjour TIG πŸ˜„

                            OK, I was confused on the concepts Drape/Drope.

                            I have discovered that the kind of subdivision is important. Until now I was trying to drape with some classical triangulated shapes and that's why the result wasn't working.

                            As I have seen with your example above it was possible, I have discovered that shapes must be subdivided by real tin subdivision.(as far)


                            http://i274.photobucket.com/albums/jj245/Spendauballet/SketchUp/thdropverts_005.jpg


                            http://i274.photobucket.com/albums/jj245/Spendauballet/SketchUp/thdropverts_006.jpg

                            (I see we can't obtain this way something like we can do with sandboxtool/Stamptool but with a 3D path.)

                            Anyway This DropVertices brings so much !!!!+++ Thank you one more time and bravo!! TIG

                            simon.

                            1 Reply Last reply Reply Quote 0
                            • EarthMoverE Offline
                              EarthMover
                              last edited by 12 Aug 2011, 19:20

                              Here is another method to do what you are looking for Simon.

                              [flash=800,600:1yx2pldf]http://www.youtube.com/v/hzN5n2UB7Ao[/flash:1yx2pldf]

                              3D Artist at Clearstory 3D Imaging
                              Guide Tool at Winning With Sketchup
                              Content Creator at Skapeup

                              1 Reply Last reply Reply Quote 0
                              • S Offline
                                simon le bon
                                last edited by 12 Aug 2011, 22:58

                                Dear Adam,
                                your videos are invaluable to understand easily how things work and as reminders.
                                I have watched your previous a number of times.

                                I'm studying your propositions (soapskin&buble _ instant road (which makes the deal πŸ‘ πŸ‘ ) and I'm thinking to others. It's for tomorrow now.

                                Cheers,

                                   simon.
                                
                                1 Reply Last reply Reply Quote 0
                                • pilouP Offline
                                  pilou
                                  last edited by 22 Aug 2011, 12:47

                                  Maybe use of Ferrari can also gives some cool results πŸ˜‰

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

                                  1 Reply Last reply Reply Quote 0
                                  • K Offline
                                    ktslambieng
                                    last edited by 6 Jan 2012, 03:18

                                    oh .thank u verry much
                                    but ruby SplitUp I can find where, who can help me, please
                                    i saw on Youtube
                                    http://www.youtu.be/watch?v=kAUx4AHVbOU&feature=related

                                    1 Reply Last reply Reply Quote 0
                                    • T Offline
                                      TIG Moderator
                                      last edited by 6 Jan 2012, 09:43

                                      @ktslambieng said:

                                      oh .thank u verry much
                                      but ruby SplitUp I can find where, who can help me, please
                                      i saw on Youtube
                                      http://www.youtu.be/watch?v=kAUx4AHVbOU&feature=related

                                      Like 'On Screen Rolling Reel' - 'SplitUp' has never been published.
                                      It's in beta testing with a select group [Rich O'B].
                                      The bugs are now ironed out... I'll speak with the other[s] to see what we should do next...

                                      TIG

                                      1 Reply Last reply Reply Quote 0
                                      • Rich O BrienR Offline
                                        Rich O Brien Moderator
                                        last edited by 6 Jan 2012, 10:03

                                        Don't forget my NURBS plugin that's fairly stable. Just too powerful for mere mortals.

                                        Download the free D'oh Book for SketchUp

                                        1 Reply Last reply Reply Quote 0
                                        • peter_shawP Offline
                                          peter_shaw
                                          last edited by 5 Jul 2013, 12:23

                                          great plugin, used it to fix a f-ed up model

                                          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