sketchucation logo sketchucation
    • Login
    โ„น๏ธ Licensed Extensions | FredoBatch, ElevationProfile, FredoSketch, LayOps, MatSim and Pic2Shape will require license from Sept 1st More Info

    [Plugin] RandomPushPull v2.5 20110709

    Scheduled Pinned Locked Moved Plugins
    28 Posts 8 Posters 26.1k Views 8 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.
    • TIGT Offline
      TIG Moderator
      last edited by

      My brain really hurt with the logic of it... but now it's too obvious ๐Ÿ˜’

      TIG

      1 Reply Last reply Reply Quote 0
      • dereiD Offline
        derei
        last edited by

        @tig said:

        My brain really hurt with the logic of it... but now it's too obvious ๐Ÿ˜’

        My brain hurt too trying to "discover" the reason why you tried such complicated ways to do it. Especially because my programming skills are like the result of rand method (yes, between 0 and almost 1 ๐Ÿ˜† ) and I try to learn something from what you do.

        DESIGNER AND ARTIST [DEREI.UK](http://derei.uk/l)

        1 Reply Last reply Reply Quote 0
        • pilouP Offline
          pilou
          last edited by

          So it was a true random result! ๐Ÿ’š

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

          1 Reply Last reply Reply Quote 0
          • pilouP Offline
            pilou
            last edited by

            Always funny and robust! ๐Ÿ˜Ž
            Randompushpull.jpg

            re-apply on result with the all faces (top and lateral) ๐Ÿ˜‰
            result is not too regular? (I took 1 and .1)

            Does it possible to keep the first selection? (top faces)

            Randompushpul1.jpg

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

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

              Unfortunately when you PushPull a face it disappears - the face that is at the new location isn't the same face - that's been deleted by Sketchup...

              So... it's not easy to get a reference to the new face...

              BUT you could do it... you know the plane of the picked face, you know its pt0=vertices[0].position, you know the pushpull vector, so you can offset the pt0 and then test for the new faces added since the pushpull was done and find the one with the same/reversed normal, parallel plane and coincident vertex at the offset pt0 location...

              BUT I'm not going to code it ๐Ÿ˜’

              TIG

              1 Reply Last reply Reply Quote 0
              • pilouP Offline
                pilou
                last edited by

                In this particular case same "top square"
                I can use the Selected by aera by Sdmitch ๐Ÿ˜‰

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

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

                  Except there might be faces with the same area that were not the ones you want - so then things like face.normal / plane becomes relevant too - BUT comparing areas IS a good 'outside-of-the-box' test idea ๐Ÿ˜‰

                  TIG

                  1 Reply Last reply Reply Quote 0
                  • pilouP Offline
                    pilou
                    last edited by

                    @unknownuser said:

                    Except there might be faces with the same area that were not the ones you want

                    As I had started from a sphere and took a minimum measure more large than the big edges on the surface's sphere ๐Ÿค“
                    that can't be arrived ๐Ÿ˜‰
                    It was a very particular case ๐Ÿ˜„

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

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

                      Here's v2.4 http://forums.sketchucation.com/viewtopic.php?p=340452#p340452
                      The selection now passes to the newly pushpulled faces even though the original faces have been deleted by Sketchup...

                      TIG

                      1 Reply Last reply Reply Quote 0
                      • pilouP Offline
                        pilou
                        last edited by

                        Seems selection are not keeping all the initial faces selected! ๐Ÿ˜ฎ
                        (tryed with some adjacents facets on a thick sphere )

                        Does exist a Scale multiple ? (for each facets selected)


                        sphere.jpg

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

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

                          As I explained, the original face is lost with a pushpull so I need to find the equivalent new face... At the moment it matches area, face normal and face plane [offset by the pushpull distance] - even the slightest variance in the figures that Sketchup calculates will result in a mismatch - so I suspect that's why some faces are being ignored ๐Ÿ˜’
                          Any ideas on a better way to spot newly pushpulled faces is invited... ๐Ÿ˜•

                          TIG

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

                            you can add a random move tool?

                            1 Reply Last reply Reply Quote 0
                            • K Offline
                              kyyu
                              last edited by

                              @tig said:

                              As I explained, the original face is lost with a pushpull so I need to find the equivalent new face... At the moment it matches area, face normal and face plane [offset by the pushpull distance] - even the slightest variance in the figures that Sketchup calculates will result in a mismatch - so I suspect that's why some faces are being ignored ๐Ÿ˜’
                              Any ideas on a better way to spot newly pushpulled faces is invited... ๐Ÿ˜•

                              TIG,

                              Seems to work 100%, if you account for the tiny area difference of the new face. In line #64, I used "if face.area-e[0].abs < 0.000001" instead of "if face.area==e[0]".

                              Well, at least this worked on a 7 inch diameter sphere. Don't know if it will fail for other scales.

                              [Addition]
                              Ok, I had a chance to check if scaling would make the new area test fail. Looks ok so far. My sphere had 288 faces. Initially 7 inches in diameter. I've scaled it up to 70, 700, and 7000 inch diameter. And even with the larger areas, 0.000001 difference still worked to compare if the faces have the same area. The plugin still kept the selection on all 288 faces, in all the tests.

                              RandomPushPull (v2.4 sel faces passed,my fix).rb

                              1 Reply Last reply Reply Quote 0
                              • S Offline
                                sonnycds
                                last edited by

                                Muchas gracias, me viene al pelo

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

                                  Here's v2.5 http://forums.sketchucation.com/viewtopic.php?p=340452#p340452
                                  Kyyu beat me to it with an 'area accuracy check', which now [hopefully] ensures that all of the selected faces that are pushpulled [and thereby get erased] now get their selection passed onto the the newly added face every time... ๐Ÿ˜„

                                  TIG

                                  1 Reply Last reply Reply Quote 0
                                  • pilouP Offline
                                    pilou
                                    last edited by

                                    Works like a charm ๐Ÿ‘ ๐Ÿ˜Ž
                                    Again some requests ๐Ÿ˜‰

                                    • does it possible to keep the selection but separated like when you make a normal PushPpull with CTRL ?
                                    • make a Scale on each face

                                    This last must be asked also for Fredo Scale ๐Ÿ˜„

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

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

                                    Advertisement