sketchucation logo sketchucation
    • Login
    πŸ›£οΈ Road Profile Builder | Generate roads, curbs and pavements easily Download

    Quad chamfer corner question

    scheduled pinned locked moved Developers' Forum
    10 Posts 4 Posters 2.0k Views 4 Watching
    loading-more-posts
    • oldest-to-newest
    • newest-to-oldest
    • most-votes
    reply
    • reply-as-topic
    guest-login-reply
    deleted-message
    • PixeroP Offline
      Pixero
      last edited by

      I'm trying to understand how to calculate the position of the middle vertex in a quad chamfer where all faces are planar quads.
      How is the lenght of the blue line calculated?
      I've made the simplest possible example scene to try and understand how it works.
      Quadcorner.JPG

      Quadcorner test.skp

      one-reply-to-this-post last-reply-time reply quote 0
      • C Offline
        CAUL
        last edited by

        If I understand you correctly, this is how I would solve it

        The corner "hole" consists of 6 edges (see image). Two edges defines a plane represented by an array of the form [point, normal]. If you have two edges with a common vertex the normal is the cross product of the edges:

        normal = e0.line[1].cross(e1.line[1]) plane = [e0.start.position, normal]

        Given planes pl0, pl1, pl2 for the edge sets (red, green and blue in the image), you can now calculate the point:

        line = Geom::intersect_plane_plane(pl0, pl1) point = Geom::intersect_line_plane(line, pl2)

        The point represents the position of your vertex in the corner.


        chamfer.png

        one-reply-to-this-post last-reply-time reply quote 0
        • PixeroP Offline
          Pixero
          last edited by

          Thanks, I'll try that.

          one-reply-to-this-post last-reply-time reply quote 0
          • thomthomT Offline
            thomthom
            last edited by

            Did you find a solution?

            Did you create a quad-chamfer extension? o_O

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

            one-reply-to-this-post last-reply-time reply quote 0
            • PixeroP Offline
              Pixero
              last edited by

              I looked into it but hadn't the time needed to solve it so hoping someone picks up on this and creates a quad chamfer plugin.

              one-reply-to-this-post last-reply-time reply quote 0
              • sdmitchS Offline
                sdmitch
                last edited by

                @pixero said:

                I looked into it but hadn't the time needed to solve it so hoping someone picks up on this and creates a quad chamfer plugin.

                I did this six weeks ago. Sorry for not posting it sooner.


                Quad Chamfer.gif


                Quad Chamfer.rb

                Nothing is worthless, it can always be used as a bad example.

                http://sdmitch.blogspot.com/

                one-reply-to-this-post last-reply-time reply quote 0
                • PixeroP Offline
                  Pixero
                  last edited by

                  Wow! Would it be possible to have the script do the chamfering/fillet of edges with a radius/offset setting and a segment setting and not just the corner?
                  Like Image 1 and 3 in this example.

                  http://help.autodesk.com/cloudhelp/2016/ENU/3DSMax/images/GUID-E1FC8441-C6EA-4500-A9DD-78207AC06396.png

                  one-reply-to-this-post last-reply-time reply quote 0
                  • sdmitchS Offline
                    sdmitch
                    last edited by

                    Isn't that what the Round Corners plugin does?

                    ps. The Quad Chamfer plugin executes with a left click when the Yellow edges appear instead of the Messagebox.

                    Nothing is worthless, it can always be used as a bad example.

                    http://sdmitch.blogspot.com/

                    one-reply-to-this-post last-reply-time reply quote 0
                    • PixeroP Offline
                      Pixero
                      last edited by

                      @sdmitch said:

                      Isn't that what the Round Corners plugin does?

                      ps. The Quad Chamfer plugin executes with a left click when the Yellow edges appear instead of the Messagebox.

                      Round corner plugin is great but creates a triangel at the corner, so an all quads chamfer/fillet plugin is still needed.
                      I've asked for him to fix it but nothing has happened so go for it! πŸ‘

                      one-reply-to-this-post last-reply-time reply quote 0
                      • thomthomT Offline
                        thomthom
                        last edited by

                        I guess Fredo is occupied with Animator these days.

                        It would be great if more extensions could be made available on GitHub, BitBucket with open source licenses - allowing people to add to existing extensions instead of re-implementing similar functions.

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

                        one-reply-to-this-post last-reply-time reply quote 0
                        • 1 / 1
                        • first-post
                          last-post
                        Buy SketchPlus
                        Buy SUbD
                        Buy WrapR
                        Buy eBook
                        Buy Modelur
                        Buy Vertex Tools
                        Buy SketchCuisine
                        Buy FormFonts

                        Advertisement