<br><br><div><span class="gmail_quote">On 7/20/07, <b class="gmail_sendername">Jean-Paul Saman</b> <<a href="mailto:jean-paul.saman@planet.nl">jean-paul.saman@planet.nl</a>> wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Herman Schultz wrote:<br>> Hi,<br>><br>> I am using VLC streaming (as a boardcaster) to Darwin.<br>><br>> But when I use a video client (e.g. quicktime/vlc) to watch that stream by<br>> hitting Darwin, I see a lot of green rectangles in the video in the
<br>> beginning. (see attached screen shot).<br>><br>> Can you please tell me what is wrong? And how can i fix it?<br><br>I suspect this is due to a missing key frame. The decoder just fills in<br>the blank in that case. Which of course when missing the first keyframe
<br>can produce strange effects.</blockquote><div><br>Jean-Paul,<br><br>I am seeing the same 'green area' issue in the result mp4 file when I use VLC to transcode a flv file. Here is the parameter that I used for transcoding:
<br><br> ./vlc -vvv -I dummy ~/Desktop/video.flv --sout '#transcode{vcodec=mp4v,vb=400,acodec=mpga,ab=128,audo-sync}:standard{access=file, mux=mp4, dst=/home/herman/genvlc.mp4}'<br><br>I think you are right in saying the 'green area' problem is caused by a missing key frame. I put
<br>more debug print statement in my ffmpge+vlc code. And it did say 'first frame is no keyframe' and i notice that the first frame passed to MPV_frame_start is type 2 ( FF_P_TYPE , not 1 (FF_I_TYPE) that I expected).
<br><br>[00000298] stream_out_transcode private debug: transcode_video_process calling pf_decode_video <br>
[00000399] ffmpeg decoder debug: DecodeVideo!<br>
<br>
[00000399] ffmpeg decoder debug: p_sys->i_buffer: 201<br>
<br>
[00000399] ffmpeg decoder warning: MPV_frame_start 2<br>
<br>
[00000399] ffmpeg decoder warning: warning: first frame is no keyframe<br>
<br>Can you please provide me some more pointers about how can I troble-shoot this problem from this point? <br>For example <br>* where in the code to determine the frame type ? I did a grep and step breakpoints in those code, but it never breaks there...
<br>* why the first frame can be type P_TYPE, instead of I_TYPE?<br>* why the first i_buffer is only 201 bytes? It is kind of small for a frame?<br><br>Thank you in advance for any help/pointers.<br><br>A more complete log is here:
<br><br>[00000315] ffmpeg demuxer debug: detected format: flv<br>[flv @ 0x857ce28]MPV_frame_start 1<br>[00000295] main input debug: selecting program id=0<br>[00000315] ffmpeg demuxer debug: adding es: video codec = FLV1
<br>[00000315] ffmpeg demuxer debug: adding es: audio codec = mp3 <br>[00000315] ffmpeg demuxer debug: AVFormat supported stream<br>[00000315] ffmpeg demuxer debug: - format = flv (flv format)<br>[00000315] ffmpeg demuxer debug: - start time = 0
<br>[00000315] ffmpeg demuxer debug: - duration = 300042000<br>[00000315] main demuxer debug: using demux2 module "ffmpeg"<br>[00000295] main input debug: looking for a subtitle file in /home/herman/Desktop/
<br>[00000358] main packetizer debug: looking for packetizer module: 17 candidates<br>[00000358] main packetizer debug: using packetizer module "packetizer_copy"<br>[00000295] main input debug: stream out mode -> no decoder thread
<br>[00000389] main packetizer debug: looking for packetizer module: 17 candidates<br>[00000389] main packetizer debug: using packetizer module "packetizer_copy"<br>[00000295] main input debug: stream out mode -> no decoder thread
<br>[00000295] main input debug: starting in async mode<br>[00000295] main input debug: `/home/herman/Desktop/video.flv' successfully opened<br>[00000389] packetizer_copy packetizer debug: need dts > 0<br>[00000358] packetizer_copy packetizer debug: need dts > 0
<br>[00000297] main stream output debug: adding a new input<br>[00000298] stream_out_transcode private debug: creating audio transcoding from fcc=`mp3 ' to fcc=`mpga'<br>[00000390] main decoder debug: looking for decoder module: 25 candidates
<br>[00000390] ffmpeg decoder debug: libavcodec initialized (interface 3352580 )<br>[00000390] ffmpeg decoder debug: ffmpeg codec (MPEG Audio layer 1/2/3) started<br>[00000390] main decoder debug: using decoder module "ffmpeg"
<br>[00000391] main encoder debug: looking for encoder module: 7 candidates<br>[00000391] ffmpeg encoder debug: libavcodec already initialized<br>[00000391] ffmpeg encoder debug: found encoder MPEG Audio layer 1/2<br>[00000391] main encoder debug: using encoder module "ffmpeg"
<br>[00000298] stream_out_transcode private debug: Sam: open output stream 0-0<br>[00000305] main private debug: adding a new input<br>[00000305] main private debug: calling pf_addstream start<br>[00000305] mux_mp4 private debug: adding input
<br>[00000305] main private debug: calling pf_addstream end<br>[00000298] stream_out_transcode private debug: Sam: open output stream 0-4<br>[00000297] main stream output debug: adding a new input<br>[00000298] stream_out_transcode private debug: creating video transcoding from fcc=`FLV1' to fcc=`mp4v'
<br>[00000399] main decoder debug: looking for decoder module: 25 candidates<br>[00000399] ffmpeg decoder debug: libavcodec already initialized<br>[00000399] ffmpeg decoder debug: postprocessing disabled<br>[00000399] ffmpeg decoder debug: using direct rendering
<br>[00000399] ffmpeg decoder debug: ffmpeg codec (Flash Video) started<br>[00000399] main decoder debug: using decoder module "ffmpeg"<br>[00000400] main encoder debug: looking for encoder module: 7 candidates<br>
[00000400] ffmpeg encoder debug: libavcodec already initialized<br>[00000400] ffmpeg encoder debug: found encoder MPEG-4 Video<br>[00000400] main encoder debug: using encoder module "ffmpeg"<br>[00000400] main encoder debug: removing module "ffmpeg"
<br>[00000298] stream_out_transcode private debug: end creating video transcoding from fcc<br>[00000298] stream_out_transcode private debug: transcode_video_process calling pf_decode_video <br>[00000399] ffmpeg decoder debug: DecodeVideo!
<br><br>[00000399] ffmpeg decoder debug: p_sys->i_buffer: 201<br><br>[00000399] ffmpeg decoder warning: MPV_frame_start 2<br><br>[00000399] ffmpeg decoder warning: warning: first frame is no keyframe<br><br>[00000298] stream_out_transcode private debug: decoder aspect is 576000:432000
<br>[00000298] stream_out_transcode private debug: source pixel aspect is 1.000000:1<br>[00000298] stream_out_transcode private debug: scaled pixel aspect is 1.000000:1<br>[00000298] stream_out_transcode private debug: source 320x240, crop 320x240, destination 320x240, padding 320x240
<br><br><br><br><br> </div><br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">Gtz,<br>Jean-Paul Saman.<br></blockquote></div><br>