<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
  <meta content="text/html; charset=ISO-8859-1"
 http-equiv="Content-Type">
</head>
<body bgcolor="#ffffff" text="#000000">
<meta content="text/html; charset=ISO-8859-1" http-equiv="Content-Type">
<br>
Hi,<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; I agree with h264parse can complete h264 frames.<br>
<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Before starting gstreamer pipeline, I'll negotiates the video
resolution. Thats not a problem.<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; The reason, I'm receiving complete h264 frames before pushing
to h264parse is, another display<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; application using ffmpeg is displaying the live stream. Display
application uses the completed<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; frames for&nbsp; displaying.<br>
<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; My problem is with dummy frames written into avi file.<br>
<br>
<br>
On 07/15/2010 11:36 AM, sudarshan bisht wrote:
<blockquote
 cite="mid:AANLkTilP0fh0c-coeWFREuQI-IusvNrkdX2RFct4UG_e@mail.gmail.com"
 type="cite">
  <div>&nbsp;Hi , </div>
  <div>&nbsp;</div>
  <div>&nbsp; </div>
  <div>&nbsp; You are setting caps 800x600 in&nbsp;caps but you output shows
1280x720 ?? </div>
  <div><br>
&nbsp;&nbsp; And why you are waiting to receive a complete frame ? &nbsp;you can
simply push the data to appsrc , h264parse is there to build&nbsp;a complete
frame .</div>
  <div>&nbsp;</div>
  <div><br>
&nbsp;</div>
  <div class="gmail_quote">On Thu, Jul 15, 2010 at 11:15 AM,
Prabhulinga Swamy B S <span dir="ltr">&lt;<a moz-do-not-send="true"
 href="http://prabhulingaswamy.bs">prabhulingaswamy.bs</a>@<a
 moz-do-not-send="true" href="http://globaledgesoft.com">globaledgesoft.com</a>&gt;</span>
wrote:<br>
  <blockquote
 style="border-left: 1px solid rgb(204, 204, 204); margin: 0px 0px 0px 0.8ex; padding-left: 1ex;"
 class="gmail_quote">hi Sandeep,<br>
&nbsp; &nbsp; &nbsp;thank you for your reply.<br>
    <br>
&nbsp; &nbsp; Yes, I'm sure of receiving 30 fps from the network. After<br>
completely receiving<br>
&nbsp; &nbsp; the frame, I'm incrementing frame count.<br>
    <br>
&nbsp; &nbsp; What I mean about the duplicate frames is, after every valid frame<br>
in the resulting<br>
&nbsp; &nbsp; video file, there is a duplicate and empty frame.<br>
    <br>
&nbsp; &nbsp; The fallowing output can clear your doubt.<br>
    <br>
prabhu@prabhu:avi $ ffmpeg -v 5 -i sample.avi -f null -<br>
    <br>
Input #0, avi, from 'sample.avi':<br>
&nbsp; Duration: 00:00:00.00, start: 0.000000, bitrate: -2147483 kb/s<br>
&nbsp; &nbsp; Stream #0.0, 1/60: Video: h264, yuv420p, 1280x720, 1/120, 59.94<br>
tbr, 60 tbn, 120 tbc<br>
Output #0, null, to 'pipe:':<br>
&nbsp; &nbsp; Stream #0.0, 1/90000: Video: rawvideo, yuv420p, 1280x720,<br>
1001/60000, q=2-31, 200 kb/s, 90k tbn, 59.94 tbc<br>
Stream mapping:<br>
&nbsp; Stream #0.0 -&gt; #0.0<br>
&nbsp; existing PPS referenced<br>
    <br>
[h264 @ 0x806ed70]non-existing PPS referenced<br>
[h264 @ 0x806ed70]decode_slice_header error<br>
[h264 @ 0x806ed70]no frame!<br>
Error while decoding stream #0.0<br>
Error while decoding stream #0.0<br>
&nbsp; &nbsp; Last message repeated 1 times<br>
[h264 @ 0x806ed70]non-existing PPS referenced<br>
[h264 @ 0x806ed70]decode_slice_header error<br>
[h264 @ 0x806ed70]no frame!<br>
Error while decoding stream #0.0<br>
*** 1 dup!<br>
Error while decoding stream #0.0<br>
*** 1 dup!<br>
&nbsp; &nbsp; &nbsp; &nbsp; .<br>
&nbsp; &nbsp; &nbsp; &nbsp; .<br>
&nbsp; &nbsp; &nbsp; &nbsp; .<br>
Error while decoding stream #0.0<br>
*** 1 dup!<br>
frame= &nbsp;315 fps=122 q=0.0 Lsize= &nbsp; &nbsp; &nbsp;-0kB time=5.26 bitrate=<br>
-0.0kbits/s dup=315 drop=0<br>
video:0kB audio:0kB global headers:0kB muxing overhead -inf%<br>
    <br>
I've received 315 frames from the network and pushed those many frames
into<br>
gstreamer pipeline. But don't know why these dummy frames are written<br>
into the file.<br>
    <br>
For ex, if I receive 30MB of video data, the resulting file is also of<br>
same size, but<br>
frames count will be double the original frames.<br>
    <div class="im"><br>
    <br>
    <br>
    <br>
On 07/14/2010 09:38 PM, Sandeep Prakash wrote:<br>
&gt; Hi,<br>
&gt;<br>
&gt;<br>
&gt; Prabhulinga Swamy B S wrote:<br>
&gt;<br>
&gt;&gt; &nbsp; &nbsp; &nbsp; &nbsp; appsrc is-live=true<br>
&gt;&gt; "caps=video/x-h264,width=800,height=600,framerate=30/1" ! \<br>
&gt;&gt; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; h264parse ! queue ! avimux ! queue ! filesink<br>
&gt;&gt; location=filename.avi<br>
&gt;&gt;<br>
&gt;&gt;<br>
&gt; Are you sure the h264 stream you are getting from the network has
30 fps?<br>
&gt;<br>
&gt;<br>
&gt; Prabhulinga Swamy B S wrote:<br>
&gt;<br>
&gt;&gt; &nbsp; &nbsp; &nbsp; But the resulting file is having duplicate frames.<br>
&gt;&gt; &nbsp; &nbsp; &nbsp; For ex, if i push 200 frames, the resulting file contain
nearly 200<br>
&gt;&gt; frames.<br>
&gt;&gt;<br>
&gt;&gt;<br>
&gt; Plz explain in detail on the above statements. What does "nearly"
mean?<br>
&gt;<br>
&gt; Regards,<br>
&gt; Sandeep<br>
&gt;<br>
    <br>
--<br>
    <br>
    </div>
  </blockquote>
  </div>
</blockquote>
<br>
<pre class="moz-signature" cols="72">-- 

Regards,
Prabhulinga Swamy B S

</pre>
</body>
</html>