<div dir="ltr"><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><br>
I've tried looking for callbacks, looking at the packet itself, looking at<br>
the AVFormatContext, AVIO, AVStream, etc. And I can't find a way to do it.<br>
Would be really nice if av_write_frame would set the new pos after writing<br>
the packet to the file.<br></blockquote></div><div><br></div><div>I am guessing that FLV container has a known header size. Maybe you can use</div><div>size value of a AVPacket + header + all the AVPackets before and based on that </div><div>calculate what your offset for that IDR packet is? Just an idea, not sure if it will work.</div><div><br></div>-- <br><div dir="ltr" class="gmail_signature"><br>Regards<br>Strahinja Radman</div></div>