[Libav-user] avformat_open_input subfile protocol for reading video from ZIP
dj.alexshaft at gmail.com
Thu Nov 19 16:48:23 CET 2015
Hi all. I use ffmpeg libs with Unity3D game dev platform as native plugins
for ios and android, for rendering video into textures. So simply I make
animations by such strange way =)
Everything works like a charm. But, for Android platform Unity packs my
video sources into .jar archive which is simply zip archive.
I found that ffmpeg has "subfile" protocol.
I tried simple trick:
ZipFile zip = new ZipFile(Application.streamingAssetsPath + "/test.zip");
get needed ZipEntry (it's just .avi file)
and create path like :
path = "subfile,,start," + entry.Offset + ",end," + (entry.Offset +
entry.CompressedSize) + ",,:" + Application.streamingAssetsPath +
So I get this path for example:
I test it on Windows so I get path like: C:/
But when I open input by avformat_open_input(&pFormatCtx, path, NULL, 0) I
just get result 1
So, maybe someone knows what am I doing wrong and what actually that result
Hope on your response!
Best regards, Alex
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Libav-user