CADImport.NET and SvgNet
Moderators: SDS, support, admin
CADImport.NET and SvgNet
Hello,
I have a CADImport.Net related issue, that I hope can be resolved with your help:
I am using CADImport.Net and intended to convert a DWG file to SVG format by reading the DWG with CADImport.Net and writing it with the free SVG library SvgNet (http://www.codeproject.com/csharp/svgnet.asp) to SVG format. SvgNet provides a GDI+ to SVG bridge (SvgGraphics), that uses the *exact* same interface as a GDI+ System.Drawing.Graphics object that does not render to the screen but outputs an SVG file.
Unfortunately, the Graphics class is a sealed class, so the SvgGraphics class cannot be a direct subclass of the Graphics class. As a result an SvgGraphics object cannot be passed to the CADImport.Net CADImage.Draw() method, despite the fact that it provides the exact same methods as System.Drawing.Graphics.
To resolve this problem, I could imagine, that CADImport.Net provides an interface that is similar or identical to the System.Drawing.Graphics class, that is supported by a CadImage.Draw method. Using this interface I would be able to write a wrapper for the SvgGraphics class and use CadImport.Net to output SVG graphics.
Do you see any opportunity that CADImport.Net could support such functionality and open up new possibilities (not only for this issue) regarding the application area of CADImport.Net?
Thanks in advance,
Nicolas Goell
I have a CADImport.Net related issue, that I hope can be resolved with your help:
I am using CADImport.Net and intended to convert a DWG file to SVG format by reading the DWG with CADImport.Net and writing it with the free SVG library SvgNet (http://www.codeproject.com/csharp/svgnet.asp) to SVG format. SvgNet provides a GDI+ to SVG bridge (SvgGraphics), that uses the *exact* same interface as a GDI+ System.Drawing.Graphics object that does not render to the screen but outputs an SVG file.
Unfortunately, the Graphics class is a sealed class, so the SvgGraphics class cannot be a direct subclass of the Graphics class. As a result an SvgGraphics object cannot be passed to the CADImport.Net CADImage.Draw() method, despite the fact that it provides the exact same methods as System.Drawing.Graphics.
To resolve this problem, I could imagine, that CADImport.Net provides an interface that is similar or identical to the System.Drawing.Graphics class, that is supported by a CadImage.Draw method. Using this interface I would be able to write a wrapper for the SvgGraphics class and use CadImport.Net to output SVG graphics.
Do you see any opportunity that CADImport.Net could support such functionality and open up new possibilities (not only for this issue) regarding the application area of CADImport.Net?
Thanks in advance,
Nicolas Goell
Hello Nicolas,
We need a little time for estimating this library to find out what is possible to do.
Sergey.
Please post questions to the forum or write to support@cadsofttools.com
We need a little time for estimating this library to find out what is possible to do.
Sergey.
Please post questions to the forum or write to support@cadsofttools.com
Hello Nicolas,
Library <b>SvgNet</b> contains it's own interface IGraphics which inherits no one standard interface of FrameWork. This fact presumes valuable difficulties in realisation of <b>Draw</b> method for this interface in the context <b>CAD Import .NET</b>.
However this task can be solved like a separate project, using sources of <b>CAD Import .NET</b>
Sergey.
Please post questions to the forum or write to support@cadsofttools.com
Library <b>SvgNet</b> contains it's own interface IGraphics which inherits no one standard interface of FrameWork. This fact presumes valuable difficulties in realisation of <b>Draw</b> method for this interface in the context <b>CAD Import .NET</b>.
However this task can be solved like a separate project, using sources of <b>CAD Import .NET</b>
Sergey.
Please post questions to the forum or write to support@cadsofttools.com