Graphic编码

1. BMP图片向JPG格式的转化

可以参考文章

http://www.computing.net/answers/programming/c-code-convert-bmp-to-jpeg-file/4383.html

中的建议,摘录重要部分如下:

 

As tech-fred said, regular JPEGs are lossy. Photographic images generally cannot be squished as much as JPEGs, without some detail loss (somewhat like MP3s in audio).

If you need a non-lossy compact format other than RLE'd bitmaps, compressed TIFFs are popular. They are commonly used with graphicssoftware for high-quality storage (though not used on web pages or as GUI resources). The PNG format is also good, and getting quite popular. Source is freely available for both.

Finding free libraries using searches engines is difficult; you have to know where to search. Keep bookmarks for these sites: sourceforge.net, codeguru.com, freshmeat.net, simtel.net; there are many others. You will have good luck going directly to Open Source sites, which aren't commercial, of course, so search sites do not get paid to give them high visibility. If you are mostly Windows-oriented, don't be put off by all the Unix/Linux talk; C and C++ source is fairly portable, and much source is for Windows too.

In general when looking for free source, you can also search for projects that uses the kind of software you want to use, download it, and read the docs which tell you where to get other source. You can also get ideas about how to implement things; this is what Open Source is all about (free availability is encouraged). I found lots of stuff via a freshmeat search, and some indirectly from it:


An "official" source for JPEG processing, from IJG themselves:

ftp://ftp.uu.net/graphics/jpeg/jpegsrc.v6b.tar.gz
or...
http://www.ijg.org/files/jpegsrc.v6b.tar.gz
or in Zip format...
ftp://ftp.simtel.net/pub/simtelnet/msdos/graphics/jpegsr6.zip

Tons of official info:

http://www.faqs.org/faqs/jpeg-faq/

Free TIFF library:

ftp://ftp.sgi.com/graphics/tiff/tiff-v3.4-tar.gz

For a more complete image-processing library, there is also ImageMagick, which works with many formats and platforms:

http://imagemagick.sourceforge.net/

Several graphics libraries (including PNG, JPEG, TIFF) are available at:

ftp://ftp.nluug.nl/pub/graphics/ImageMagick/delegates/

 

另外,同时找到了一个好玩的开源工程

http://wingraphviz.sourceforge.net/wingraphviz/

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值