Hi there,
We have an issue with EMF to SVG conversion on Linux/Unix servers.
When we try to convert the attached EMF image to SVG, the conversion is unsuccessful with very generic error “Cannot find any fonts installed on the system”, it never prints the font details that caused this exception.
Can we have the font details logged along with the exception that caused this issue ?
Code Snippet :
String dataDir = "C:\\emf-with-svg-content\\";
Image image = Image.load(dataDir + "image9.emf", new MetafileLoadOptions(true));
try {
// Create an instance of EmfRasterizationOptions class and set
// different options
final EmfRasterizationOptions emfRasterizationOptions = new EmfRasterizationOptions();
emfRasterizationOptions.setPageWidth(image.getWidth());
emfRasterizationOptions.setPageHeight(image.getHeight());
// call the save method and pass instance of SvgOptions class to
// convert it to SVG format.
image.save(dataDir + "image9.svg", new SvgOptions() {
{
setVectorRasterizationOptions(emfRasterizationOptions);
}
});
} finally {
image.dispose();
}
Exception log :
|ERROR|5308028|ImageGenerationUtil|Exception while converting the image image8.emf->
com.aspose.imaging.coreexceptions.ImageSaveException: Image export failed.
at com.aspose.imaging.Image.a(Unknown Source)
at com.aspose.imaging.Image.save(Unknown Source)
at com.aspose.imaging.Image.save(Unknown Source)
at com.citi.icg.rendition.conversion.document.util.ImageGenerationUtil.convertEMFOrWMFImage(ImageGenerationUtil.java:469)
at com.citi.icg.rendition.conversion.document.util.ImageGenerationUtil.saveEMFOrWMFImage(ImageGenerationUtil.java:161)
.
.
.
.
at com.citi.icg.rendition.conversion.document.DocumentGenerator.generateJson(DocumentGenerator.java:86)
at com.citi.icg.rendition.conversion.document.DocumentGenerator.converttoJsonExternal(DocumentGenerator.java:860)
at com.citi.icg.rendition.conversion.document.DocumentGenerator$$FastClassBySpringCGLIB$$93f6e5fc.invoke()
at org.springframework.cglib.proxy.MethodProxy.invoke(MethodProxy.java:204)
at org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.invokeJoinpoint(CglibAopProxy.java:736)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:157)
at com.citi.icg.rendition.util.MethodLoggingInterceptor.invoke(MethodLoggingInterceptor.java:92)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179)
at org.springframework.aop.interceptor.ExposeInvocationInterceptor.invoke(ExposeInvocationInterceptor.java:92)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179)
at org.springframework.aop.framework.CglibAopProxy$DynamicAdvisedInterceptor.intercept(CglibAopProxy.java:671)
at com.citi.icg.rendition.conversion.document.DocumentGenerator$$EnhancerBySpringCGLIB$$163bc93c.converttoJsonExternal()
at com.citi.icg.rendition.service.ConversionExecutor.convert(ConversionExecutor.java:101)
at com.citi.icg.rendition.service.ConversionExecutor.main(ConversionExecutor.java:36)
Caused by: com.aspose.imaging.internal.Exceptions.InvalidOperationException: Cannot find any fonts installed on the system.
at com.aspose.imaging.internal.Y.j.a(Unknown Source)
at com.aspose.imaging.internal.Y.j.a(Unknown Source)
at com.aspose.imaging.internal.Y.j.a(Unknown Source)
at com.aspose.imaging.internal.eQ.b.a(Unknown Source)
at com.aspose.imaging.internal.eO.b.e(Unknown Source)
at com.aspose.imaging.internal.eO.b.a(Unknown Source)
at com.aspose.imaging.internal.eO.b.a(Unknown Source)
at com.aspose.imaging.internal.eN.c.a(Unknown Source)
at com.aspose.imaging.internal.dV.q.a(Unknown Source)
at com.aspose.imaging.internal.dV.q.a(Unknown Source)
at com.aspose.imaging.internal.dV.q.a(Unknown Source)
at com.aspose.imaging.internal.dV.q.a(Unknown Source)
at com.aspose.imaging.internal.dV.D.b(Unknown Source)
at com.aspose.imaging.internal.dV.a.a(Unknown Source)
at com.aspose.imaging.internal.dV.a.export(Unknown Source)
… 49 common frames omitted
images.zip (129.1 KB)