简体   繁体   English

如何从 H.264 帧和音频帧的集合创建 mp4 文件?

[英]How do I create an mp4 file from a collection of H.264 frames and audio frames?

I have a program that captures and stores H.264 encoded video as well as audio into a proprietary format file.我有一个程序可以将 H.264 编码的视频和音频捕获并存储到专有格式文件中。 I need to be able to export that video and audio to an mp4 file.我需要能够将该视频和音频导出为 mp4 文件。 I prefer C# but will use C++ if necessary.我更喜欢 C#,但会在必要时使用 C++。 Any suggestions?有什么建议?

To produce MPEG-4 Part 14 .MP4 file you need a multiplexer.要生成 MPEG-4 Part 14 .MP4文件,您需要一个多路复用器。 There is a choice of multiplexers out there:有多种多路复用器可供选择:

API and complexity might vary because some of multiplexers are expected to be a part of pipeline, they are not completely standalone classes. API 和复杂性可能会有所不同,因为一些多路复用器预计会成为管道的一部分,它们不是完全独立的类。 You might want to check respective samples (and license agreements, perhaps, too) to see what is best for you.您可能需要检查相应的示例(也许还有许可协议)以了解什么最适合您。

Take a look at libmp4v2.看看 libmp4v2。 Fairly straightforward to use..使用起来相当简单..

http://code.google.com/p/mp4v2/ http://code.google.com/p/mp4v2/

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 如何将音频帧从 input.mp4 传递到 libavcodec 中的 output.mp4? - How can I pass audio frames from an input .mp4 to an output .mp4 in libavcodec? 如何使用ffmpeg改变mp4文件的h264属性、yuv、fps、tbr、tbn、tbc? - How to use ffmpeg to change the h264 properties, yuv, fps, tbr, tbn, and tbc of an mp4 file? 如何从mp4文件读取音频和视频数据包 - How to read audio and video packets from mp4 file iOS 浏览器是否支持带有 h264 视频和 4 个(或更多)AAC 音频通道的 mp4? - Is there iOS browser support for mp4 with h264 video and 4 (or more) AAC audio channels? 如何获取音频(.wav或.mp3)文件中每秒或毫秒的帧数(或样本数)? - How to get number of Frames(or Samples) per sec or ms in a audio (.wav or .mp3) file? 如何将.MP4视频与.WAV音频结合使用命令行参数中的ffmpeg创建新的.MP4视频? - How to combine a .MP4 video with a .WAV audio to create a new .MP4 video using ffmpeg from command line arguments? 如何实时或从iOS中保存的音频文件中获取麦克风的原始音频帧? - How can I obtain the raw audio frames from the microphone in real-time or from a saved audio file in iOS? 如何将带时间戳的动画帧同步到音频文件? - How to sync timestamped animation frames to audio file? 从 mp4 中提取音轨并将其保存为可播放的音频文件 - Extract audio track from mp4 and save it to a playable audio file .mp4的通道音频? - Channel Audio from .mp4?
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM