Welcome Guest! To enable all features, please Login or Register.

Notification

Icon
Error

Options
View
Last Go to last post Unread Go to first unread post
#1 Posted : Tuesday, July 28, 2009 7:59:38 PM(UTC)

sjha  
sjha

Groups: Registered
Posts: 6


Hi,

I am creating an image dump after scanning a page
when i try to open this dump image file with leadtool evaluation version 16.5, L_FileInfo() detects this image compression as JPEG and finally returns error no = -11.
I have attached the image dump for your reference.
Can you please help me on this.

Scanner Details:
----------------
InoTec M06 / SCAMAX 4x2xx (connected via RJ45)
- M0612CD / 412CD
- mainboard firmware 60-60-60
- controller firmware 3.03.46
- display firmware 3.04.03
- PostEndorser = Y
- PreEndorser = n/a
- TWAIN: 1.076
- ISIS: 1.0.10808.18001

Bits per pixel = 1
DPI = 200
Compression = CCITT G4

Thanks & Regards,
Sitesh
File Attachment(s):
test.tif (12kb) downloaded 29 time(s).
 

Try the latest version of LEADTOOLS for free for 60 days by downloading the evaluation: https://www.leadtools.com/downloads

Wanna join the discussion? Login to your LEADTOOLS Support accountor Register a new forum account.

#2 Posted : Wednesday, July 29, 2009 3:09:57 AM(UTC)

Adnan Ismail  
Guest

Groups: Guests
Posts: 3,022

Was thanked: 2 time(s) in 2 post(s)

Sitesh,
The attached image does not appear to be a valid image. It does not have width and height information in it. Can you tell me how exactly you dumped the scanned image and created the attached file?

Is there a way to see this problem in a very small test application (not your full project)? If yes, please send me this test project in a ZIP or RAR file and I will check it for you.
 
#3 Posted : Wednesday, July 29, 2009 5:49:25 AM(UTC)

sjha  
sjha

Groups: Registered
Posts: 6


Hi Adnan,

I saved the raw bytes which has come from scanner into a binary file and then tried to open this file using the Main Demo LeadTool application.

This error happens sporadically.

In other cases it returns me Error = -9.
Please find the attached file for
which I get Error (-9).

I have also attached the image dump when I scanned a color image with JPEG compression and I am able to open this file successfully with LeadTool.

Regards,
Sitesh
File Attachment(s):
ImageDump.rar (369kb) downloaded 30 time(s).
 
#4 Posted : Thursday, July 30, 2009 6:40:10 AM(UTC)

Adnan Ismail  
Guest

Groups: Guests
Posts: 3,022

Was thanked: 2 time(s) in 2 post(s)

If you're dumping raw pixel data without saving a file format header, you will need to use the raw loading method of LEADTOOLS. This is explained in the help topic "working with the Raw filter".
 
#5 Posted : Monday, August 3, 2009 12:13:24 AM(UTC)

sjha  
sjha

Groups: Registered
Posts: 6


Hi Adnan,

I receive the image data from the scanner and i check for image type using LeadTool.

//pseudo code
CodecsImageInfo info = codecs.GetInformation(FileName, true);

if(info.Format == "JPEG")
{
//Do something...
}
else
{
//Do something...
}

To get image information, I used RasterCodecs class's GetInformation(string fileName, bool totalPages)
function and it returned me Image compression as JPEG and Bits per pixel = 8.
But my scanner is configured to send CCIT G4 compressed image with Bits per pixel = 1.
I attached image file (Test.tif) in my first post for which I get this problem.

to summarize the main question:
-------------------------------
In this case i know the image is a tiff.
why does leadtools return a "positiveā€œ result when checking for jpeg?
what makes it think it was a jpeg?


thanks in advance

Sitesh
 
#6 Posted : Monday, August 3, 2009 4:23:10 AM(UTC)

Adnan Ismail  
Guest

Groups: Guests
Posts: 3,022

Was thanked: 2 time(s) in 2 post(s)

The image is definitely not a TIFF file, but it could be raw CCITT Group 4. In this case, you will need to use the raw loading mechanism of LEADTOOLS. I can try that, but I will need to know the exact width and height of the image in pixels.

Please note that raw binary data can trigger a false positive because it basically contains random bytes. Some of these bytes could resemble the properties of other formats like JPEG.
 
#7 Posted : Tuesday, August 4, 2009 4:03:50 AM(UTC)

sjha  
sjha

Groups: Registered
Posts: 6


Hi Adnan,

Image width = 1653
Image height = 2315
X Resolution = 200
Y Resolution = 200
Compression = CCIT G4

Thanks,
Sitesh
 
#8 Posted : Wednesday, August 5, 2009 6:35:19 AM(UTC)

Adnan Ismail  
Guest

Groups: Guests
Posts: 3,022

Was thanked: 2 time(s) in 2 post(s)

Sitesh,
When I loaded your image into our .NET demo, I got a blank scanned page (not data on it). Is this the page you are dumping? If yes, you can load it using our demo as follows:
1- Open Main C# demo shipped with our toolkit.
2- From File menu-> Open Raw.
3- Browse to your image file, then click OK. The loading Raw dialog box will open.
4- Set the values inside the dialog according to your settings.

The demo uses the RasterCodecs.CodecsRawOptions class and the LoadInformation event to load Raw data images.
 
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.

Powered by YAF.NET | YAF.NET © 2003-2024, Yet Another Forum.NET
This page was generated in 0.119 seconds.