Annotations Breaking nconvert for .MAG files

Discussions on NConvert - the command line tool for image conversion and manipulation

Moderators: XnTriq, xnview

qdean
Posts: 3
Joined: Wed Dec 11, 2019 2:47 pm

Annotations Breaking nconvert for .MAG files

Post by qdean »

I'm using nconvert for a multimillion document extraction and conversion from a Document management system called Fortis.
The nconvert tool has been taking these document types like a champ and converting them to compression 4 tiffs, but after increasing my sample size in Test I'm starting to run into issues.

Certain documents give me this error:
my_error_exit...<Not a JPEG file: starts with 0x57 0x54>
Error: Don't know how to read this picture (\\ITRECORDS\ARCHIVE\ACC\WTI1C0\0001C0DE.MAG)

I believe some of this is the way Fortis saves their annotation information. (Which is bad practice I know) After running some of the erroring documents through a hex editor I get annotation information in the header or I see there are annotations on the document. I'm still looking into it and trying to figure out how annotations get stored on these MAG files so maybe I can strip them out.

My question is, is there anyway we can re-mediate this? Have you guys seen this issue before? Is there a way to detect annotations and strip them from the document?
cday
XnThusiast
Posts: 3074
Joined: Sun Apr 29, 2012 9:45 am
Location: Cheltenham, U.K.

Re: Annotations Breaking nconvert for .MAG files

Post by cday »

You could possibly upload a sample file, if you are able to, that illustrates the problem for Pierre -- the only developer of all XnView software -- to have a look at if he has time...

Otherwise, you could possibly try the following option:

Code: Select all

-ignore_errors    : Ignore errors
... a rather long shot, I would think!
qdean
Posts: 3
Joined: Wed Dec 11, 2019 2:47 pm

Re: Annotations Breaking nconvert for .MAG files

Post by qdean »

Thanks for the quick response.

Absolutely! That's my intention. I got with my team (waiting to hear back) to make sure I'm grabbing a file that doesn't have sensitive information on it.

Yeah I did try the ignore errors flag and it still doesn't like it.
qdean
Posts: 3
Joined: Wed Dec 11, 2019 2:47 pm

Re: Annotations Breaking nconvert for .MAG files

Post by qdean »

The batch of files that broke for nconvert also broke under another file conversion. After more testing it looks like a number of these files are not just images but PDFs and MS Word Documents wrapped in this file type of MAG.

How does nconvert identify files? Is it just searching for an image?
caracol
Posts: 1
Joined: Wed Jan 13, 2021 1:41 pm

Re: Annotations Breaking nconvert for .MAG files

Post by caracol »

Was this issue resolved in version 7.60? I am planning to use this program to convert Fortis images and wanted to know if this situation has been resolved.
User avatar
xnview
Author of XnView
Posts: 36389
Joined: Mon Oct 13, 2003 7:31 am
Location: France

Re: Annotations Breaking nconvert for .MAG files

Post by xnview »

caracol wrote: Wed Jan 13, 2021 1:53 pm Was this issue resolved in version 7.60? I am planning to use this program to convert Fortis images and wanted to know if this situation has been resolved.
Seems to be fixed in 7.41
Pierre.