License delivery maintenance is planned for Saturday, July 26, between 12:00 and 20:00 CEST. During this time, you may experience outages or limited availability across our services, including BIMcloud SaaS, License Delivery, Graphisoft ID (for customer and company management), Graphisoft Store, and BIMx Web Viewer. More details…

GDL
About building parametric objects with GDL.
SOLVED!

substract from block with help of revolve, if angle # 360

A_ Smith
Expert
I'm trying to make object with complex wholes. To simplify that made that with basic figures, but as i see subgroup works fine only when revolve's angle =360. Otherwise i see no effect. I was hoping that if j=1 in mask (closed top, side surfaces it), programme would consider that this object is closed/whole, same as when angle 180.

project2 3,270,2
!please in settings make 3D as wired - to see holes inside blocks

model solid
pen 1
building_material 10	!concrete - just to see fill in section view

group "solid block"
	add -0.25*a,-0.5*b,-0.5*zzyzx
	block A,B,ZZYZX
endgroup

group "revolve romb 360"	
	si=1
	put 0,0,si
	put A*0.25, B*0.25, si
	put A*0.5, 0, si
	j1=1:	j2=1:	j3=1:	j4=1:	j5=1:	j6=1:	j7=1:	j8=0:	j9=0
	maskRevolve = j1 + j2*2 + j3*4 + j4*8 + j5*16 + j6*32 + j7*64 + j8*128 + j9*256
	revolve nsp/3, 360, maskRevolve, get(nsp)
endgroup

result = subgroup ("solid block", "revolve romb 360")
placegroup result

group "revolve romb 180"	
	model solid
	si=1
	put 0,0,si
	put A*0.25, B*0.25, si
	put A*0.5, 0, si
	j1=01:	j2=01:	j3=01:	j4=01:	j5=01:	j6=01:	j7=01:	j8=01:	j9=01
	maskRevolve = j1 + j2*2 + j3*4 + j4*8 + j5*16 + j6*32 + j7*64 + j8*128 + j9*256
	revolve nsp/3, 180, maskRevolve, get(nsp)
endgroup

add A*2,0,0
result3 = subgroup ("solid block", "revolve romb 180")	! HAS NO EFFECT - second cube remains the same, without any hole
placegroup result3

del top
AC 22, 24 | Win 10
1 ACCEPTED SOLUTION

Accepted Solutions
Solution
runxel
Hero
For some reason it won't work with REVOLVE.
Instead use REVOLVE{2}, then everything is fine.
Lucas Becker | AC 27 on Mac | Graphisoft Insider Panelist | Akroter.io – high-end GDL objects | Author of Runxel's Archicad Wiki | Editor at SelfGDL | Developer of the GDL plugin for Sublime Text

My List of AC shortcomings & bugs | I Will Piledrive You If You Mention AI Again |

POSIWID – The Purpose Of a System Is What It Does /// «Furthermore, I consider that Carth... yearly releases must be destroyed»

View solution in original post

2 REPLIES 2
Solution
runxel
Hero
For some reason it won't work with REVOLVE.
Instead use REVOLVE{2}, then everything is fine.
Lucas Becker | AC 27 on Mac | Graphisoft Insider Panelist | Akroter.io – high-end GDL objects | Author of Runxel's Archicad Wiki | Editor at SelfGDL | Developer of the GDL plugin for Sublime Text

My List of AC shortcomings & bugs | I Will Piledrive You If You Mention AI Again |

POSIWID – The Purpose Of a System Is What It Does /// «Furthermore, I consider that Carth... yearly releases must be destroyed»
A_ Smith
Expert
Yeah, you're right. Thank you
AC 22, 24 | Win 10

Didn't find the answer?

Check other topics in this Forum

Back to Forum

Read the latest accepted solutions!

Accepted Solutions

Start a new conversation!