IGES File
Moderators: SDS, support, admin
-
- Posts: 54
- Joined: 14 Mar 2015, 22:33
IGES File
Hello,
After load a IGES .igs file with the help of Open Cascade dll, is possible get the tree structure of the filen in xml format or in memory for visualization with a tree component?
Thanks!!!
After load a IGES .igs file with the help of Open Cascade dll, is possible get the tree structure of the filen in xml format or in memory for visualization with a tree component?
Thanks!!!
Re: IGES File
Hello,
To get a tree structure of any drawing file (IGES, DWG, DXF, etc.) for visualization with a tree component (e.g. TTreeView), you will have to iterate through entities in the given file and add each entity to the structure using the following recursive procedure:
Could you please specify what objects you need to get from an IGES file for visualization with a tree component?
Mikhail
To get a tree structure of any drawing file (IGES, DWG, DXF, etc.) for visualization with a tree component (e.g. TTreeView), you will have to iterate through entities in the given file and add each entity to the structure using the following recursive procedure:
Code: Select all
uses
..., ComCtrls;
type
tvStructure: TTreeView;
...
implementation
{$R *.dfm}
...
procedure Add(Parent: TTreeNode; E: TsgDXFEntity);
var
I: Integer;
begin
if Assigned(E) then
begin
Parent := tvStructure.Items.AddChildObject(Parent, E.EntName, E);
Application.ProcessMessages;
for I := 0 to E.Count - 1 do Add(Parent, E[I]);
end;
end;
Mikhail
Technical Support E-mail: support@cadsofttools.com
Chat support on Skype: cadsofttools.support
Chat support on Skype: cadsofttools.support
-
- Posts: 54
- Joined: 14 Mar 2015, 22:33
Re: IGES File
Hi Mikhail,
The full story is as follows:
I'm working with IFC files, from Revit, IFC format programming is a bit long to do, for now, and the programming of IFCXml or IFC to Xml is not as exhaustive, it requires a lot of code.
One solution that I am testing is to convert the IFC files (linear format) to IGES format and in that way obtain the structure of objects.
I must find the best solution to work with IFC files and show their structure in a tree and visualize their objects in the navigator, for constructive analysis.
Thanks for the information!!!
Felipe.
The full story is as follows:
I'm working with IFC files, from Revit, IFC format programming is a bit long to do, for now, and the programming of IFCXml or IFC to Xml is not as exhaustive, it requires a lot of code.
One solution that I am testing is to convert the IFC files (linear format) to IGES format and in that way obtain the structure of objects.
I must find the best solution to work with IFC files and show their structure in a tree and visualize their objects in the navigator, for constructive analysis.
Thanks for the information!!!
Felipe.
Re: IGES File
Felipe,
If you want to retain specific IFC objects when converting an .ifc file to IGES, I'm afraid that it is not possible, because the IGES standard defines a different kind of objects: edges, faces, loops, etc. So, depending on what objects you need to get, IFC -> IGES conversion may be appropriate or not appropriate solution.
Mikhail
If you want to retain specific IFC objects when converting an .ifc file to IGES, I'm afraid that it is not possible, because the IGES standard defines a different kind of objects: edges, faces, loops, etc. So, depending on what objects you need to get, IFC -> IGES conversion may be appropriate or not appropriate solution.
Mikhail
Technical Support E-mail: support@cadsofttools.com
Chat support on Skype: cadsofttools.support
Chat support on Skype: cadsofttools.support