从MP4文件中提取帧 [英] Extract frames from a MP4 file
本文介绍了从MP4文件中提取帧的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
I would like to extract frames from an MP4 file and again render a MP4 file after editing the frames.
推荐答案
我所知道的最好的代码是FFmpeg或libavcodec: http://en.wikipedia.org/wiki/Ffmpeg [ ^ ],
http ://ffmpeg.org/ [ ^ ],
http://en.wikipedia.org/wiki/Libavcodec [ ^ ],
http://libav.org/ [<一个href =http://libav.org/target =_ blanktitle =New Window> ^ ]。
在这两种情况下,您可以获得免费的开源实用程序,几乎可以制作所有内容,包括从帧图片中提取视频帧和组装视频。
现在,如何以编程方式使用它在.NET应用程序中?首先,您可以使用System.Diagnostics.Process.Start
运行它来使用可用的实用程序:
http://msdn.microsoft.com/en-us/library/system.diagnostics.process.start.aspx [ ^ ]。
如果这还不够好,你可以自己将库包装在.NET程序集中,或找到合适的包装器。请参阅:
http://www.ffmpeg-csharp.com/ [ ^ ],
http://sourceforge.net/projects/sharpffmpeg/ [ ^ ],
http://vbffmpegwrapper.codeplex.com/ [ ^ ]。
毕竟,尝试找一些: http://bit.ly/VpboUJ [ ^ ]。
如果你想工作在你自己的包装但不知道如何,问一个问题,我会给你基本的想法(使用P / Invoke或C ++ / CLI混合模式项目)。
祝你好运,
-SA
The best code I know is FFmpeg or libavcodec: http://en.wikipedia.org/wiki/Ffmpeg[^],
http://ffmpeg.org/[^],
http://en.wikipedia.org/wiki/Libavcodec[^],
http://libav.org/[^].
In both cases, you can get free open-source utilities which can make nearly everything, including extracting video frames and assembling your video from frame pictures.
Now, how to use it programmatically in a .NET application? First, you can use the available utility by running it usingSystem.Diagnostics.Process.Start
:
http://msdn.microsoft.com/en-us/library/system.diagnostics.process.start.aspx[^].
If this is not good enough, you can wrap the library in a .NET assembly by yourself or find appropriate wrapper. Please see:
http://www.ffmpeg-csharp.com/[^],
http://sourceforge.net/projects/sharpffmpeg/[^],
http://vbffmpegwrapper.codeplex.com/[^].
After all, try to find some more: http://bit.ly/VpboUJ[^].
If you wish to work at such wrapper by yourself but don't know how, ask a question, I'll give you the basic ideas (using P/Invoke or C++/CLI "mixed-mode" project).
Good luck,
—SA
谢谢SA,
我正在使用vb处理加密视频mp4的项目。 net
i只想从视频流中提取i帧,你能告诉我如何确定i-frame以及如何提取它
thank you SA ,
I'm working on project to encryption video mp4 by using vb.net
i want to extract only i frame from video stream , can you told me how to determine i-frame and how to extract it
这篇关于从MP4文件中提取帧的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文