2015-02-23 91 views
0

我在我的应用程序中使用vlc播放器,我想使用vlc获取正在播放的文件信息,我已经使用vlc SDK。我已经搜索了很多,但在iOS中找不到适合vlc player集成的任何适当文档。我想要得到的信息如下:如何在使用VLC播放器时获取媒体信息

General 
ID          : 2 (0x2) 
Format         : MPEG-TS 
File size        : 915 MiB 
Duration         : 8mn 31s 
Start time        : UTC 2009-06-09 14:15:57 
End time         : UTC 2009-06-09 14:24:12 
Overall bit rate       : 15.0 Mbps 

Video #1 
ID          : 256 (0x100) 
Menu ID         : 1 (0x1) 
Format         : AVC 
Format/Info        : Advanced Video Codec 
Format profile       : [email protected] 
Format settings, CABAC     : Yes 
Format settings, ReFrames    : 4 frames 
Codec ID         : 27 
Duration         : 8mn 31s 
Width         : 720 pixels 
Height         : 576 pixels 
Display aspect ratio      : 4:3 
Frame rate        : 25.000 fps 
Standard         : PAL 
Color space        : YUV 
Chroma subsampling      : 4:2:0 
Bit depth        : 8 bits 
Scan type        : MBAFF 
Scan order        : Top Field First 
Color primaries       : BT.470-6 System B, BT.470-6 System G, BT.601-6 625, BT.1358 625, BT.1700 625 PAL, BT.1700 625 SECAM 
Transfer characteristics     : BT.470-6 System B, BT.470-6 System G 
Matrix coefficients      : BT.470-6 System B, BT.470-6 System G, BT.601-6 625, BT.1358 625, BT.1700 625 PAL, BT.1700 625 SECAM, IEC 61966-2-4 601 

有没有什么办法得到这种类型的信息?

任何帮助,将不胜感激。 在此先感谢。

回答

2

完全披露:我是VLC主要开发人员之一,也是Mac和iOS SDK的当前维护人员。

iOS上的VLC SDK称为MobileVLCKit或简称为VLCKit。我们在wiki上提供基本文档。另外,I blogged about metadata in VLCKit recently,它应该提供您需要的所有答案。

注意:您的上述输出取自mediainfo,这是更详细的方式。在VLCKit中,您只能获得尽可能多的信息,您可以从我们的桌面变体中获得的信息面板中获得信息。

+0

感谢您的回复,但我想获得正在播放到vlc的视频的候选位(秒/秒)。我可以使用VLCKit播放/暂停视频,但无法找到媒体信息。 – 2015-02-23 13:54:45

+1

对不起,您是否阅读过我的博客文章,其中包含确切的API调用? :)还是你想统计数据传输? – feepk 2015-02-23 20:50:43

+0

我很抱歉,我想我错过了一些东西,你提供了获取元数据的API。但我不知道如何使用它。我正在使用dropIn-Player示例。 vlcObject。 tracksInformation不允许我获取元数据。请让我知道我在这里做错了什么? – 2015-02-24 07:06:52

相关问题