用c语言读取并显示bmp图像.docVIP

  • 18
  • 0
  • 约3.17万字
  • 约 38页
  • 2017-02-11 发布于北京
  • 举报
用c语言读取并显示bmp图像

如何在WIN-TC中或TC++3.0中把一张BMP格式的图片显示出来?下面的是C C++编程实例随书光盘上的代码,我在TC2.0下编译通过. 它是利用了抖动技术显示了8bit和24bit的位图(也就是256色和16M色位图),应该能满足你的需要. 不过,我想问下,你老师教过抖动显示吗? #include stdio.h #include dos.h #include stdio.h #include conio.h #define NoError 0 #define ErrorFileOpen 1 #define ErrorFileType 2 #define ErrorImageColor 3 typedef struct tagBITMAPFILEHEADER { unsigned int bfType; unsigned long bfSize; unsigned int bfReserved1; unsigned int bfReserved2; unsigned long bfoffBits; }BITMAPFILEHEADER; typedef struct tagBITMAPINFOHEADER { unsigned long biSize; unsigned long biWidth; unsigned lon

文档评论(0)

1亿VIP精品文档

相关文档