<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Cut Material in 3D in GDL</title>
    <link>https://community.graphisoft.com/t5/GDL/Cut-Material-in-3D/m-p/265597#M3035</link>
    <description>&lt;BLOCKQUOTE&gt;Braza wrote:&lt;BR /&gt;
Hi Arnaut,&lt;BR /&gt;
If I understand you correctly, there is a solution for this that I used in the &lt;A href="https://archicad-talk.graphisoft.com/viewtopic.php?p=316799#p316799" target="_blank"&gt;Composite Mesh Object&lt;/A&gt;.&lt;BR /&gt;
It is what I call a "GDL Jedi Trick" like "&lt;I&gt;&lt;/I&gt;&lt;S&gt;&lt;I&gt;&lt;I&gt;&lt;/I&gt;&lt;/I&gt;&lt;/S&gt;These are not the droids we are looking for&lt;E&gt;&lt;/E&gt;"  &lt;IMG src="https://community.graphisoft.com/legacyfs/online/emojis/icon_smile.gif" style="display : inline;" /&gt;&lt;BR /&gt;
So, to full a Called custom saved object to display new BM's or any other parameters, the trick is to: In the Call definition of the saved object, define all the parameters that you want to override with a "-1" value.  The CALL commands says something like: if the compiler can't find the value in the local list of attributes it will adopt the very previous BM definition.  So put a BM definition right before the CALL.  Then it will stick to the Called object.  &lt;BR /&gt;
It will give only a "minor error occurred message" while saving it, but it wont affect the object functionality.&lt;BR /&gt;
Hope this helps.
&lt;/BLOCKQUOTE&gt;

Worked perfectly! Thank you so much!&lt;BR /&gt;
&lt;BR /&gt;
i can now, call -&amp;gt; Override -&amp;gt; Cut and repeat &lt;BR /&gt;
&lt;BR /&gt;
A lot more elegant than I would have managed!&lt;PRE&gt;MODEL SOLID

if GLOB_CONTEXT = 2 then
add 0,0,GLOB_CUTPLANES_INFO[1] + GLOB_CSTORY_ELEV - GLOB_HSTORY_ELEV
CUTPLANE{2} 0,0
del 1
endif

i = von

h = von_H


Group "O"

CALL "Operator Höhenfarben" PARAMETERS materialAttribute_1 = 2, materialAttribute_2 = 3, materialAttribute_3 = i

Endgroup

if Sichtbar then
placegroup "O"
endif



repeat

	i = i + 1
	h = h + hohe
Gosub "Schicht":

until h &amp;gt;= bis_H



IF GLOB_CONTEXT=2 THEN
CUTEND
ENDIF

del top

!===========================================================
End
!===========================================================



"Schicht":
addz h-GLOB_ELEVATION!-Versatz
CUTPLANE 1,1,0,0
addz -hohe
CUTPLANE 1,1,0,1
!Circle 10
del 2

!material i
!addz -10
!Block 10,10,10
!del 1


CALL "Operator Höhenfarben" PARAMETERS materialAttribute_1 = i, materialAttribute_2 = i, materialAttribute_3 = i, materialAttribute_4 = i, materialAttribute_5 = i, buildingMatAttribute_1 = i

Cutend
Cutend
Return&lt;/PRE&gt;</description>
    <pubDate>Tue, 11 May 2021 16:22:46 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2021-05-11T16:22:46Z</dc:date>
    <item>
      <title>Cut Material in 3D</title>
      <link>https://community.graphisoft.com/t5/GDL/Cut-Material-in-3D/m-p/265588#M3026</link>
      <description>&lt;DIV class="actalk-migrated-content"&gt;A project I'm working on is pretty complicated when it comes to height differences. So I decided to show those differences with a rainbow colour spectrum.&lt;BR /&gt;The issue I have is that the graphical overriding (in German it's called Graphische Überschreibung) only works on the ceilings.&lt;BR /&gt;&lt;BR /&gt;I've created a object which layers Polys every 0.50 m and changes surface accordingly.&lt;BR /&gt;&lt;BR /&gt;My thought being that I could then use solid intersection to get these colors also on the ramp and ceiling of the parking garage.&lt;BR /&gt;&lt;BR /&gt;The surface which is cut is just grey. I assume it's because of the building material. Is there a way to override this?&lt;BR /&gt;&lt;BR /&gt;When I set the status code of the poly to 1 I can see that the colors are still there but only where the layers of the poly are.
&lt;PRE&gt;MODEL SOLID

For i =Von to bis

Material BM

set Material i
!block A,B,hohe

put 0	,0	,15
put A	,0	,15
put A	,B	,15
put 0	,B	,15

