Recent

Author Topic: LibreDWG with fpc?  (Read 1869 times)

zamtmn

  • Hero Member
  • *****
  • Posts: 594
LibreDWG with fpc?
« on: June 08, 2022, 07:29:21 pm »
Hi!
Does anyone use LibreDWG to read/write DWG files?
Usage examples?

MarkMLl

  • Hero Member
  • *****
  • Posts: 6692
Re: LibreDWG with fpc?
« Reply #1 on: June 08, 2022, 08:16:46 pm »
Use the forum search facility, it's been discussed a couple of times.

MarkMLl
MT+86 & Turbo Pascal v1 on CCP/M-86, multitasking with LAN & graphics in 128Kb.
Pet hate: people who boast about the size and sophistication of their computer.
GitHub repositories: https://github.com/MarkMLl?tab=repositories

zamtmn

  • Hero Member
  • *****
  • Posts: 594
Re: LibreDWG with fpc?
« Reply #2 on: June 08, 2022, 08:29:44 pm »
I have not find meaningful discussions, just the name was mentioned several times

MarkMLl

  • Hero Member
  • *****
  • Posts: 6692
Re: LibreDWG with fpc?
« Reply #3 on: June 08, 2022, 08:53:52 pm »
...by yourself in at least one case. Sorry, I should have followed through the context more.

MarkMLl
MT+86 & Turbo Pascal v1 on CCP/M-86, multitasking with LAN & graphics in 128Kb.
Pet hate: people who boast about the size and sophistication of their computer.
GitHub repositories: https://github.com/MarkMLl?tab=repositories

zamtmn

  • Hero Member
  • *****
  • Posts: 594
Re: LibreDWG with fpc?
« Reply #4 on: June 11, 2022, 02:14:44 am »
Ok. I'll try to do something https://github.com/zamtmn/fpdwg

amir.eng

  • Full Member
  • ***
  • Posts: 101
Re: LibreDWG with fpc?
« Reply #5 on: June 27, 2022, 09:41:23 am »
Hello zamtmn,

I need a library to read/write DWG via Lazarus too , and I have been looking for it for years , but I couldn't find anything.
Let me know if you find any usful things.

Thanks in advance.
« Last Edit: July 20, 2022, 06:47:30 am by amir.eng »
Lazarus 3.0 , FPC 3.2.2 , Windows 10 64, Excel 2016 64

zamtmn

  • Hero Member
  • *****
  • Posts: 594
Re: LibreDWG with fpc?
« Reply #6 on: June 28, 2022, 12:03:11 am »
amir.eng
LibreDWG, according to my observations, is managed with non-complex files. I managed to read the file and iterate through all the objects in it. I haven't tried write dwg yet. There is a difficulty in translating headers - macros are actively used
« Last Edit: June 28, 2022, 12:08:55 am by zamtmn »

amir.eng

  • Full Member
  • ***
  • Posts: 101
Re: LibreDWG with fpc?
« Reply #7 on: July 18, 2022, 07:32:07 am »
amir.eng
LibreDWG, according to my observations, is managed with non-complex files. I managed to read the file and iterate through all the objects in it. I haven't tried write dwg yet. There is a difficulty in translating headers - macros are actively used

I dont need all library of LibreDWG, I need it only for points, assume there is a point includes X,Y,Z and I want to create a simple dwg for the coordinate via lazarus.
« Last Edit: July 18, 2022, 07:33:43 am by amir.eng »
Lazarus 3.0 , FPC 3.2.2 , Windows 10 64, Excel 2016 64

zamtmn

  • Hero Member
  • *****
  • Posts: 594
Re: LibreDWG with fpc?
« Reply #8 on: July 18, 2022, 09:36:36 am »
Unfortunately, everything has been done in dwg to complicate it third-party use.
You can write the reading yourself by spending a lot of effort. I tried, it's hopeless. Only use ready-made tools with their problems and limitations((

alaa123456789

  • Sr. Member
  • ****
  • Posts: 260
  • Try your Best to learn & help others
    • youtube:
Re: LibreDWG with fpc?
« Reply #9 on: July 18, 2022, 08:10:33 pm »
i was looking for Autocad solutions and found something called .scr files which is scripting language in autocad here some sample
https://www.researchgate.net/profile/Mahesh-Luintel/publication/332493976_USE_OF_SCRIPT_FILES_IN_AUTOCAD/links/5cb7e8e7299bf120976cd8e6/USE-OF-SCRIPT-FILES-IN-AUTOCAD.pdf

maybe you could do more research and make demo
thanks

zamtmn

  • Hero Member
  • *****
  • Posts: 594
Re: LibreDWG with fpc?
« Reply #10 on: September 01, 2022, 03:58:31 pm »
i was looking for Autocad solutions and found something called .scr files which is scripting language in autocad here some sample
https://www.researchgate.net/profile/Mahesh-Luintel/publication/332493976_USE_OF_SCRIPT_FILES_IN_AUTOCAD/links/5cb7e8e7299bf120976cd8e6/USE-OF-SCRIPT-FILES-IN-AUTOCAD.pdf

maybe you could do more research and make demo
thanks
these are all half-measures, we need the ability to fully read and write dwg

loaded

  • Hero Member
  • *****
  • Posts: 825
Re: LibreDWG with fpc?
« Reply #11 on: September 01, 2022, 05:55:15 pm »
If a solid source with specifications for the dwg format is found, it can be read in binary format. I think it is not very difficult, but it will definitely take a lot of time and effort.
Not now, but at a convenient time, I intend to read this format. (bottom of my To Do List)  :)
Check out  loaded on Strava
https://www.strava.com/athletes/109391137

krolikbest

  • Full Member
  • ***
  • Posts: 247
Re: LibreDWG with fpc?
« Reply #12 on: September 01, 2022, 08:05:32 pm »
You may to convert a dwg to dxf
« Last Edit: September 01, 2022, 08:07:56 pm by krolikbest »

zamtmn

  • Hero Member
  • *****
  • Posts: 594
Re: LibreDWG with fpc?
« Reply #13 on: September 01, 2022, 09:10:25 pm »
ODA DWG specs: https://www.opendesign.com/files/guestdownloads/OpenDesign_Specification_for_.dwg_files.pdf
Specifications are not complete, format is very complex, much has been done to make access difficult.
But yes, anything is possible. I once get access to primitives for DWG version 2000.

And now I think it's better to use a third-party library and help in its development than to do my own implementation

 

TinyPortal © 2005-2018