c - 使用 ffmpeg 或 OpenCV 处理 .Raw 图像

标签 c opencv image-processing ffmpeg v4l2

看完Wikipedia page原始图像格式,它是任何图像的数字底片。

To be viewed or printed, the output from a camera's image sensor has to be processed, that is, converted to a photographic rendering of the scene, and then stored in a standard raster graphics format such as JPEG. This processing, whether done in-camera or later in a raw-file converter, involves a number of operations, typically including

我使用 v4l2 example 从我的罗技 c920 中抓取了一些 .raw 文件但是当我显示图像时,它看起来像这样: raw frame file原始图像,在其他帧中我可以看到我的影子

有谁知道如何处理此类文件以查看完整的帧?

Here is a link to the original .raw file

最佳答案

ffmpeg -f rawvideo -s 640x480 -pix_fmt yuyv422 -i frame-1.raw frame-1.jpg

选项是根据链接的 v4l2 代码设置的,生成的图像是您期望得到的图像。

关于c - 使用 ffmpeg 或 OpenCV 处理 .Raw 图像,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/15031183/

相关文章:

image - 为什么计算 RGB 的平均值不会产生像素的亮度?

algorithm - 用直线分解曲线的最简单算法是什么?

c - 为我的操作系统移植 NewLib : some questions

opencv - 从视频中的单应性中提取人脸旋转

image-processing - ImageMagick 将高大图像裁剪为具有相同宽度动态高度的 A4 PDF 页面

c++ - 对齐C++指针位置的目的是什么

c++ - OpenCV:CvBox2D 角度

c - float math.cos 不准确

c - 我如何绕过返回地址覆盖而不是重定向控制流?

c++ - 如何检测DTLS中收到的消息?