You are viewing limited content. For full access, please sign in.

Question

Question

Can't upload jpg files from iOS to Cloud Forms?

asked on November 30, 2021

A user uploaded a jpg file to a form from an iOS device, as shown by the title ending in _iOS.jpg

When the process tries to save it to the repository, it fails every time with this error:

Lfi_GetFileInfo failed.(Stream: length 2518515)(HRESULT: 0x88982F07 : WINCODEC_ERR_UNKNOWNIMAGEFORMAT)

When I was first told of this issue, I assumed the user was using the proprietary image format .heic, but that format actually saves to the repository without an issue.

Is this a known restriction in Cloud?

0 0

Answer

SELECTED ANSWER
replied on November 30, 2021

If I'm parsing what you said there correctly, it sounds like the user may have renamed a .heic file to have a .jpg extension without actually converting it to the jpeg format. The Windows Imaging Component library then correctly threw an image format error upon being handed a ".jpg" file with .heic headers and encoding.

1 0

Replies

replied on November 30, 2021

Hi Brian,

Even though the error message says "Unknown Image Format", it's highly unlikely there's an inherent issue with the jpg file format as a whole here. It's much for likely something abnormal with that specific file is tripping a rare bug.

This error message comes from an underlying Microsoft library called Windows Imaging Component (WIC) which some Laserfiche software uses. The most recent hit I found on the error indicated it could occur when an image exceeded certain DPI and dimension parameters:

https://docs.microsoft.com/en-us/answers/questions/69222/cannot-decode-the-image-with-very-large-resolution.html

There are other, ancient reports of various weird bugs in WIC throwing the same error for different reasons:

https://stackoverflow.com/questions/8971751/the-image-format-is-unrecognized-depending-on-monitor

https://faithlife.codes/blog/2008/08/image_format_error_when_loading_from_a_stream/

If you can consistently reproduce the issue with that file (and especially if you can with other files too), please open a support case, attach the files, and reference this post. Since the error is happening in a Microsoft library, if they haven't fixed the underlying bug there's probably not much we can do, but if they have, we might be able to patch.

Cheers,
Sam

1 0
replied on November 30, 2021

Hi Samuel,

 

Thank you for your response. From looking into this a bit more, I see that the problematic jpg file has a "Bit depth" of 32 in Properties --> Details in Windows, and if I look at the header in a text editor, it clearly says "heic" even though it has a .jpg file extension. If I open it in Paint and hit "save as" it immediately assumes to save as .heic

I know that the size/dpi of the image is unrelated because no matter how small I made it, the same issue happened.

If I look at a jpg that did not have an issue saving, the "Bit depth" is 24, not 32. Also, if I change the problem .jpg file's extension in Windows to .heic, the Save to Repository works perfectly fine.

 

0 0
SELECTED ANSWER
replied on November 30, 2021

If I'm parsing what you said there correctly, it sounds like the user may have renamed a .heic file to have a .jpg extension without actually converting it to the jpeg format. The Windows Imaging Component library then correctly threw an image format error upon being handed a ".jpg" file with .heic headers and encoding.

1 0
You are not allowed to follow up in this post.

Sign in to reply to this post.