如何以编程方式创建视频?

发布于 2024-07-05 02:46:19 字数 88 浏览 9 评论 0原文

是否有免费的库可以根据图像序列创建 MPEG(或任何其他简单的视频格式)?

它也必须在 Linux 上运行,并且最好具有 Python 绑定。

Is there a freely available library to create a MPEG (or any other simple video format) out of an image sequence ?

It must run on Linux too, and ideally have Python bindings.

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

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

发布评论

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

评论(7

月光色 2024-07-12 02:46:20

在 c++ OpenCV(来自英特尔的开源计算机视觉库)中,您可以创建一个 AVI 文件,然后将帧推入其中......

但这就像用大炮射击苍蝇一样。

in c++ OpenCV (open source Computer Vision library from Intel) let you create an AVI file and just push frames inside...

but it's like shooting with a cannon to a fly.

一直在等你来 2024-07-12 02:46:20

mplayer 不是一个库,但它能够将 JPEG 序列编码为任何类型的格式。 它运行在Linux、Windows、BSD等平台上,如果你想和python一起使用,你可以编写一个python脚本。

Not a library, but mplayer has the ability to encode JPEG sequences to any kind of format. It runs on Linux, Windows, BSD and other platforms and you can write a python script if you want to use it with python.

挥剑断情 2024-07-12 02:46:20

ffmpeg 有一个 API,还有 python 绑定,似乎是可行的方法!

谢谢

ffmpeg has an API and also python bindings, seems to be the way to go !

Thanks

作妖 2024-07-12 02:46:20

ffmpeg最小可运行C示例

我在以下位置提供了完整的可运行示例:如何使用ffmpeg的sws_scale()调整图片大小?

ffmpeg minimal runnable C example

I have provided a full runnable example at: How to resize a picture using ffmpeg's sws_scale()?

↙厌世 2024-07-12 02:46:19

ffmpeg 是一个很棒的(开源)程序,用于构建各种视频并转换一种类型将视频(在本例中为图像序列)转换为其他类型的视频。

通常它是从命令行使用的,但这实际上只是其内部库的包装。 它明确可以在另一个程序中使用

还有包装 c api 的 python 绑定,尽管这个特定项目似乎没有获得最好的支持(可能还有其他项目在做同样的事情)。

还有此链接,有人使用 ffmpeg 做了与您类似的事情寻找。

ffmpeg is a great (open source) program for building all kinds of video, and converting one type of video (a sequence of images in this case) into other types of video.

Usually it is utilized from the command line, but that is really just a wrapper around its internal libraries. It is expressly available to be used from within another program.

There are also python bindings that wrap the c api, though this particular project doesn't seem to be getting the best support (there are probably other projects out there doing the same thing).

There's also this link where someone has used ffmpeg to do something similar to what you're looking for.

梦途 2024-07-12 02:46:19

GStreamer 是一个流行的选择。 它是一个完整的多媒体框架,很像 DirectShow 或 QuickTime,具有拥有合法许可的编解码器的优点,并且具有出色的 Python 绑定。

GStreamer is a popular choice. It's a full multimedia framework much like DirectShow or QuickTime, has the advantage of having legally licensed codecs available, and has excellent Python bindings.

撩起发的微风 2024-07-12 02:46:19

我知道有 mencoder (mplayer 项目的一部分)和 ffmpeg,两者都可以做到这一点。

I know there's mencoder (part of the mplayer project), and ffmpeg, which both can do this.

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