Ok the quick glance is more focused now.
There is some components:
- Document.xml that contain what seems to be the treeview
- GuiDocument.xml that seem to contain the View Part of the file
- a Bunch fo brp files that seem to adhere to https://www.opencascade.com/doc/occt-6.7.0/overview/html/occt_brep_format.html that is quite obvious the internal 3D representation in the "native " format oof the CAD engine
- some other DiffuseColor… that I suspect contains the color used by the View part
- Edges file, that seems compressed
I suspect that it will be not very difficult to extend the format using maybe a DXF file for the TechDraw Part, and some glue to relate the two files.
Simply for not “reinventing the wheel” everytime a function is needed.
On the other side FreeCAD is already a “collage” of different pieces of Software, OCCT, Coin3D, VTK, QT5 and Python mainly, finding a library that is more taylored to support the needed function, like the Path workbench has done for the CAM part, (from my point of view in a ugly and overcomplicated manner)
will be a more viable solution than trying to mimic these function.
XML file is goog ad easy parseable, but maybe making it too big will result in a bottleneck.
if the TreeView is kept in the Document.xml and the other functions, in a similar manner in what is done with the OCCT brp files maybe it will be an improvement.
If I’m in need to modify the 3D part, i use only the 3D infors, if this 3D part is derived from a 2D part, there will be a mechanism that tell the 2D part that the 3D representation is modified, but for this i don’t know the workflow.
Having seen what the BIM workbench is trying to achieve, what is the workflow, i draw the 2D design of the floor and then from the information on the 2D object i derive the 3D part, but to have this the document has to contain all the infos, and from what i see it is more the inverse, from a 3D solid i could derive the 2D draft, using the projection.
This is a clear place where more discussion will be useful and for the “file part” a broad talk with main developers, is needed.
Regards
Carlo D.



