Click here to Skip to main content
15,887,350 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:

Hello All,

I have a tiff image created in PixelFormat32bppARGB. I want it convert it to  PixelFormat1bppIndexed (black and white) tiff image to be used by my application. Can anyone help me with steps or sample code for the same.

 

Code to create the tiffimage in PixelFormat32bppARGB:-

bmp = new Bitmap(iWidth, iHeight); // here PixelFormat32bppARGB  is taken in by default

Also I am using the GDI+ library.

Thanks,

Vikas

Posted
Updated 23-Nov-09 21:24pm
v2

1 solution

Hi Vikas,

 

We have an application that we use for scanning our client applications forms,ID's etc which we store on a server hdd.These were always supposed to be scanned into 8bpp to ensure that we had a decent picture quality and at the same time not use too much disk space as we scan over 80000 images per day.

 

We then had an issue where some ppl would go change settings on the scanner and not set them back to the default settings and as result we had a lot of oversized 32bit images.

 

I then created an application/class that would get all these files,convert the bit size and also the image size of each file.Also some of these files were multipage TIFF documents.

 

Anycase just to get to the point...I do have a class that can do this for your but I think it would be much easier to zip the entire project with source code and email it to you instead of just giving you pieces of code in a post ?

 

The class was written in C# / .Net 2.0.

 

Kind Regards.

Freddie.

 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900