sketchucation logo sketchucation
    • Login
    Oops, your profile's looking a bit empty! To help us tailor your experience, please fill in key details like your SketchUp version, skill level, operating system, and more. Update and save your info on your profile page today!
    🫛 Lightbeans Update | Metallic and Roughness auto-applied in SketchUp 2025+ Download

    Intersect_with group with model

    Scheduled Pinned Locked Moved Developers' Forum
    3 Posts 2 Posters 172 Views 2 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.
    • S Offline
      sardinois
      last edited by

      Hi All,

      I would like to use the intersect_with function to intersect a group of entities with the entire model. Basically similar to the option you get from the context menu when you select a face or group and choose "intersect with->entire model".
      However, I can't seem to figure out what arguments use for the intersect_function
      Can you guys maybe help me out?

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

        Read the API guidance very carefully.
        https://developers.google.com/sketchup/docs/ourdoc/entities#intersect_with
        It's one of the most complicated methods, with six arguments, passed in a not-obvious order.
        You'll need to make transformation[s] - even if 'empty' - to use twice.
        You also need references to the 'entities' contexts for what intersects and where the resultant geometry is put... For example when you intersect a group with the model.entities do you want the intersection lines in the model.entities, the group.entities [needs to apply the group.transformation [.inverse?]] or inside a newly made group in the model OR group.entities, so they are separate from rest...
        Note that the final argument must be either one 'entity' or an 'array of entities', not an entities-object.

        TIG

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

          Thanks TIG! The problem was indeed the last argument, I put an entities object in there. working with an array instead did the job

          1 Reply Last reply 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