用Java中的AutoCAD库来读取.dwg文件? [英] AutoCAD library in Java to read .dwg files?
问题描述
是否有任何开源Java或JavaScript库可用于解析.dwg文件并从中获取对象。
Is there any open-source Java or JavaScript library available to parse .dwg files and get the objects from it.
我想从表中提取数据我的项目的文字。
I would like to extract data from a table of text for my project.
似乎AutoCAD开发人员社区更喜欢.NET和C / C ++而不是JAVA。
It seems that the AutoCAD developer community prefers .NET and C/C++ over JAVA.
我找到的唯一免费替代方法是首先将.dwg转换为.dxf并使用Kabeja lib从中读取。
The only free alternative I found is by converting .dwg to .dxf first and using the Kabeja lib to read from it.
推荐答案
所有已回复的人都有信用,我已经测试了你所有的命题,这是我发现的,截至2015年:
Credits to all who have answered, I've tested all your proposition and here's what I've found , as of 2015:
目前还没有免费且可靠的解决方案来读取和操作.dwg和.dxf文件。这尤其适用于最新版本的AutoCAD,例如:Autocad 2010,Autocad 2013等,RF 2013,RF 2010。
There is currently no free AND reliable solution to read and manipulate .dwg and .dxf files. This applies especially to latest versions of AutoCAD, ex : Autocad 2010, Autocad 2013 etc, RF 2013, RF 2010.
可靠(且价格昂贵)的解决方案将是Teigha by ODA (2000美元一年)和RealDWG在C#by Autocad(每年5000美元)...
Reliable (and expensive) solutions would be Teigha by ODA (2000$ a year) and RealDWG in C# by Autocad (5000$ a year)...
更便宜的替代品是这样的:
Cheaper alternatives are as such :
- AutoCAD I / O每月10美元(由Augusto Gonclaves建议),但现在功能有限。
- 编写LISPS例程并在AutoCAD 2015/2016的付费实例中使用SCRIPT文件运行它们。
- 等待更完整的实施AutoCad核心控制台..
Kabeja和YCad等开源库可能能够处理较旧的AutoCAD版本,但不要指望这些项目自几年前开始就处于非活动状态。值得关注的是Apache Tika,因为他们开始为.dwg文件编写解析器,但开发速度很慢。
Open-source libraries such as Kabeja and YCad may be able to deal with older AutoCAD versions but do not expect much from them as these projects are inactive since a few years ago. It's worth to keep an eye out for Apache Tika though, since they started writing parsers for .dwg files but development has been slow.
在个人方面,我认为AutoDesk现在在CAD市场上拥有强大而自私的垄断地位,并且他们很难让其他人加入。格式的.dwg文件版本经常变化,我想开源开发人员将不得不在某些时候放弃请改用官方产品。
On a personal note, I think that AutoDesk has a strong and selfish monopoly on the CAD market now and they are making it difficult for others to join in. The format's version of .dwg files changes so often and I guess open-source developers will have to give up at some point and use the official product instead.
让我们希望在未来几年内有更多的开源解决方案
Let's hope for more open-source solutions in the coming years
这篇关于用Java中的AutoCAD库来读取.dwg文件?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!