Hey,
I am attempting to parse two word documents that I have attached. One is in .doc format and the other is in the .docx format. My goal is to convert the gif formatted image to a png formatted image.
In the .doc file, it appears that the image gets identified by the ImageType.PNG type. However, in the .docx file, it is coming through as ImageType.UNKNOWN. Unfortunately, this prevents me from correctly identifying the image type and saving it as a .png.
According to this post, .gif images should be converted to .png images at load time. Is this not happening in .docx documents correctly?
I have reproduced this on version 11.7.0 and 13.3.0.1. I arrive at this issue as follows:
- visitShapeStart(Shape shape) is called
- com.aspose.words.ImageData data = shape.getImageData();
- ImageType.UNKNOWN == data.getImageType();
Expected Result:
data.getImageType() == ImageType.PNG in .doc and .docx files for .gif images.
Any help on this matter would be greatly appreciated!
Thanks,