LEADTOOLS Support
Imaging
Imaging SDK Examples
HOW TO: Load a Vector File as a RasterImage using the CDLL interface
#1
Posted
:
Tuesday, December 30, 2008 6:22:27 AM(UTC)
Groups: Registered, Tech Support, Administrators
Posts: 764
Currently, the .NET interface does not support loading or saving vector files. However, if you want to convert a vector file to raster but you prefer to use the .NET interface, it is possible to use the CDLL interface to load and convert the vector file to a BITMAPHANDLE which can then be converted into a RasterImage. Attached is a VB.NET 2005 demo shows how to do this in version 15.
__________________________
Moderator note:
V17.5 supports converting vector files to raster bitmaps. See post dated 08-17-2012 in this thread.
#2
Posted
:
Tuesday, December 30, 2008 6:23:32 AM(UTC)
Groups: Registered, Tech Support, Administrators
Posts: 764
Here's the same project but for version 16. It is practically the same, but the BITMAPHANDLE structure had to be updated since it is slightly different in v16. If you try to use the same structure as in v15, you will get an Invalid Structure Size error.
#3
Posted
:
Wednesday, June 17, 2009 6:39:53 AM(UTC)
Groups: Guests
Posts: 3,022
Was thanked: 2 time(s) in 2 post(s)
This project is the same project as above, except it has been converted to C#, and there is an added feature of saving the image to disk as a BMP. It has been tested with 16.5. It will work with both 16 and 16.5.
#4
Posted
:
Wednesday, September 1, 2010 4:59:49 AM(UTC)
Groups: Tech Support
Posts: 366
Thanks: 1 times
Was thanked: 4 time(s) in 4 post(s)
This project has been updated to use the LEADTOOLS 17 dlls and Visual Studio 2008.
I'm modified the original slightly to use the RasterSaveDialog to specify the type of file to save. This will make it easier for updating the project to save out different types of raster files. To update the demo to save a different file format, first add the necessary file format dlls to the project for that file format (for a list of necessary dlls, see the help file topic "Files to be Included With Your Application"). Then add the format to the saveFileDialogFormatList collection.
Walter Bates
Senior Support Engineer
LEAD Technologies, Inc.
#5
Posted
:
Friday, August 17, 2012 10:33:08 AM(UTC)
Groups: Tech Support
Posts: 366
Thanks: 1 times
Was thanked: 4 time(s) in 4 post(s)
Rasterizing vector file in .NET is now natively supported with LEADTOOLS v17.5. Attached is a small sample project illustrating supporting loading vector files with .NET. The project is built with VS 2008 targeting the .NET 2.0 framework.
Please note that you will need build 17.5.0.31 or later of the Leadtools.Codecs.dll and Leadtools.Vector.dll build 17.5.0.2 or later.
For questions or concerns regarding this support including where to download the latest v17.5 DLLs, please email
support@leadtools.com.
Walter Bates
Senior Support Engineer
LEAD Technologies, Inc.
#6
Posted
:
Tuesday, October 3, 2017 11:02:52 AM(UTC)
Groups: Registered, Tech Support, Administrators
Posts: 199
Was thanked: 28 time(s) in 28 post(s)
Updated to LEADTOOLS v19 with Visual Studio 2017. Also changed project to automatically select dll's for running in 32-bit and 64-bit.
Extract to "C:\LEADTOOLS 19\Examples\DotNet\CS\" to use the example.
There is an included DXF file ("CS_LoadVector.dxf") for testing, copy to the "LEADTOOLS Images" directory ("C:\Users\Public\Documents\LEADTOOLS Images\") before running.
Anthony Northrup
Developer Support Engineer
LEAD Technologies, Inc.
LEADTOOLS Support
Imaging
Imaging SDK Examples
HOW TO: Load a Vector File as a RasterImage using the CDLL interface
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.