ImageEn for Delphi and C++ Builder ImageEn for Delphi and C++ Builder

 

ImageEn Forum
Profile    Join    Active Topics    Forum FAQ    Search this forumSearch
Forum membership is Free!  Click Join to sign-up
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 ImageEn Library for Delphi, C++ and .Net
 ImageEn and IEvolution Support Forum
 Demo for reading SVG
 New Topic  Reply to Topic
Author Previous Topic Topic Next Topic  

sn00py

Austria
3 Posts

Posted - Dec 16 2014 :  02:14:29  Show Profile  Reply
Hello

Is there samewhere a Demo for reading and showing (and printing) SVG Files?

I am searching a library for that.

regards
andi

xequte

38608 Posts

Posted - Dec 16 2014 :  17:01:23  Show Profile  Reply
Hi Andi

ImageEn will load, display and print SVG files if either:
- The ImageMagick DLL exists in the EXE folder (download from the registered users page)
- ImageMagick has been installed on the system (this is the newer method)

Note: Your application must call IEAutoLoadIOPlugins

See also:

http://www.imageen.com/ieforum/topic.asp?TOPIC_ID=316

Nigel
Xequte Software
www.xequte.com
nigel@xequte.com
Go to Top of Page

sn00py

Austria
3 Posts

Posted - Dec 17 2014 :  00:01:45  Show Profile  Reply
Hmmm
I didn't get it to work :(

I just installed ImageMagick from the webpage ... and than i copied the demo apps into the same directory where all DLL are (many CORE_RL_*.dll) but still see no SVG in the open dialog - waht is going wrong?
Go to Top of Page

xequte

38608 Posts

Posted - Dec 17 2014 :  01:35:38  Show Profile  Reply
Hi

You need to use a demo that calls IEAutoLoadIOPlugins on start-up, so use the "Camera Raw Files" demo at:

http://www.imageen.com/demos/#InputOutput

Also, ensure the ImageMagick version you installed matches the bitness of the application. The demo is 32bit, so ensure you have installed the 32bit version of ImageMagick.


Nigel
Xequte Software
www.xequte.com
nigel@xequte.com
Go to Top of Page

sn00py

Austria
3 Posts

Posted - Dec 17 2014 :  01:45:56  Show Profile  Reply
Okey now i can open my SVG but the quility isn't good :(

If i zoom into the SVG i see following
http://www.directupload.net/file/d/3839/4h2mp4qa_png.htm

These are all pathes.

Is it a problem with zomming into the page?
Go to Top of Page

spetric

Croatia
308 Posts

Posted - Dec 17 2014 :  02:12:20  Show Profile  Reply
Hi,

In ImageEn (using ImageMagick.dll), SVG is loaded "as is" and rendered as raster image. You can not manipulate SVG the same way as with Inkscape, or some other vector drawing program. When you zoom in, you're actually zooming raster image.

In order to "natively" manipulate SVG (zoom, translate, rotate), you should use some 3rd party library, like "Anti grain geometry": http://antigrain.com/index.html

There is also a pascal port of this library: http://www.crossgl.com/aggpas/

Libraries come with source code under public licence, so maybe you can adapt source code to render SVG onto ImageEnView canvas.

Edit: There is also VCL style version of aggpas (XE1/XE2):
http://sourceforge.net/projects/aggpasmod/
Go to Top of Page

xequte

38608 Posts

Posted - Nov 27 2023 :  15:54:40  Show Profile  Reply
Also note that SVG loading is now automatically supported on Delphi 12 and newer if you add Vcl.Skia to the uses clause of any unit in your project.

Nigel
Xequte Software
www.imageen.com
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
Jump To: