Thank you for your reply.<br>@kalileo I am doing the H.264 compression by opening a file with binary mode and write each encoded x264_nal_t* (p_payload[0]) frame into the file. And another thread is continuing to show the images of the file. Both thread are continuing separately. But basically I want to make a live video application. So, I want to decoded just that encoded x264_nal_t* (p_payload[0]). That's why I told I don't want to use file.<br>
<br>@Alex I have used also the following <br> sizeDelay = x264_encoder_delayed_frames(encoder);<br>But all are in vein.<br><br>Thanks all of You<br>Srikanta Mondal<br><br><div class="gmail_quote">On Mon, Apr 9, 2012 at 5:09 PM, Alex Cohn <span dir="ltr"><<a href="mailto:alexcohn@netvision.net.il">alexcohn@netvision.net.il</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="im">On Mon, Apr 9, 2012 at 13:56, srikanta mondal <<a href="mailto:srkntmondal@gmail.com">srkntmondal@gmail.com</a>> wrote:<br>
> Dear all, Thank you for reply. I have used x264 library. And I have the<br>
> following code ....<br>
</div>[..]<br>
<div class="im">> void decoding(uint8_t *data, int size)<br>
> {<br>
> AVPacket *pkt;<br>
> pkt = new AVPacket();<br>
> int gotpicture;<br>
><br>
> av_init_packet(pkt);<br>
> avcodec_get_frame_defaults(picture);<br>
><br>
> pkt->data = data;<br>
> pkt->size = size;<br>
> int outSize = avcodec_decode_video2(m_pContext, picture, &gotpicture,<br>
> pkt);<br>
> }<br>
><br>
> This is my brief code sniff.Please guide me how could I able to decode<br>
> directly without using file.<br>
><br>
> Thanks and regards<br>
> Srikanta Mondal<br>
<br>
</div>h264 decoder produces output after some delay. Minimum delay for<br>
simple Profile is one frame, but if you allow B frames, the delay is<br>
even longer. So, it's OK if you see that the first call to decoding()<br>
function above does not generate a picture.<br>
<br>
BR,<br>
Alex<br>
<div class="HOEnZb"><div class="h5">_______________________________________________<br>
Libav-user mailing list<br>
<a href="mailto:Libav-user@ffmpeg.org">Libav-user@ffmpeg.org</a><br>
<a href="http://ffmpeg.org/mailman/listinfo/libav-user" target="_blank">http://ffmpeg.org/mailman/listinfo/libav-user</a><br>
</div></div></blockquote></div><br>