问题描述
因此,我正在做一些与高动态范围成像(HDRI)相关的研究.我已经在OpenCV中完成了与对齐和重影去除有关的工作(尚未进行任何实际的HDR操作或创建),现在,我希望能够开始使用HDR图像.
So I'm doing some research related to High Dynamic Range Imaging (HDRI). I've already done some work in OpenCV related to aligning and ghost removal (no actual HDR manipulation or creation yet), and now I would like to be able to start working with HDR images.
任何人都可以推荐一个好的开源HDR库,理想情况下可以让我执行以下操作:
Can anyone recommend a good open source HDR library that would ideally allow me to do the following:
-
读/写HDR格式(我尚未提交特定格式的文件,因此在这里我可以提出建议)
Read/ Write an HDR format (I'm not commited to a particular format yet, so I'm open to suggestions here)
组合包围曝光的图像以获取HDR图像,但以一种允许我访问已创建的相机功能的方式,以便以后可以使用此功能来执行诸如使用不同数量的EB图像进行贡献的操作到HDR图像的不同部分.
Combine exposure-bracketed images to get HDR images, but in a way that allows me to access the camera function that gets created so that I can later use this to do things like using different numbers of EB images to contribute to different parts of the HDR image.
使用OpenCV相对容易地实现接口(有关详细信息,请参见下文).
Interface relatively easily with OpenCV (see below for details).
如果它是一个可以轻松与OpenCV交互的库,那将是理想的选择.我不认为OpenCV中目前没有任何HDR功能,但是谁能告诉我是否有一种方法可以将HDR图像转换为OpenCV算法(如修复)可以使用的格式?例如,我知道OpenCV可以处理64位浮点图像.我可以将HDR图像转换为这些格式之一并运行吗?
If it's a library that allows easy interfacing with OpenCV, that would be ideal. I don't think there is currently any HDR functionality in OpenCV, but can anyone tell me if there's a way to convert an HDR image into a format that OpenCV algorithns such as inpainting will work with? For example, I know OpenCV can work with 64-bit floating point images; can I just convert an HDR image into one of these formats and run with it?
谢谢.
推荐答案
嘿,我很久以前问过这个问题,只是通过google偶然发现了我的问题,所以我想提供一个快速更新.
Hey, I asked this a long time ago, and just stumbled on my question again through google, so I thought I'd provide a quick update.
我用Magick ++尝试了Image Magick.经过大量工作后,我设法使其与OpenEXR格式一起使用,但始终无法使Radiance(.hdr)工作,这很可惜,因为我在MATLAB中做了很多工作,而后者仅读取/写入Radiance for HDR .
I tried Image Magick with Magick++. After a fair bit of work, I managed to get it working with OpenEXR format, but was never able to get Radiance (.hdr) working which is a shame because I do a lot of work in MATLAB which only reads/writes Radiance for HDR.
接下来,我尝试了FreeImage.我可以用它读取/写入hdr以及PFM格式,但是我发现Fibitmap格式确实是封闭的,即很难将数据从Fibitmap中获取到OpenCV Mat中,并且几乎不可能将其返回到Fibitmap中.
Next, I tried FreeImage. I was able to read/write hdr as well as PFM formats with this, but I found the Fibitmap format really closed, i.e. difficult to get data from a fibitmap into an OpenCV Mat, and near impossible to get it back into a Fibitmap.
最后,我只是开始使用可移植浮动地图(PFM),并使用自己的代码读取和编写它们,因为格式是如此简单.同样,这是在研究环境中的,因此,尽管PFM对于长期的存储或商业用途而言是一种非常笨拙的格式,但对于研究目的而言却非常不错.
In the end, I just started using Portable Float Maps (PFMs), and reading and writing them with my own code because the format is so simple. Again, this is in a research setting, so while PFM is a pretty ungainly format for long-term storange or commercial use, it's pretty nice for research purposes.
这篇关于开源HDR库建议的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!