sketchucation logo sketchucation
    • Login
    ℹ️ Licensed Extensions | FredoBatch, ElevationProfile, FredoSketch, LayOps, MatSim and Pic2Shape will require license from Sept 1st More Info

    [Plugin] CleanUp

    Scheduled Pinned Locked Moved Plugins
    974 Posts 217 Posters 788.6k Views 217 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.
    • M Offline
      MtnTrails
      last edited by

      πŸ‘ Thank you, Thom! Works just like I'd hoped. What a great time saver!

      -Brian

      Keep doing what you're doing and you'll keep getting what you're getting.

      1 Reply Last reply Reply Quote 0
      • GaieusG Offline
        Gaieus
        last edited by

        Hi Thom,

        Thanks for the update. I'll definitely try it out (I managed to forget about two coplanar faces with differently positioned but the same texture again and screwed up my model - no big hassle though just a "doh" moment again...)
        πŸ˜„

        Gai...

        1 Reply Last reply Reply Quote 0
        • thomthomT Offline
          thomthom
          last edited by

          @gaieus said:

          Hi Thom,

          Thanks for the update. I'll definitely try it out (I managed to forget about two coplanar faces with differently positioned but the same texture again and screwed up my model - no big hassle though just a "doh" moment again...)
          πŸ˜„

          Ah yes - I'm still not sure how to account for that. But it is possible ... somehow...

          Thomas Thomassen β€” SketchUp Monkey & Coding addict
          List of my plugins and link to the CookieWare fund

          1 Reply Last reply Reply Quote 0
          • Rich O BrienR Offline
            Rich O Brien Moderator
            last edited by

            Hi Thom,

            Thanks for the update, one of my favourite plugins.
            Doesnt say much about my modelling ability!

            Download the free D'oh Book for SketchUp πŸ“–

            1 Reply Last reply Reply Quote 0
            • thomthomT Offline
              thomthom
              last edited by

              Important update in 1.2.2
              Sorry for all these updates recently.
              I think I found the root of why the last update wasn't 100%.

              It now erases edges as they are processes, instead of in bulk later. This is because each face's plane equations must be re-evaluated after it's been merged. This might lead to slightly longer processing time - but I now hope that it truly is 100% watertight.

              Thomas Thomassen β€” SketchUp Monkey & Coding addict
              List of my plugins and link to the CookieWare fund

              1 Reply Last reply Reply Quote 0
              • EarthMoverE Offline
                EarthMover
                last edited by

                Thanks for the update. I use this puppy all the time! πŸ‘

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

                1 Reply Last reply Reply Quote 0
                • J Offline
                  Jim
                  last edited by

                  Thanks - it is doing better job of removing edges. I am willing to trade a little extra time for a cleaner model.

                  I did get a reference to a deleted Edge error on this model (.stl import.) I haven't investigated the cause, but I've attached it in case you're curious.

                  Error: #<TypeError: reference to deleted Edge> C:\Program Files\Google\Google SketchUp 7\Plugins\tt_cleanup.rb:283:infaces'`

                  My fix:
                  283: next unless e.valid? and e.is_a?(Sketchup::Edge)

                  But is doesn't explain the cause.


                  moai.skp

                  Hi

                  1 Reply Last reply Reply Quote 0
                  • thomthomT Offline
                    thomthom
                    last edited by

                    hm.. that is odd. I wonder why that happens. thanks for posting the model.

                    Thomas Thomassen β€” SketchUp Monkey & Coding addict
                    List of my plugins and link to the CookieWare fund

                    1 Reply Last reply Reply Quote 0
                    • thomthomT Offline
                      thomthom
                      last edited by

                      Updated to account for the issue reported by Jim.

                      Though I still don't understand why I ever get a reference to a deleted edge...

                      Thomas Thomassen β€” SketchUp Monkey & Coding addict
                      List of my plugins and link to the CookieWare fund

                      1 Reply Last reply Reply Quote 0
                      • TIGT Offline
                        TIG Moderator
                        last edited by

                        Trap unexpected deleted edges with edge.erase! if edge.valid? type of code ?

                        TIG

                        1 Reply Last reply Reply Quote 0
                        • thomthomT Offline
                          thomthom
                          last edited by

                          Yes - but what puzzles me is why the code comes across deleted references at all. After reviewing my code I can't work out why. I am iterating an array copy of the entities collection. And I only iterate the array once.

                          Thomas Thomassen β€” SketchUp Monkey & Coding addict
                          List of my plugins and link to the CookieWare fund

                          1 Reply Last reply Reply Quote 0
                          • thomthomT Offline
                            thomthom
                            last edited by

                            Gaieus: This update is for you. Made it investigate the UV's before merging.
                            Not that it is very strict, the UV values for either vertex of the edge has to be identical for each face connected to it before it merges. This means there might be cases where it visually looks like they should merge, but doesn't. They should merge is you position a material on one face and use the dropper to paint other adjacent faces.
                            To turn of this feature just enable the Ignore UV's.

                            Note that this is pretty fresh code that hasn't been tested well. (Only very quickly.) So please investigate the model after using the tool and report any unexpected behaviour. (Please most sample model as that will make debugging much easier.)

                            Thomas Thomassen β€” SketchUp Monkey & Coding addict
                            List of my plugins and link to the CookieWare fund

                            1 Reply Last reply Reply Quote 0
                            • E Offline
                              Ern
                              last edited by

                              Very handy,


                              Now all the cookies are yours!

                              1 Reply Last reply Reply Quote 0
                              • GaieusG Offline
                                Gaieus
                                last edited by

                                @thomthom said:

                                Gaieus: This update is for you. Made it investigate the UV's before merging...

                                Thanks a bunch, Thom, πŸ‘
                                I will definitely check it out. Lately I have needed this function really badly.

                                Gai...

                                1 Reply Last reply Reply Quote 0
                                • J Offline
                                  j40
                                  last edited by

                                  Thanks a lot Thom !! πŸ‘ This is one of the greatest plugins.

                                  Top3D Studio

                                  1 Reply Last reply Reply Quote 0
                                  • thomthomT Offline
                                    thomthom
                                    last edited by

                                    Version 2.0.0

                                    • Supports ThomThom's Menu
                                    • Persistent preferences.
                                    • Settings for global and local cleanup synced.
                                    • Repairs split edges. (Based on Carlo Roosen's Repair Broken Edges)
                                    • Removes duplicate faces.
                                    • Fixes duplicate component definition names.
                                    • Runs Validity Check at the end.

                                    "Duplicate faces" are faces where multiple faces share the same set of vertices. The plugins should also be able to detect smaller faces overlapping larger faces.

                                    Thomas Thomassen β€” SketchUp Monkey & Coding addict
                                    List of my plugins and link to the CookieWare fund

                                    1 Reply Last reply Reply Quote 0
                                    • GaieusG Offline
                                      Gaieus
                                      last edited by

                                      Downloading... πŸ˜‰

                                      Gai...

                                      1 Reply Last reply Reply Quote 0
                                      • Rich O BrienR Offline
                                        Rich O Brien Moderator
                                        last edited by

                                        Hi Thom,

                                        thanks for the update πŸ‘

                                        Incredible tool! Should be mentioned in the Visual Index thread

                                        Rich

                                        Download the free D'oh Book for SketchUp πŸ“–

                                        1 Reply Last reply Reply Quote 0
                                        • J Offline
                                          Jim
                                          last edited by

                                          Yep, this is the best cleanup script available.

                                          I know the choice of user interface is limited, but I'm not a fan of nested menus. I was wondering if a webdialog interface would work. So then I could have a single shortcut that would bring up the "cleanup" dialog showing the options available, and then "run" from there. Maybe? Someday?

                                          Edit: "best" is an under-statement - it's important and essential.

                                          Hi

                                          1 Reply Last reply Reply Quote 0
                                          • thomthomT Offline
                                            thomthom
                                            last edited by

                                            @jim said:

                                            I know the choice of user interface is limited, but I'm not a fan of nested menus. I was wondering if a webdialog interface would work. So then I could have a single shortcut that would bring up the "cleanup" dialog showing the options available, and then "run" from there. Maybe? Someday?

                                            Yes - that is exactly what I have in mind. The options are growing so a better UI is required. However, I'm trying to prioritise Vertex Edit. This has been a necessary distraction because I need it at work.

                                            So my plans for v2 that did not make it will be postponed to v3:

                                            • Merge Identical and similar materials
                                            • Axis adjustments
                                            • Find identical groups/components (If I can find a good algorithm for this.)
                                              For this webdialog UI is a must in order to be friendly to use.

                                            Thanks for letting me know how to activate the Fix Model function - in some cases it appears that erasing big bulk of edges messes up SUæs Loops. Even though everything looks fine in SU. So it was good to force that test after a cleanup.

                                            Thomas Thomassen β€” SketchUp Monkey & Coding addict
                                            List of my plugins and link to the CookieWare fund

                                            1 Reply Last reply Reply Quote 0
                                            • 1
                                            • 2
                                            • 3
                                            • 4
                                            • 5
                                            • 6
                                            • 7
                                            • 8
                                            • 48
                                            • 49
                                            • 6 / 49
                                            • First post
                                              Last post
                                            Buy SketchPlus
                                            Buy SUbD
                                            Buy WrapR
                                            Buy eBook
                                            Buy Modelur
                                            Buy Vertex Tools
                                            Buy SketchCuisine
                                            Buy FormFonts

                                            Advertisement