using Data from 2D section for 3D cut
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
2020-07-16
07:39 PM
- last edited on
2022-09-26
10:48 PM
by
Daniel Kassai
When I create a vertical section through the window then the 3D data is cut. And the result is not what I want for a vertical section view.
Is there a possibility to show data from the 2D section instead?
Solved! Go to Solution.
- Labels:
-
Library (GDL)
Accepted Solutions
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
2020-07-16 07:45 PM
If you want a correct section representation, you will have to create the correct 3d geometry.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
2020-07-16 07:45 PM
If you want a correct section representation, you will have to create the correct 3d geometry.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
2020-07-16 10:15 PM
How is this possible?

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
2020-07-17 12:39 AM
The 2D and 3D components of any GDL object are completely separate unless you use the "Project2" command which generates the 2D from a projection of he 3D, though it is not advised as it slows regeneration.
If you want the section to be a more simplified representation of your detailed 3D geometry then you need to rationalise the geometry for that view (sections are a live 3D view). you do this by using the GLOB_VIEW_TYPE function to hide/simplify the pieces of 3D geometry you don't want to see in section.
for example, let say you have 4 pieces of geometry that make up the frame profile in 3D but in section you only want to see the main piece. then your code will look like this:
Geometry 1 (actual GDL script just represented by the term Geometry for this post) if GLOB_VIEW_TYPE # 4 then Geometry 2 Geometry 3 Geometry 4 endifGLOB_VIEW_TYPE 4 is for sections (refer to GDL manual for the rest, and don use this function in the parameter script)
# stands for "not equal to"
So in plain English (far less efficient) it reads:
execute Geometry 1
if the view is NOT a section view then
execute Geometry 2
execute Geometry 3
execute Geometry 4
You can also be far more clever with this function and simplify a single complex shape by using the PUT and GET functions to define the shape as this allows you to define the points of the shape prior to the shape command hence adding conditions to the points.
for example a C channel can be made into a simple rectangle as follows:
HEIGHT = 2.100 WIDTH = .050 DEPTH = .100 THICK = .002 put 0, 0, 15 put WIDTH, 0, 15 if GLOB_VIEW_TYPE # 4 then put WIDTH, THICK, 15 put THICK, THICK, 15 put THICK, DEPTH -THICK, 15 put WIDTH, DEPTH -THICK, 15 endif put WIDTH, DEPTH, 15 put 0, DEPTH, 15 prism_ nsp/3, HEIGHT, get(nsp)it super easy and as you can see it gives you the ability to make your geometry responsive to all sorts of conditions.
personally i always use the PUT and GET functions for my geometry as it means i don't have to keep changing the value that sets the number of nodes (which gets frustrating) as i can use the "nsp/3" instead. But the main reason is it allows me to make the geometry far more conditional.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
2020-07-24 03:02 PM
With if GLOB_VIEW_TYPE = 4 then I know, if I am in a section view.
Would it be possible to recognize the direction of the 3D section?
I would like to know if a window is cut perpendicular.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
2020-07-26 05:18 PM
Martin wrote:
Hi, many thanks for your response!
With if GLOB_VIEW_TYPE = 4 then I know, if I am in a section view.
Would it be possible to recognize the direction of the 3D section?
I would like to know if a window is cut perpendicular.
Not possible that I am aware of.
Barry.
Versions 6.5 to 27
i7-10700 @ 2.9Ghz, 32GB ram, GeForce RTX 2060 (6GB), Windows 10
Lenovo Thinkpad - i7-1270P 2.20 GHz, 32GB RAM, Nvidia T550, Windows 11