File Writer 是否可以加快捕获的流视频的 FPS?

发布于 2024-11-17 12:46:39 字数 837 浏览 3 评论 0原文

我在 graphedit 中连接了一个网络摄像头,在 C# 代码中,我保存的所有视频的保存速度比它们的流式传输速度快 2-3 倍。网络摄像头设置为运行 640x480 @ 30fps。我录制了一个 15 秒的视频,当我重播它时,视频只有 5 秒长,它包含整个 15 秒的视频,但只是在更高的 FPS 下。

我稍微改变了我的过滤器。我使用过 ffdshow 编码器、xvid 编码器、mpeg 编码器、divx 编码器以及 avi mux、xvid mux、mpeg mux,所有这些都连接到 File Writer,并且它们都以更高的 FPS 保存视频流。

那么 File Writer 是否做了一些不应该做的事情呢?

有没有办法修复或解决它?

或者也许是更好的选择?

编辑:

这些是我一直在尝试使用的图表,但所有这些图表的输出都是加速的 FPS

Source -> Smart Tee -> 3ivx MPEG-4 Video Encoder -> 3ivx MPEG-4 Media Muxer -> File Writer

Source -> Smart Tee -> Divx Video Encoder -> AVI Mux -> file writer

Source -> Smart Tee -> ffdshow video encoder -> 3ivx MPEG-4 Media Muxer -> file writer

Source -> Smart Tee -> AVI Mux -> File Writer

,我录制了一个 15 秒的视频,当它们重播时,它们的长度为 5 秒

I have a webcam hooked up in graphedit, and in C# code, all the videos i save are being saved 2-3 times faster then they are being streamed at. The webcam is setup to run 640x480 @ 30fps. I record a video for 15 seconds and when i replay it, the video is only 5 seconds long, it contains the entire 15second video but just at a higher FPS.

I have changed my filters around a bit. I have used ffdshow encoders, xvid encoders, mpeg encoders, divx encoders along with avi mux, xvid mux, mpeg mux, all connected to File Writer and they are all saving the video stream at higher FPS.

So is File Writer doing something it shouldnt?

Is there a way to fix it or work around it?

or maybe a better option?

EDIT:

These are the graphs I've been trying to use but all the outputs are at a sped up FPS

Source -> Smart Tee -> 3ivx MPEG-4 Video Encoder -> 3ivx MPEG-4 Media Muxer -> File Writer

Source -> Smart Tee -> Divx Video Encoder -> AVI Mux -> file writer

Source -> Smart Tee -> ffdshow video encoder -> 3ivx MPEG-4 Media Muxer -> file writer

Source -> Smart Tee -> AVI Mux -> File Writer

with all these graphs, I recorded a 15 second video and when they were replayed, they were 5 seconds long

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

魔法少女 2024-11-24 12:46:39

您需要检查来自网络摄像头的样本的时间戳以及其流的媒体类型中提到的帧持续时间。前者可以在 GraphEditPlus 中轻松完成,方法是在网络摄像头后面插入样本抓取器并观看抓取的样本信息(右键单击抓取器)。后者甚至更简单:只需单击连接即可。

You need to check timestamps of samples coming out of your web cam and also frame duration mentioned in the media type of its stream. The former can be done easily in GraphEditPlus by inserting a sample grabber after the web cam and watching grabbed samples info (right click the grabber). The latter is even easier: just click the connection.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文