prism_ NSP/3,hohe,
	get (NSP)


addz hohe

next i&lt;/PRE&gt;
&lt;/DIV&gt;</description>
      <pubDate>Tue, 14 Sep 2021 07:13:00 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/GDL/Cut-Material-in-3D/m-p/265588#M3026</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2021-09-14T07:13:00Z</dc:date>
    </item>
    <item>
      <title>Re: Cut Material in 3D</title>
      <link>https://community.graphisoft.com/t5/GDL/Cut-Material-in-3D/m-p/265589#M3027</link>
      <description>Hi. Check options in SEO - there must set "Use Own Attributes". And if you would like to see same colour when you cut in 3D (with marquee for example), set "Use Element Attributes" in Filter and Cut Elements in 3D dialog.</description>
      <pubDate>Mon, 10 May 2021 06:31:28 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/GDL/Cut-Material-in-3D/m-p/265589#M3027</guid>
      <dc:creator>Podolsky</dc:creator>
      <dc:date>2021-05-10T06:31:28Z</dc:date>
    </item>
    <item>
      <title>Re: Cut Material in 3D</title>
      <link>https://community.graphisoft.com/t5/GDL/Cut-Material-in-3D/m-p/265590#M3028</link>
      <description>I think this has got to do with the &lt;B&gt;Cut_fill&lt;/B&gt; settings. You would have to set it for each of your layers. I can only think of being able to change this via the &lt;B&gt;Building Material&lt;/B&gt; command.&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
Ling.</description>
      <pubDate>Mon, 10 May 2021 08:50:32 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/GDL/Cut-Material-in-3D/m-p/265590#M3028</guid>
      <dc:creator>Lingwisyer</dc:creator>
      <dc:date>2021-05-10T08:50:32Z</dc:date>
    </item>
    <item>
      <title>Re: Cut Material in 3D</title>
      <link>https://community.graphisoft.com/t5/GDL/Cut-Material-in-3D/m-p/265591#M3029</link>
      <description>Very nice visualization idea.</description>
      <pubDate>Tue, 11 May 2021 05:07:02 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/GDL/Cut-Material-in-3D/m-p/265591#M3029</guid>
      <dc:creator>Marc H</dc:creator>
      <dc:date>2021-05-11T05:07:02Z</dc:date>
    </item>
    <item>
      <title>Re: Cut Material in 3D</title>
      <link>https://community.graphisoft.com/t5/GDL/Cut-Material-in-3D/m-p/265592#M3030</link>
      <description>&lt;BLOCKQUOTE&gt;Lingwisyer wrote:&lt;BR /&gt;
I think this has got to do with the &lt;B&gt;Cut_fill&lt;/B&gt; settings. You would have to set it for each of your layers. I can only think of being able to change this via the &lt;B&gt;Building Material&lt;/B&gt; command.&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
Ling.
&lt;/BLOCKQUOTE&gt;

&lt;BR /&gt;
I was afraid so. In the end the solution i found without creating a building material for each colour was to draw the layers as mesh and then using solid intersection. After I could turn it into a mesh again and save it as an Object.&lt;BR /&gt;
A bit of a work around though  &lt;IMG src="https://community.graphisoft.com/legacyfs/online/emojis/icon_wink.gif" style="display : inline;" /&gt;</description>
      <pubDate>Tue, 11 May 2021 07:05:02 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/GDL/Cut-Material-in-3D/m-p/265592#M3030</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2021-05-11T07:05:02Z</dc:date>
    </item>
    <item>
      <title>Re: Cut Material in 3D</title>
      <link>https://community.graphisoft.com/t5/GDL/Cut-Material-in-3D/m-p/265593#M3031</link>
      <description>&lt;BLOCKQUOTE&gt;Podolsky wrote:&lt;BR /&gt;
Hi. Check options in SEO - there must set "Use Own Attributes". And if you would like to see same colour when you cut in 3D (with marquee for example), set "Use Element Attributes" in Filter and Cut Elements in 3D dialog.
&lt;/BLOCKQUOTE&gt;

