Create a dwg in thumbnail in linux environment

Create a ruby ​​on the rails website that uses RMagick to create thumbnails for many types of images. However, RMagick cannot read dwg files.

I tried a few things, looked into the Java JDWGLib library, which would probably allow me to write a converter, but that would be common from scratch, where I just need a sketch.

Using a viewer to open a file in a remote X session and capture the screen is also considered, however I'm not sure how I could guarantee that the viewer finished opening when I took a screenshot.

I am not interested in manipulating a file other than creating a thumbnail. It will be used for commercial purposes, so any libraries used must be compatible.

+7
linux ruby-on-rails imagemagick thumbnails dwg
source share
2 answers

cad2svg is a simple Linux command line utility that automatically converts AutoCAD files (both dwg and dxf) to SVG.

link

+3
source share

I could not find any command line tool for creating thumbnails on any of the windows or Linux.

I think you could download the DWGdirect lib (C ++), which allows you to export DWG to a bitmap ... but this requires the purchase of a license for membership in the "" "Open" "" Design Alliance.

I would recommend adding an additional file to your form that says thumbnail. And let users provide screenshots.

0
source share

All Articles