Jump to content
AlexanderP

Boolean operations. Creating general surfaces

Recommended Posts

Hello all. I have a question. Is it possible to create with .tcl commands general surfaces, but for all solids.
It is very tedious to constantly perform repeated commands. And script could solve this problem.
image.thumb.png.05ee365e9bf00a1ab7686f40d2a02f28.png

For example this detail:
image.png.7cededa96b3614668cc1f6f85561d6a7.png

This surfaces were made by next commands:
 

add_button "Make boolean surfaces" { 
*createmark solids 1 1
*createmark solids 2 5
*boolean_merge_solids 1 2 14 2

*createmark solids 1 1
*createmark solids 2 5
*boolean_merge_solids 1 2 14 2

*createmark solids 1 2
*createmark solids 2 1
*boolean_merge_solids 1 2 14 2

*createmark solids 1 3
*createmark solids 2 1
*boolean_merge_solids 1 2 14 2

*createmark solids 1 4
*createmark solids 2 1
*boolean_merge_solids 1 2 14 2

*createmark solids 1 5
*createmark solids 2 1
*boolean_merge_solids 1 2 14 2

*createmark solids 1 2
*createmark solids 2 2
*boolean_merge_solids 1 2 14 2

*createmark solids 1 2
*createmark solids 2 3
*boolean_merge_solids 1 2 14 2

*createmark solids 1 2
*createmark solids 2 4
*boolean_merge_solids 1 2 14 2

*createmark solids 1 2
*createmark solids 2 5
*boolean_merge_solids 1 2 14 2

*createmark solids 1 3
*createmark solids 2 1
*boolean_merge_solids 1 2 14 2

*createmark solids 1 3
*createmark solids 2 2
*boolean_merge_solids 1 2 14 2}

But if we have about 100+ solids and more?
How to solve this question\problem?
Thanks!

Share this post


Link to post
Share on other sites

Hi

Try simple loops like this. 

 

for {set i 1} {$i<6} {incr i} {
for {set j [expr $i+1]} {$j<6} {incr j} {
*createmark solids 1 $i
*createmark solids 2 $j
*boolean_merge_solids 1 2 14 2
}
}

AlexanderP and Livil Lyle like this

Share this post


Link to post
Share on other sites
16 hours ago, vipin said:

Hi

Try simple loops like this. 

 

for {set i 1} {$i<6} {incr i} {
for {set j [expr $i+1]} {$j<6} {incr j} {
*createmark solids 1 $i
*createmark solids 2 $j
*boolean_merge_solids 1 2 14 2
}
}

Thank you. It works :)

vipin likes this

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
You are posting as a guest. If you have an account, please sign in.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


×
×
  • Create New...