Is the a way to set this up within a 3D script?</description>
      <pubDate>Tue, 11 May 2021 07:11:12 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/GDL/Cut-Material-in-3D/m-p/265593#M3031</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2021-05-11T07:11:12Z</dc:date>
    </item>
    <item>
      <title>Re: Cut Material in 3D</title>
      <link>https://community.graphisoft.com/t5/GDL/Cut-Material-in-3D/m-p/265594#M3032</link>
      <description>You cannot control external ArchiCAD commands with GDL script. Maybe I don't understand something - what exactly you need. If this is the case - I can review your file and script - if you upload it here.</description>
      <pubDate>Tue, 11 May 2021 09:20:58 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/GDL/Cut-Material-in-3D/m-p/265594#M3032</guid>
      <dc:creator>Podolsky</dc:creator>
      <dc:date>2021-05-11T09:20:58Z</dc:date>
    </item>
    <item>
      <title>Re: Cut Material in 3D</title>
      <link>https://community.graphisoft.com/t5/GDL/Cut-Material-in-3D/m-p/265595#M3033</link>
      <description>&lt;BLOCKQUOTE&gt;Podolsky wrote:&lt;BR /&gt;
You cannot control external ArchiCAD commands with GDL script. Maybe I don't understand something - what exactly you need. If this is the case - I can review your file and script - if you upload it here.
&lt;/BLOCKQUOTE&gt;

I got a bit further in my project.&lt;BR /&gt;
&lt;BR /&gt;
My thinking is that if get this object to override the surface of what I'm loading into it in segments, it could easily adjust to change.&lt;BR /&gt;
I would just have to select everything I want coloured and save them as an Object which I then "call" into it.&lt;BR /&gt;
&lt;BR /&gt;
The issue now is that it doesn't change the materials of what I'm loading into it.&lt;BR /&gt;
&lt;BR /&gt;
I thought that it might be possible to repeat the solid operation in using "for to next".&lt;BR /&gt;
Here I encountered two problems: The Group "Z" doesn't change material and seems to stay on the first index&lt;BR /&gt;
And I can't  "count" the groups (As in "O(i)")&lt;BR /&gt;
&lt;BR /&gt;
Is the a way to override materials given to something before? like clearing all attributes and assigning a new one&lt;BR /&gt;
&lt;BR /&gt;

&lt;PRE&gt;&lt;I&gt;
&lt;/I&gt;Versatz = 9.00
Von = 1
Bis = 21
Hohe = 0.5

addz -GLOB_ELEVATION-Versatz			!GLOB_CUTPLANES_INFO[1] + GLOB_CSTORY_ELEV - GLOB_HSTORY_ELEV

Group "Z"



	For i =Von to bis
	set Material i
	BUILDING_MATERIAL i
	hotspot 0,0,0
	
	put 0	,0	,15
	put A	,0	,15
	put A	,B	,15
	put 0	,B	,15
	
	prism_ NSP/3,hohe,
		get (NSP)
	
	addz hohe
	
	next i

del top

Endgroup


Group "O"


!!Afterwards I want to insert a Call here

!!The Idea being that if something changes, I can select all ceilings and ramps and just replace the object I'm calling

	add A/4, B/4,0

	hotspot 0,0,0

	set Material 1
	BUILDING_MATERIAL 1
	
	put 0	,0	,15
	put A/2	,0	,15
	put A/2	,B/2	,15
	put 0	,B/2	,15
	
	prism_ NSP/3,5,
		get (NSP)
	

Endgroup

Placegroup "Z" !Ziel

Placegroup "O" ! Operator

Result = ISECTGROUP{3} ("Z", "O", 0, 0, 0 , 2)


addx A*2

Placegroup Result

del 1&lt;/PRE&gt;</description>
      <pubDate>Tue, 11 May 2021 11:40:17 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/GDL/Cut-Material-in-3D/m-p/265595#M3033</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2021-05-11T11:40:17Z</dc:date>
    </item>
    <item>
      <title>Re: Cut Material in 3D</title>
      <link>https://community.graphisoft.com/t5/GDL/Cut-Material-in-3D/m-p/265596#M3034</link>
      <description>Hi Arnaut,&lt;BR /&gt;
If I understand you correctly, there is a solution for this that I used in the &lt;A href="https://archicad-talk.graphisoft.com/viewtopic.php?p=316799#p316799" target="_blank"&gt;Composite Mesh Object&lt;/A&gt;.&lt;BR /&gt;
It is what I call a "GDL Jedi Trick" like "&lt;I&gt;&lt;/I&gt;&lt;S&gt;&lt;I&gt;&lt;I&gt;&lt;/I&gt;&lt;/I&gt;&lt;/S&gt;These are not the droids we are looking for&lt;E&gt;&lt;/E&gt;"  &lt;IMG src="https://community.graphisoft.com/legacyfs/online/emojis/icon_smile.gif" style="display : inline;" /&gt;&lt;BR /&gt;
So, to fool a Called custom saved object to display new BM's or any other parameters, the trick is to: In the Call definition of the saved object, define all the parameters that you want to override with a "-1" value.  The CALL commands says something like: if the compiler can't find the value in the local list of attributes it will adopt the very previous BM definition.  So put a BM definition right before the CALL.  Then it will stick to the Called object.  &lt;BR /&gt;
It will give only a "minor error occurred message" while saving it, but it wont affect the object functionality.&lt;BR /&gt;
Hope this helps.</description>
      <pubDate>Tue, 11 May 2021 15:05:08 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/GDL/Cut-Material-in-3D/m-p/265596#M3034</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2021-05-11T15:05:08Z</dc:date>
    </item>
    <item>
      <title>Re: Cut Material in 3D</title>
      <link>https://community.graphisoft.com/t5/GDL/Cut-Material-in-3D/m-p/265597#M3035</link>
      <description>&lt;BLOCKQUOTE&gt;Braza wrote:&lt;BR /&gt;
