C++:在 Windows 上使用 C++ 读写 BMP 文件的最简单方法是什么?

2021-12-18 00:00:00 windows winapi image-manipulation c++ bmp

我想加载一个 BMP 文件,在内存中对其进行一些操作,然后在 Windows(Win32 原生)上使用 C++ 输出一个新的 BMP 文件.我知道 ImageMagick 并且它是 C++ 绑定 Magick++,但我认为这对这个项目来说太过分了,因为我目前对其他文件格式或平台不感兴趣.

I would like to load a BMP file, do some operations on it in memory, and output a new BMP file using C++ on Windows (Win32 native). I am aware of ImageMagick and it's C++ binding Magick++, but I think it's an overkill for this project since I am currently not interested in other file formats or platforms.

就读取和写入 BMP 文件的代码设置而言,最简单的方法是什么?答案可能是就用 Magick++,它是最简单的."

What would be the simplest way in terms of code setup to read and write BMP files? The answer may be "just use Magick++, it's the simplest."

相关问题:最好的图像处理库是什么?

推荐答案

当只为 Windows 开发时,我通常只使用 ATL CImage 类

When developing just for Windows I usually just use the ATL CImage class

相关文章