cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 
GDL
About building parametric objects with GDL.

isectgroup & project2{4}

Paalanen
Booster

Hello everybody,

I'm about to capitulate on an issue I've been banging my head against. The projected parts of an "isected" body isn't drawn completely using the project2{4} command. Would be greatful for any thoughts.
All the best,
Péter

3d script:

group "1"
block 1,1,1
endgroup

group "2"
add .3, .3, .3
block 1,1,1
del 1
endgroup

result = isectgroup("1", "2")
placegroup result

2d:
methodx=3+32+512
partsi=1+2+4+8

project2{4} 3, 0,
0, 0,
1,
2, !---Cutheight: 0,3 - 1 section, 1 -> projection

methodx, partsi,
1, !---Fill
1, 2, !---FillPen, FillBgPen
0, 0, -SYMB_ROTANGLE,
0, 0, !---cutLinePen, cutLineType
0, !---Fill
0, 0, !---FillPen, FillBgPen
0, 0, 0,
3, 1, !---projectedLinePen, projectedLineType

0, 0,
0, !---Fill
0, 0, !---FillPen, FillBgPen
0, 0, -SYMB_ROTANGLE,
0, 0, !---cutLinePen, cutLineType
0, !---Fill
0, 0, !---FillPen, FillBgPen
0, 0, 0,
0, 0, !---projectedLinePen, projectedLineType
5 REPLIES 5
Pertti Paasky
Expert

Hello Peter

Maybe You can add   "project2 3, 0" to show outlines.

project2{4} 3, 0,....- command shows contours.

In Your script the cutheight is 2, it is higher than the model.

In this case no contours are shown.

Maybe You have read Tips and tricks ?

https://gdl.graphisoft.com/tips-and-tricks/using-project24-command

Anyway, this command is cryptical and my forehead is as sore as yours.

BR Pertti

- AC-24 FIN - WIN 10 - HP Zbook -
“A winner is just a loser who tried one more time.”
George M. Moore, Jr.

 

Thank you Sir Pääsky!

The project2{4} command produces a section through the 3d body if the cutheight is set to cut it. In addition, it produces a projection of whatever is in front of the cutheight and not cut. The polygons of the cut and the projection are controlled separately. In my example, cutheights 0,3-1 produce sections. 1 and above will produce a projection. The section works fine. However, the projection is faulty and this happens specifically when "isecting" groups. See attached pic below - I added a simple block to point out that the projection does work when not "isect".

Watch your forehead : )

 

 

 

Screenshot 2024-04-22 at 9.15.35.png



 

 

Turns out that the "missing" lines from the projected isect groups are controlled by the "cutLinePen" and "cutLineType" of the 1st half of the command. This muddles up section and projection in a most unwanted way - must be seen as a bug. At least it makes the otherwise brilliant command useless to what I need to achieve.

Dear Peter

Meanwhile You can do next: in 3d script:

 

if glob_view_type=2 then....

***here You put the simplified model for 2d projection only***

else

*** normal model***

endif

Now it projects a different 3d model in a way You want.the real model look like in 2d.

- AC-24 FIN - WIN 10 - HP Zbook -
“A winner is just a loser who tried one more time.”
George M. Moore, Jr.

Thank you! However, the model I would have liked to project would have been one with intersected groups. Now an alternative solution for the intersection needs to be found...

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!