VLC 使用哪个函数打开视频文件? [英] which function does VLC use to open a video file?

查看:30
本文介绍了VLC 使用哪个函数打开视频文件?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经下载了一个视频文件并记录了数据包到达时间.我想根据我录制的时间使用 VLC 播放视频.在 VLC 源代码中我应该调用哪个函数以及如何调用它?

i`ve downloaded a video file and recorded the packet arrival time. and i want to use VLC to play the video according to the time i record. which function and how should i call to do it in the VLC source code?

我的意思是当我们按下按钮打开视频文件时,VLC通常使用哪些功能来播放视频?因为它的源代码树中有很多文件和函数.

i mean usually which functions VLC use to play video when we press the button to open a video file? because there are so many files and functions in its source tree.

非常感谢.

推荐答案

您可以链接到 libVLC 并调用其中的函数.http://wiki.videolan.org/LibVLC_SampleCode_Thumbnailer 给出了一个使用这种技术的小型 C 程序示例打开电影,在电影中寻找时间,抓取一帧的 JPG,并将其保存到磁盘.只有几行代码.

You can just link to libVLC and call functions in it. http://wiki.videolan.org/LibVLC_SampleCode_Thumbnailer gives an example of a small C program that uses this technique to open a movie, seek to a time within the movie, grab a JPG of one frame, and save it to disk. It is only a few lines of code.

我不了解 Windows,但在 Mac 上,标头和共享库位于:在 VLC 应用程序包中:VLC.app/Contents/MacOS/include/vlc/vlc.h(以及该目录中的其他 .h 文件),库位于 VLC.app/Contents/MacOS/lib/libvlc.动态库

I don't know about Windows, but on Mac, the header and shared library are at: in the VLC application package at: VLC.app/Contents/MacOS/include/vlc/vlc.h (and the other .h files in that directory) and the library is at VLC.app/Contents/MacOS/lib/libvlc.dylib

请注意,该库是 GPLv2,而不是 LGPL.我的理解是,如果您链​​接到该库,则需要以 GPL 形式发布您的程序.

Note that the library is GPLv2, not LGPL. My understand is that if you link to the library, you are required to release your program as GPL.

这篇关于VLC 使用哪个函数打开视频文件?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