Hi Arnaut,&lt;BR /&gt;
If I understand you correctly, there is a solution for this that I used in the &lt;A href="https://archicad-talk.graphisoft.com/viewtopic.php?p=316799#p316799" target="_blank"&gt;Composite Mesh Object&lt;/A&gt;.&lt;BR /&gt;
It is what I call a "GDL Jedi Trick" like "&lt;I&gt;&lt;/I&gt;&lt;S&gt;&lt;I&gt;&lt;I&gt;&lt;/I&gt;&lt;/I&gt;&lt;/S&gt;These are not the droids we are looking for&lt;E&gt;&lt;/E&gt;"  &lt;IMG src="https://community.graphisoft.com/legacyfs/online/emojis/icon_smile.gif" style="display : inline;" /&gt;&lt;BR /&gt;
So, to full a Called custom saved object to display new BM's or any other parameters, the trick is to: In the Call definition of the saved object, define all the parameters that you want to override with a "-1" value.  The CALL commands says something like: if the compiler can't find the value in the local list of attributes it will adopt the very previous BM definition.  So put a BM definition right before the CALL.  Then it will stick to the Called object.  &lt;BR /&gt;
It will give only a "minor error occurred message" while saving it, but it wont affect the object functionality.&lt;BR /&gt;
Hope this helps.
&lt;/BLOCKQUOTE&gt;

Worked perfectly! Thank you so much!&lt;BR /&gt;
&lt;BR /&gt;
i can now, call -&amp;gt; Override -&amp;gt; Cut and repeat &lt;BR /&gt;
&lt;BR /&gt;
A lot more elegant than I would have managed!&lt;PRE&gt;MODEL SOLID

if GLOB_CONTEXT = 2 then
add 0,0,GLOB_CUTPLANES_INFO[1] + GLOB_CSTORY_ELEV - GLOB_HSTORY_ELEV
CUTPLANE{2} 0,0
del 1
endif

i = von

h = von_H


Group "O"

CALL "Operator Höhenfarben" PARAMETERS materialAttribute_1 = 2, materialAttribute_2 = 3, materialAttribute_3 = i

Endgroup

if Sichtbar then
placegroup "O"
endif



repeat

	i = i + 1
	h = h + hohe
Gosub "Schicht":

until h &amp;gt;= bis_H



IF GLOB_CONTEXT=2 THEN
CUTEND
ENDIF

del top

!===========================================================
End
!===========================================================



"Schicht":
addz h-GLOB_ELEVATION!-Versatz
CUTPLANE 1,1,0,0
addz -hohe
CUTPLANE 1,1,0,1
!Circle 10
del 2

!material i
!addz -10
!Block 10,10,10
!del 1


CALL "Operator Höhenfarben" PARAMETERS materialAttribute_1 = i, materialAttribute_2 = i, materialAttribute_3 = i, materialAttribute_4 = i, materialAttribute_5 = i, buildingMatAttribute_1 = i

Cutend
Cutend
Return&lt;/PRE&gt;</description>
      <pubDate>Tue, 11 May 2021 16:22:46 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/GDL/Cut-Material-in-3D/m-p/265597#M3035</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2021-05-11T16:22:46Z</dc:date>
    </item>
    <item>
      <title>Re: Cut Material in 3D</title>
      <link>https://community.graphisoft.com/t5/GDL/Cut-Material-in-3D/m-p/265598#M3036</link>
      <description>Cool! I'm glad it helped.  &lt;IMG src="https://community.graphisoft.com/legacyfs/online/emojis/icon_biggrin.gif" style="display : inline;" /&gt; &lt;BR /&gt;
Cheers,</description>
      <pubDate>Tue, 11 May 2021 16:26:43 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/GDL/Cut-Material-in-3D/m-p/265598#M3036</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2021-05-11T16:26:43Z</dc:date>
    </item>
  </channel>
</rss>

