<div dir="ltr"><br><div class="gmail_extra"><br><br><div class="gmail_quote">On Fri, Apr 18, 2014 at 12:56 AM, J Decker <span dir="ltr"><<a href="mailto:d3ck0r@gmail.com" target="_blank">d3ck0r@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">I'm attempting to use custom IO. Â I have successfully used it to remap fopen, fread, fseek etc. Â I have mostly successfully done the same for this network stream...<div>
<br></div><div>Question is... It looks like if I supply no seek routine, the custom IO should set a characteristics sort of flag indicating no seek... but without the seek it fails to read the stream; is there a suggested codec/container format to use that doesn't seek to the end or near the end first?</div>
<div><br></div><div>Also, it is given that I should </div><div>avio_alloc_context</div><div>foramt_alloc_context</div><div>(do something to start opening the file)</div><div><br></div><div>use some of the file and call  av_probe_input_format... and finally avformat_open_input with a blank filename....</div>
<div><br></div><div>I notice that open_input with a filename must not do this same step... because, with this sample movie I have, with the probe, the open_input seeks to read the last 8 bytes and then fails indicating a bad format. Â If I bypass the probe, or pass it a 0 size, then the avformat_open_input is able to read, but it seeks to the end minus 18k(something) Â and reads to the end in 2k blocks... and I'm subsequently able to get audio and sound streams to play... but not if I call the probe_infput_format first...</div>
<div><br></div><div>I'm not sure what the return of the original probe is; but it's 0 when the video loads.</div><div><br></div></div></blockquote><div><br></div><div>I checked this morning, probe results with a QuickTime/MOV format... which is also the same format as open_input finds; but the resulting read behavior is totally different</div>
<div>Â </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div></div><div>I see that the command line tool is supposed to support pipes (at least on some platforms), so I assume it does a similar thing to build a IO context that doesnt' have seek?</div>
<div><br></div></div>
</blockquote></div><br></div></div>