Welcome to Doom9's Forum, THE in-place to be for everyone interested in DVD conversion. Before you start posting please read the forum rules. By posting to this forum you agree to abide by the rules. |
18th July 2011, 16:27 | #1 | Link |
Registered User
Join Date: Oct 2004
Posts: 131
|
ImageReader error on blank PNGs
When I use ImageMagick to save a totally black PNG, Avisynth ImageSource() returns an DevIL library error:
error: 'Illegal file' in DevIL library.... I think the output of ImageMagick is 100% standard compilant, so the error must be with ImageMagick. I tried 2.58 official, 2.60 latest, 2.60 MT latest and its all the same. Can you suggest me some newer build, or a solution to this problem? I uploaded the file which triggers this error (only 456 bytes). Last edited by pancserzso; 18th July 2011 at 16:33. |
18th July 2011, 17:38 | #2 | Link |
Moderator
Join Date: Nov 2001
Location: Netherlands
Posts: 6,364
|
Perhaps a bug in DevIL 1.6.6? AviSynth v2.60a3 and 1.7.8 DevIL.dll loads it fine.
|
18th July 2011, 18:16 | #3 | Link | |
Registered User
Join Date: Oct 2004
Posts: 131
|
Can you help me, I cannot make DevIL 1.7.8 work.
I have the Avisynth 2.60a3 (AviSynth_110525.exe) and downloaded the new 1.7.8 DevIL.dll. I have overwritten the old DevIL with the new one in System32 folder. But I get exception errors, when trying to open the Avisynth script: It is the line in the avs: Quote:
Last edited by pancserzso; 18th July 2011 at 18:49. |
|
18th July 2011, 21:39 | #5 | Link | |
Registered User
Join Date: Oct 2004
Posts: 131
|
Quote:
Can you upload a version which works for sure? |
|
18th July 2011, 22:38 | #6 | Link |
Compiling Encoder
Join Date: Jan 2007
Posts: 1,348
|
those dlls are part of the Visual Studio 2005 redistributable package.
as avisynth is 32bit, make sure you have the x86 version installed, these dlls should go into syswow64 (or more likely a subdirectory within it) I am not aware if you should get the sp0 or sp1 package however though... Edit: (generally you should get the sp1, but some programs seem to explicitly state getting the sp0). Last edited by kemuri-_9; 18th July 2011 at 22:46. |
18th July 2011, 22:57 | #7 | Link |
Avisynth Developer
Join Date: Jan 2003
Location: Melbourne, Australia
Posts: 3,167
|
Do NOT just bang copies of msvcp80.dll, msvcr80.dll, etc, into your windows system directories.
You now need to correctly install them (thanks Micro$oft, ........ NOT!) from a re-distributable package. Visual C++ 2005 SP1 Redistributable Package (x86) See this page "Latest Supported Visual C++ Downloads" for details. Also the ScriptEnvironment::ThrowError() problem is a recently identified bug. |
19th July 2011, 04:45 | #8 | Link |
Registered User
Join Date: Oct 2004
Posts: 131
|
I have installed all the latest MSVC 2005 packages (both 32-bit and 64-bit), but no success.
I tried using the latest MT build, and it displays a different message: Can someone help me? BTW, now this error is not only for this special image, it is for all avisynth imagesources now. |
19th July 2011, 05:16 | #10 | Link |
Avisynth Developer
Join Date: Jan 2003
Location: Melbourne, Australia
Posts: 3,167
|
Avisynth 2.5.8 pre-dates the bug with reporting the DevIL library errors, so you will at least be able to see the correct error message text for your problem with that version.
Also your error message seems to indicate that the file name causing problems is "Invalid extension" which may mean that something is stomping over the memory that holds the filename. |
19th July 2011, 05:45 | #11 | Link |
Registered User
Join Date: Oct 2004
Posts: 131
|
But I need to use DevIL 1.7.8 to read the problematic images.
Here is what happens with 2.58 official + DevIL 1.7.8: Also, I copied the avs file to e:\a.avs and the png image to e:\b.png, but the error is exactly the same. |
19th July 2011, 11:52 | #12 | Link |
Avisynth Developer
Join Date: Jan 2003
Location: Melbourne, Australia
Posts: 3,167
|
1. Can you please put a copy x_alpha0001.png somewhere for us to download.
2. The error IL_INVALID_EXTENSION means the parser selected based on the file extension does not recognise the file contents. The .PNG parser expects the file to start 0x89, 0x50, 0x4E, 0x47, 0x0D, 0x0A, 0x1A, etc |
19th July 2011, 14:59 | #13 | Link |
Registered User
Join Date: Oct 2004
Posts: 131
|
OK, I have uploaded a file with both a good png and a bad png. By bad I mean having size 465 bytes and being 100% transparent, what the old DevIL library doesn't accept. I am trying to find a solution for making bad.png work. It is a 100% correct PNG file, generated by the latest ImageMagick.
http://ifile.it/cqk6xo8 |
19th July 2011, 23:01 | #14 | Link |
Avisynth Developer
Join Date: Jan 2003
Location: Melbourne, Australia
Posts: 3,167
|
Okay both work fine with DevIL 1.7.8 (764,416 bytes)
Good.avs works fine, bad.avs gives "Illegal file", IL_ILLEGAL_FILE_VALUE. with DevIL 1.6.6 (719,872 bytes). Same results with Avisynth.dll 2.5.8, 2.6.3 (apart from bug) and 2.6.4 (my fixed build). msvcm80.dll, msvcp80.dll and msvcr80.dll all are version 8.00.50727.762 Are you sure x_alpha0001.png is valid? :? From DevIL docs :- IL_ILLEGAL_FILE_VALUE => An illegal value was found in a file trying to be loaded. IL_INVALID_EXTENSION => The extension of the specified filename was not correct for the type of image-loading function. |
19th July 2011, 23:03 | #15 | Link | |
Registered User
Join Date: Oct 2004
Posts: 131
|
Quote:
Where can I download your 2.6.4 build? Also, can you upload your dll's to somewhere? |
|
19th July 2011, 23:34 | #16 | Link |
Avisynth Developer
Join Date: Jan 2003
Location: Melbourne, Australia
Posts: 3,167
|
As I said in my post #7 you cannot just bang copies of the msvc runtimes into your system directory any more.
You must correctly install them from a proper Micro$oft distribution. I used the vcredist_x86.exe (2,723,264 bytes) as downloaded from the link in my post #7. It was digitally signed Monday, 19 February 2007 07:06:01 |
19th July 2011, 23:39 | #17 | Link | |
Registered User
Join Date: Oct 2004
Posts: 131
|
Quote:
Also, my versions are: 8.00.50727.4027 Last edited by pancserzso; 19th July 2011 at 23:41. |
|
|
|