hi there
Can anyone plz help me with compressing a JPEG image with c programming on windowsxp.
thanx in advance
hi there
Can anyone plz help me with compressing a JPEG image with c programming on windowsxp.
thanx in advance
I thought a JPEG image was already compressed... am I missing something?
QuantumPete
"No-one else has reported this problem, you're either crazy or a liar" - Dogbert Technical Support
"Have you tried turning it off and on again?" - The IT Crowd
2 choices:
* Learn how to read jpegs and compress them yourself
* Use a 3rd party library, see http://www.ijg.org/
Or something like libgd
A jpeg doesn't necessarily have to be compressed, jpeg can be compressed on several levels [1-100] "qualities", 1 being the worst, 100 being the best since it's a lossy format.Originally Posted by QuantumPete
Last edited by zacs7; 08-31-2007 at 04:47 AM.
JPEG i am talking about is not a compressed image ..
Last edited by dragunov; 08-31-2007 at 04:47 AM.
thanx for the reply all of u..
oops i missed something
i am talking about compressing a bmp image
sorry..
Then convert it to JPEG or PNG! Or run it through some compression library such as zip, gzip, LWZ or such.
Windows is capable to natively supporting at least JPEG, I think.
--
Mats
Only with GDI+Originally Posted by matsp
Still libgd is the easiest way I'd say, or GDI+
Yes, I realized that only GDI+ supports it. Not sure where GDI+ was introduced, WinXP or Vista?
Edit: it's a separate SDK that can be used for almost any recent Win32 version, see: http://msdn2.microsoft.com/en-us/library/ms533798.aspx
Image::Save in GDI+:
http://msdn2.microsoft.com/en-us/library/ms535407.aspx
--
Mats